[JAVA-4646] Deal with consequence of interrupted socket operation throwing SocketException Created: 13/Jun/22 Updated: 07/Sep/23 Resolved: 07/Sep/23 |
|
| Status: | Closed |
| Project: | Java Driver |
| Component/s: | Internal |
| Affects Version/s: | None |
| Fix Version/s: | 4.11.0 |
| Type: | Improvement | Priority: | Major - P3 |
| Reporter: | Jeffrey Yemin | Assignee: | Valentin Kavalenka |
| Resolution: | Done | Votes: | 0 |
| Labels: | loom | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Epic Link: | Virtual Threads Support |
| Quarter: | FY24Q3 |
| Backwards Compatibility: | Fully Compatible |
| Documentation Changes: | Not Needed |
| Documentation Changes Summary: | 1. What would you like to communicate to the user about this feature? |
| Description |
|
When a socket operation is interrupted (say by a call to StructuredTaskScope#joinUntil that times out, tests show that SocketInputStream#read throws a SocketException with the message "Closed by interrupt" . The driver will treat that exception according to the rules defined by the SDAM and CMAP specifications, as a network error. But it should be treated more like InterruptedException. |
| Comments |
| Comment by Githook User [ 07/Sep/23 ] |
|
Author: {'name': 'Valentin Kovalenko', 'email': 'valentin.kovalenko@mongodb.com', 'username': 'stIncMale'}Message: Handle `Socket` IO interruptibility (#1189)
|
| Comment by Jeffrey Yemin [ 12/Apr/23 ] |
|
Some ideas here: https://github.com/jyemin/mongo-java-driver/tree/j4646 |