You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@shardingsphere.apache.org by GitBox <gi...@apache.org> on 2022/08/02 15:53:02 UTC
[GitHub] [shardingsphere] RaigorJiang opened a new issue, #19815: NPE occurs in close method of `UnicastDatabaseBackendHandler` when there is no resouce in database
RaigorJiang opened a new issue, #19815:
URL: https://github.com/apache/shardingsphere/issues/19815
### Which version of ShardingSphere did you use?
master https://github.com/apache/shardingsphere/commit/1b50bb6cc1c9a1dd537f65a271363aa4f2cdd81d
### Which project did you use? ShardingSphere-JDBC or ShardingSphere-Proxy?
ShardingSphere-Proxy
### Expected behavior
Give an appropriate error message
### Actual behavior
```sql
postgres=> show all;
ERROR: Cannot invoke "org.apache.shardingsphere.proxy.backend.communication.DatabaseCommunicationEngine.close()" because "this.databaseCommunicationEngine" is null
postgres=>
```
#### Log
```
java.lang.NullPointerException: Cannot invoke "org.apache.shardingsphere.proxy.backend.communication.DatabaseCommunicationEngine.close()" because "this.databaseCommunicationEngine" is null
at org.apache.shardingsphere.proxy.backend.handler.data.impl.UnicastDatabaseBackendHandler.close(UnicastDatabaseBackendHandler.java:106)
at org.apache.shardingsphere.proxy.frontend.postgresql.command.query.simple.PostgreSQLComQueryExecutor.close(PostgreSQLComQueryExecutor.java:133)
at org.apache.shardingsphere.proxy.frontend.command.CommandExecutorTask.executeCommand(CommandExecutorTask.java:125)
at org.apache.shardingsphere.proxy.frontend.command.CommandExecutorTask.run(CommandExecutorTask.java:78)
```
### Reason analyze (If you can)
`databaseCommunicationEngine` is null
### Steps to reproduce the behavior, such as: SQL to execute, sharding rule configuration, when exception occur etc.
Props in server.yaml
```yaml
props:
proxy-frontend-database-protocol-type: PostgreSQL
```
Start the Proxy with PostgreSQL type, connect to the logic database postgres, and execute `show all;`.
--
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: notifications-unsubscribe@shardingsphere.apache.org.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [shardingsphere] terrymanu closed issue #19815: NPE occurs in close method of `UnicastDatabaseBackendHandler` when there is no resouce in database
Posted by GitBox <gi...@apache.org>.
terrymanu closed issue #19815: NPE occurs in close method of `UnicastDatabaseBackendHandler` when there is no resouce in database
URL: https://github.com/apache/shardingsphere/issues/19815
--
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: notifications-unsubscribe@shardingsphere.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org