-
Type: New Feature
-
Resolution: Unresolved
-
Priority: Major - P3
-
None
-
Affects Version/s: None
-
Component/s: Not Applicable
-
Storage Engines
-
StorEng - Defined Pipeline
MongoDB may benefit from receiving asynchronous feedback as to whether the storage engine estimates it is behind with respect to processing requests. Thereby allowing the server to adapt before investing in starting a transaction.
One way this might be achieved is to provide support for an optional IPC interface that the server could monitor with say poll(). For instance all platforms including windows support AF_UNIX socket IPC for example.
Fleshing out a design and API would be too cumbersome for this speculative ticket. Here are cursory notes on the idea:
- I think the channel should be associated with the connection.
- The communication channel should be one way only: WiredTiger to caller.
- There should be no possibility of blocking WiredTiger so this means notifications might be lost if not serviced in a timely fashion.
- The protocol should be simple and abstract. Possible in the form of "advice" to the caller. Exposing internal state will potentially create unwanted coupling.
- Setup and teardown should be the responsibility of a single party.
- An IPC mechanism that does not require sharing memory but rather uses a system resource identifier (name) is strongly preferred as it avoids many potential issues.