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 2021/04/07 02:52:58 UTC

[GitHub] [shardingsphere] sandynz opened a new issue #9955: Proxy with empty configuration "show databases" and "create database db1" failed when governance enabled

sandynz opened a new issue #9955:
URL: https://github.com/apache/shardingsphere/issues/9955


   ## Bug Report
   
   ### Which version of ShardingSphere did you use?
   5.0.0-RC1-SNAPSHOT, commit: c7ea29693b802cffd29fd5323bf35970434bd353
   
   ### Which project did you use? ShardingSphere-JDBC or ShardingSphere-Proxy?
   ShardingSphere-Proxy
   
   ### Expected behavior
   No exception thrown
   
   ### Actual behavior
   Stack trace:
   ```
   [ShardingSphere-Command-0] o.a.s.p.f.c.CommandExecutorTask - Exception occur: 
   java.lang.NullPointerException: null
   	at org.apache.shardingsphere.infra.check.SQLCheckEngine.check(SQLCheckEngine.java:49)
   	at org.apache.shardingsphere.proxy.backend.text.TextProtocolBackendHandlerFactory.sqlCheck(TextProtocolBackendHandlerFactory.java:92)
   	at org.apache.shardingsphere.proxy.backend.text.TextProtocolBackendHandlerFactory.newInstance(TextProtocolBackendHandlerFactory.java:78)
   	at org.apache.shardingsphere.proxy.frontend.mysql.command.query.text.query.MySQLComQueryPacketExecutor.<init>(MySQLComQueryPacketExecutor.java:52)
   	at org.apache.shardingsphere.proxy.frontend.mysql.command.MySQLCommandExecutorFactory.newInstance(MySQLCommandExecutorFactory.java:73)
   	at org.apache.shardingsphere.proxy.frontend.mysql.command.MySQLCommandExecuteEngine.getCommandExecutor(MySQLCommandExecuteEngine.java:60)
   	at org.apache.shardingsphere.proxy.frontend.command.CommandExecutorTask.executeCommand(CommandExecutorTask.java:92)
   	at org.apache.shardingsphere.proxy.frontend.command.CommandExecutorTask.run(CommandExecutorTask.java:71)
   	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
   	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
   	at java.lang.Thread.run(Thread.java:748)
   ```
   
   ### Reason analyze (If you can)
   `backendConnection.getSchemaName()` is null, which cause related `shardingSphereMetaData` still null
   
   ### Steps to reproduce the behavior, such as: SQL to execute, sharding rule configuration, when exception occur etc.
   1, Enable governance in `server.yaml`
   2, Clean configuration, include `config-sharding.yaml` and remote configuration in ZooKeeper governance_ds
   3, Client connect to proxy, run `show databases;` or `CREATE DATABASE sharding_db;`
   
   ### Example codes for reproduce this issue (such as a github link).
   


-- 
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [shardingsphere] terrymanu closed issue #9955: Proxy with empty configuration "show databases" and "create database db1" failed when governance enabled

Posted by GitBox <gi...@apache.org>.
terrymanu closed issue #9955:
URL: https://github.com/apache/shardingsphere/issues/9955


   


-- 
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org