[JAVA-5197] Support the "operation" key when doing standardized server selection logging Created: 12/Oct/23  Updated: 16/Oct/23

Status: Backlog
Project: Java Driver
Component/s: Logging, Server Selection
Affects Version/s: None
Fix Version/s: None

Type: Improvement Priority: Minor - P4
Reporter: Valentin Kavalenka Assignee: Unassigned
Resolution: Unresolved Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Issue split
split from JAVA-4754 Add log messages to Server selection ... Closed
Epic Link: Easier debugging with standardized logging
Documentation Changes Summary:

1. What would you like to communicate to the user about this feature?
2. Would you like the user to see examples of the syntax and/or executable code and its output?
3. Which versions of the driver/connector does this apply to?


 Description   

From the implementation standpoint, we need to pass operation name to Cluster.selectServer/selectServerAsync via OperationContext. It seems that if each ReadOperation/WriteOperation/AsyncReadOperation/AsyncWriteOperation exposes the name of the operation, we can then take it and put in the OperationContext. Or, maybe each operation may expose its OperationContext, in which case, we will need to create an OperationContext when/before we are creating the corresponding operation.

If we do this, we need to update LogMatcher.assertLogMessageEquality such that it start comparing operation again.


Generated at Thu Feb 08 09:03:59 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.