[JAVA-805] Make connection pool and connection state observable Created: 12/Apr/13 Updated: 15/Jan/18 Resolved: 11/Jul/17 |
|
| Status: | Closed |
| Project: | Java Driver |
| Component/s: | API, Monitoring |
| Affects Version/s: | None |
| Fix Version/s: | 3.5.0 |
| Type: | New Feature | Priority: | Major - P3 |
| Reporter: | Jeffrey Yemin | Assignee: | Ross Lawley |
| Resolution: | Done | Votes: | 7 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||||||||||||||||||||||||||||||
| Case: | (copied to CRM) | ||||||||||||||||||||||||||||||||||||
| Description |
|
It'd be potentially useful for the status of a replica set connection to be observable, so an observer can subscribe and be made aware of any events (eg. change in primary, no primary or no majority, etc.). Similarly, it could be useful for the status of the connection pool and of each connection to be observable. Specifically, the driver should surface the following events to listeners:
|
| Comments |
| Comment by Githook User [ 10/Jul/17 ] |
|
Author: {u'username': u'rozza', u'name': u'Ross Lawley', u'email': u'ross.lawley@gmail.com'}Message: Made ConnectionListener and ConnectionPoolListener an official part of the API
|
| Comment by Ross Lawley [ 15/Jun/17 ] |
| Comment by Jeffrey Yemin [ 13/Sep/13 ] |
|
This is complete in core, but still need to expose a way to add listeners via MongoClientOptions |
| Comment by auto [ 13/Sep/13 ] |
|
Author: {u'username': u'jyemin', u'name': u'Jeff Yemin', u'email': u'jeff.yemin@10gen.com'}Message: |
| Comment by auto [ 13/Sep/13 ] |
|
Author: {u'username': u'jyemin', u'name': u'Jeff Yemin', u'email': u'jeff.yemin@10gen.com'}Message: |
| Comment by auto [ 13/Sep/13 ] |
|
Author: {u'username': u'jyemin', u'name': u'Jeff Yemin', u'email': u'jeff.yemin@10gen.com'}Message: |
| Comment by auto [ 13/Sep/13 ] |
|
Author: {u'username': u'jyemin', u'name': u'Jeff Yemin', u'email': u'jeff.yemin@10gen.com'}Message: |
| Comment by auto [ 13/Sep/13 ] |
|
Author: {u'username': u'jyemin', u'name': u'Jeff Yemin', u'email': u'jeff.yemin@10gen.com'}Message: |
| Comment by Jeffrey Yemin [ 12/Jul/13 ] |
|
The underpinnings are here, but this still needs to be exposed via MongoClient |
| Comment by auto [ 26/Jun/13 ] |
|
Author: {u'username': u'jyemin', u'name': u'Jeff Yemin', u'email': u'jeff.yemin@10gen.com'}Message: |
| Comment by Jeffrey Yemin [ 12/Apr/13 ] |
|
Stephen is thinking more of a notification system rather than polling ReplicaSetStatus.getMastert(). It's a reasonable request. |
| Comment by Scott Hernandez (Inactive) [ 12/Apr/13 ] |
|
You can get access to the replica state already. See Mongo.getReplicaSetStatus() |