[JAVA-5034] Allow to suspend/resume MongoClient Created: 22/Jun/23 Updated: 31/Jan/24 |
|
| Status: | Backlog |
| Project: | Java Driver |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | New Feature | Priority: | Unknown |
| Reporter: | Christoph Strobl | Assignee: | Unassigned |
| Resolution: | Unresolved | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Quarter: | FY24Q3, FY24Q4, FY25Q1 |
| Documentation Changes Summary: | 1. What would you like to communicate to the user about this feature? |
| Description |
|
In order to create a checkpoint using CRaC it is required that all sockets are closed before taking the snapshot.
Is there a way to access the ConnectionPool to invoke those methods or maybe even provide some public API as outlined below
In doing so existing references to the MongoClient as well as obtained MongoDatabase, MongoCollection instances will remain valid, which would not be the case if the client was closed before the checkpoint and recreated from captured MongoClientSettings in the afterRestore method. |
| Comments |
| Comment by PM Bot [ 03/Nov/23 ] |
|
There hasn't been any recent activity on this ticket, so we're resolving it. Thanks for reaching out! Please feel free to reopen this ticket if you're still experiencing the issue, and add a comment if you're able to provide more information. |
| Comment by PM Bot [ 26/Oct/23 ] |
|
Hi cstrobl@vmware.com! JAVA-5034 is awaiting your response. If this is still an issue for you, please open Jira to review the latest status and provide your feedback. Thanks! |
| Comment by Slav Babanin [ 18/Oct/23 ] |
|
Posting brief summary of our discussion with cstrobl@vmware.com:
cstrobl@vmware.com since you're currently exploring various approaches, including the complete shutdown of MongoClient, we'll temporarily hold off on the suspension task until the complete client shutdown approach is explored. Please let us know if this does not align. |
| Comment by Christoph Strobl [ 24/Jul/23 ] |
|
The short answer is yes. However, there are two types of checkpoints we're talking about. An early checkpoint is done after application startup to avoid the boot sequence on resume. So the JVM is not warmed up and the application did not have to process any requests yet. A late checkpoint is taken after the JVM has been warmed up by processing/running a set of procedures before capturing the snapshot. This is a controlled process with the only purpose to kick off and then capture jvm runtime optimisations. Either way the user/environment will have to make sure the boot/warmup sequence has completed and no load is applied when sending the command to capture the snapshot. |
| Comment by Jeffrey Yemin [ 21/Jul/23 ] |
|
cstrobl@vmware.com do you think it's safe to assume that at the time the checkpoint is done, there are no in-progress database operations? |
| Comment by Jeffrey Yemin [ 21/Jul/23 ] |
|
Hi cstrobl@vmware.com we plan to tackle this in the next few months. |
| Comment by Tom Selander [ 26/Jun/23 ] |
|
cstrobl@vmware.com Hi Christoph, thanks for the request! We will look into potentially prioritizing this when we do our next round of planning for Java in Q3. |
| Comment by PM Bot [ 22/Jun/23 ] |
|
Hi cstrobl@vmware.com, thank you for reporting this issue! The team will look into it and get back to you soon. |