You are currently browsing legacy 3.5 version of documentation. Click here to switch to the newest 5.1 version.

We can help you with migration to the latest RavenDB

Contact Us Now
see on GitHub

Saving Changes

Pending registered operations (RegisterUpload, RegisterRename, RegisterFileDeletion or metadata changes) will not be sent to the server until the SaveChangesAsync is called.


Task SaveChangesAsync();
Return Value
Task A task that represents the asynchronous save operation

Applying Changes

The RavenFS session, in contrast to the IDocumentSession, does not send changes as a batch operation in a single call. Each registered file modification will be executed in a separate request.

If the exception occurs when the file change is applied, the exception will be thrown by the SaveChangesAsync and any pending modifications will be canceled.


await session.SaveChangesAsync();