So I am developing a Spellchecker application. I am storing all the projects (books) on Dropbox. My application downloads and uploads files to Dropbox.
The application will have multiple users who may possibly be accessing the same project at the same time. If two users finish processing the project at the same time (i.e. application starts to upload the same file at the same time to dropbox), I assume, one overwrites the other.
This would cause a problem for me. I would like to program the application to acquire a lease on a certain project, giving the user exclusive access to it. The point is at this link https://www.dropbox.com/developers/reference/webhooks I saw something about leases.
How do I implement a lease? In java in this dropbox API how to I assign exclusive access to a Dropbox folder for one user at a time?
Cheers