What is New in RavenDB 3.0: Operations - The Nitty Gritty Details
Join the DZone community and get the full member experience.Join For Free
after looking at all the pretty pictures, let us take a look at what we have available for us for behind the cover for ops.
the first such change is abandoning performance counters. in 2.5, we reported a lot of our state through performance counters. however, while they are a standard tool and easy to work with using admin tools, they were also unworkable. we have had multiple times where ravendb would hang because performance counters were corrupted, they require specific permissions and in general they were a lot of hassle. instead of relying on performance counters, we are now using the metrics.net package to handle that. this gives us a lot more flexibility. we can now generate a lot more metrics, and we have. all of those are available in the /debug/metrics endpoint, and on the studio as well.
another major change we did was to consolidate all of the database administration details to a centralized location:
manage your server gives us all the tools we need to manage the databases on this server.
you can manage permissions, backup and restore, watch what is going on and in general do admin style operations.
in particular, note that we made it slightly harder to use the system database. the intent now is that the system database is reserved for managing the ravendb server itself, and all users’ data will reside in their own databases.
you can also start a compaction directly from the studio:
compactions are good if you want to ask ravendb to return some disk space to the os (by default we reserve it for our own usage).
restore & backup are possible via the studio, but usually, admins want to script those out. we had raven.backup.exe to handle scripted backup for a while now. and you could restore using raven.server.exe --restore from the command line.
the problem was that this restored the database to disk, but didn’t wire it to the server, so you had the extra step of doing that. this was useful for restoring system databases, not so much for named databases.
we now have:
- raven.server.exe --restore-system-database --restore-source=c:\backups\system\2014-09-17 --restore-destination=c:\raven\data\system
- raven.serve.exe --restore-database=http://localhost:8080 --restore-source=c:\backups\realestaterus\2014-09-17 --restore-database-name=c:\raven\data\databases\realestaterus
which make a clear distinction between those operations.
another related issue is how smuggler handles error. previously, the full export process had to complete successfully for you to have a valid output. now we are more robust for errors such as unreliable network or timeouts. that means that if your network has a tendency to cut connections off at the knee, you will be able to resume (assuming you use incremental export) and still get your data.
we have also made a lot of changes in the smuggler to make it work more nicely in common deployment scenarios, where request size and time are usually limited. the whole process is more robust for errors now.
speaking of making things more robust, another area where we put attention to was memory usage over time. beyond just reducing our memory usage in common scenarios, we have also improved our gc story. we can now invoke explicit gcs when we know that we created a lot of garbage that needs to be rid off. we’ll also invoke large object heap compaction if needed, utilizing the new features in the .net framework.
that is quite enough for a single post, but still doesn’t cover all the operations change, i’ll cover the stuff that should make your drool on the next post.
Published at DZone with permission of Oren Eini, DZone MVB. See the original article here.
Opinions expressed by DZone contributors are their own.