Details
-
Improvement
-
Resolution: Done
-
Major
-
2.5.0
-
Security Level: Public
Description
Automatic closing of replicators when issuing a db close is a common API enhancement request from customers .
Today clients have to implement a wait loop to check for replicators to close before they can close the database. The issue is how long do they wait ? This is true even for the case when replicator.close does eventually succeed - it is exacerbated when the replicator.close() does not return at all and is stuck in busy state (see related ticket).
The API enhancement to db.close() should handle the following-
- Automatically close all replicators.
- Configurable timeout that apps can use to specify how long to wait before giving up/returning.
- Define what the implications of "Giving up" are . Options
- Should CBL continue to wait for replicators to close. How long?
- Force stop option / nullify replicator instances
- Returning from API without closing all replicators should not prevent the app from future db operations ( re-open database)
(I Can't seem to add watchers
CC Jens Alfke, Jim Borden, Pasin Suriyentrakorn, Daniel Petersen)