linghengqian commented on issue #33831:
URL:
https://github.com/apache/shardingsphere/issues/33831#issuecomment-2506365028
> for example the database server crashed
- This doesn't sound like there is any way to check it.
`java.sql.Connection` does not have an interface for health checking. So I'm
assuming you want to do this? Are you going to submit a PR with unit tests?
```java
if (1 == connectionSize) {
Connection connection = createConnection(databaseName,
dataSourceName, dataSource, connectionContext.getTransactionContext());
try {
methodInvocationRecorder.replay(connection);
} catch (final SQLException ex) {
connection.close();
throw ex;
}
return Collections.singletonList(connection);
}
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]