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/10/18 02:08:43 UTC

[GitHub] [shardingsphere] BruceZhangXL opened a new issue #13082: Could not initialize class org.apache.shardingsphere.sql.parser.core.rule.registry.ParseRuleRegistry

BruceZhangXL opened a new issue #13082:
URL: https://github.com/apache/shardingsphere/issues/13082


   ## Bug Report
   java.lang.NoClassDefFoundError, message=Could not initialize class org.apache.shardingsphere.sql.parser.core.rule.registry.ParseRuleRegistry 】 
   java.lang.NoClassDefFoundError: Could not initialize class org.apache.shardingsphere.sql.parser.core.rule.registry.ParseRuleRegistry
   	at org.apache.shardingsphere.sql.parser.SQLParseEngine.parse0(SQLParseEngine.java:70)
   	at org.apache.shardingsphere.sql.parser.SQLParseEngine.parse(SQLParseEngine.java:52)
   	at org.apache.shardingsphere.core.route.router.sharding.ShardingRouter.parse$original$K1EIPfwP(ShardingRouter.java:86)
   	at org.apache.shardingsphere.core.route.router.sharding.ShardingRouter.parse$original$K1EIPfwP$accessor$fYOJ3msv(ShardingRouter.java)
   	at org.apache.shardingsphere.core.route.router.sharding.ShardingRouter$auxiliary$8V8n2toM.call(Unknown Source)
   	at org.apache.skywalking.apm.agent.core.plugin.interceptor.enhance.InstMethodsInter.intercept(InstMethodsInter.java:86)
   	at org.apache.shardingsphere.core.route.router.sharding.ShardingRouter.parse(ShardingRouter.java)
   
   ### Which version of ShardingSphere did you use?
   4.1.1
   ### Which project did you use? ShardingSphere-JDBC or ShardingSphere-Proxy?
   ShardingSphere-JDBC
   ### Expected behavior
   run fine under jdk 11
   ### Actual behavior
   sometime throw  NoClassDefFoundError under jdk 11, the error seldom occur  but really exists ,must restart app once occured
   ### Reason analyze (If you can)
   ![image](https://user-images.githubusercontent.com/10344508/137657981-045e411f-fe55-4722-a00a-629cab281f78.png)
   
   the static code block in ParseRuleRegistry maybe occer error,should wrap them with try and catch the real exception,instead of throw the initialize class fail exception.
   
   


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



[GitHub] [shardingsphere] lanchengx commented on issue #13082: Could not initialize class org.apache.shardingsphere.sql.parser.core.rule.registry.ParseRuleRegistry

Posted by GitBox <gi...@apache.org>.
lanchengx commented on issue #13082:
URL: https://github.com/apache/shardingsphere/issues/13082#issuecomment-945335940


   Could you verify it in the test environment?


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



[GitHub] [shardingsphere] BruceZhangXL closed issue #13082: Could not initialize class org.apache.shardingsphere.sql.parser.core.rule.registry.ParseRuleRegistry

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


   


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



[GitHub] [shardingsphere] BruceZhangXL commented on issue #13082: Could not initialize class org.apache.shardingsphere.sql.parser.core.rule.registry.ParseRuleRegistry

Posted by GitBox <gi...@apache.org>.
BruceZhangXL commented on issue #13082:
URL: https://github.com/apache/shardingsphere/issues/13082#issuecomment-945326714


   > Hi @BruceZhangXL , thanks for your feedback, could you try the latest version 5.0.0-beta? `ParseRuleRegistry` has some adjustments.
   
   the code had changed too much in 5.0.0, i can not find  this class named ParseRuleRegistry. we can not try this version in prod env.


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



[GitHub] [shardingsphere] BruceZhangXL commented on issue #13082: Could not initialize class org.apache.shardingsphere.sql.parser.core.rule.registry.ParseRuleRegistry

Posted by GitBox <gi...@apache.org>.
BruceZhangXL commented on issue #13082:
URL: https://github.com/apache/shardingsphere/issues/13082#issuecomment-954465927


   this exception throwed by parallelStream ,the classloader changed. has solved by invoke ParseRuleRegistry.getInstance during app is starting


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



[GitHub] [shardingsphere] lanchengx commented on issue #13082: Could not initialize class org.apache.shardingsphere.sql.parser.core.rule.registry.ParseRuleRegistry

Posted by GitBox <gi...@apache.org>.
lanchengx commented on issue #13082:
URL: https://github.com/apache/shardingsphere/issues/13082#issuecomment-945319156


   Hi @BruceZhangXL , thanks for your feedback, could you try the latest version 5.0.0-beta? `ParseRuleRegistry` has some adjustments.


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