You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@shardingsphere.apache.org by "794086163 (via GitHub)" <gi...@apache.org> on 2023/03/03 08:25:41 UTC

[GitHub] [shardingsphere] 794086163 opened a new issue, #24439: java.lang.OutOfMemoryError: GC overhead limit exceeded

794086163 opened a new issue, #24439:
URL: https://github.com/apache/shardingsphere/issues/24439

   
   ### Which version of ShardingSphere did you use?
   5.2.1
   ### Which project did you use? ShardingSphere-JDBC or ShardingSphere-Proxy?
   ShardingSphere-JDBC
   ### Expected behavior
   
   SQL executed correctly
   
   ### Actual behavior
   
   java.lang.OutOfMemoryError
   
   ### Reason analyze (If you can)
   When parsing SQL, there is an endless loop!!
   
   ![image](https://user-images.githubusercontent.com/37607959/222663652-1f6b90c9-4cf4-41d7-a899-82c9900634a9.png)
   
   
       at org.apache.shardingsphere.sql.parser.sql.common.util.ExpressionExtractUtil.extractAndPredicates(java.util.Collection, org.apache.shardingsphere.sql.parser.sql.common.segment.dml.expr.ExpressionSegment) (line: 67)
       at org.apache.shardingsphere.sql.parser.sql.common.util.ExpressionExtractUtil.getAndPredicates(org.apache.shardingsphere.sql.parser.sql.common.segment.dml.expr.ExpressionSegment) (line: 50)
       at org.apache.shardingsphere.sql.parser.sql.common.util.ExpressionExtractUtil.extractAndPredicates(java.util.Collection, org.apache.shardingsphere.sql.parser.sql.common.segment.dml.expr.ExpressionSegment) (line: 66)
       at org.apache.shardingsphere.sql.parser.sql.common.util.ExpressionExtractUtil.getAndPredicates(org.apache.shardingsphere.sql.parser.sql.common.segment.dml.expr.ExpressionSegment) (line: 50)
       at org.apache.shardingsphere.sql.parser.sql.common.util.ColumnExtractor.extractColumnSegments(java.util.Collection, java.util.Collection) (line: 72)
       at org.apache.shardingsphere.infra.binder.statement.dml.SelectStatementContext.<init>(java.util.Map, java.util.List, org.apache.shardingsphere.sql.parser.sql.common.statement.dml.SelectStatement, java.lang.String) (line: 110)
       at org.apache.shardingsphere.infra.binder.SQLStatementContextFactory.getDMLStatementContext(java.util.Map, java.util.List, org.apache.shardingsphere.sql.parser.sql.common.statement.dml.DMLStatement, java.lang.String) (line: 163)
       at org.apache.shardingsphere.infra.binder.SQLStatementContextFactory.newInstance(java.util.Map, java.util.List, org.apache.shardingsphere.sql.parser.sql.common.statement.SQLStatement, java.lang.String) (line: 146)
       at org.apache.shardingsphere.infra.binder.SQLStatementContextFactory.newInstance(java.util.Map, org.apache.shardingsphere.sql.parser.sql.common.statement.SQLStatement, java.lang.String) (line: 131)
       at org.apache.shardingsphere.driver.jdbc.core.statement.ShardingSpherePreparedStatement.<init>(org.apache.shardingsphere.driver.jdbc.core.connection.ShardingSphereConnection, java.lang.String, int, int, int, boolean, java.lang.String[ ]) (line: 196)
       at org.apache.shardingsphere.driver.jdbc.core.statement.ShardingSpherePreparedStatement.<init>(org.apache.shardingsphere.driver.jdbc.core.connection.ShardingSphereConnection, java.lang.String) (line: 160)
       at org.apache.shardingsphere.driver.jdbc.core.connection.ShardingSphereConnection.prepareStatement(java.lang.String) (line: 91)
       at org.apache.ibatis.executor.statement.PreparedStatementHandler.instantiateStatement(java.sql.Connection) (line: 86)
       at org.apache.ibatis.executor.statement.BaseStatementHandler.prepare(java.sql.Connection, java.lang.Integer) (line: 88)
       at org.apache.ibatis.executor.statement.RoutingStatementHandler.prepare(java.sql.Connection, java.lang.Integer) (line: 59)
       at com.baomidou.mybatisplus.core.executor.MybatisSimpleExecutor.prepareStatement(org.apache.ibatis.executor.statement.StatementHandler, org.apache.ibatis.logging.Log, boolean) (line: 94)
       at com.baomidou.mybatisplus.core.executor.MybatisSimpleExecutor.doQuery(org.apache.ibatis.mapping.MappedStatement, java.lang.Object, org.apache.ibatis.session.RowBounds, org.apache.ibatis.session.ResultHandler, org.apache.ibatis.mapping.BoundSql) (line: 68)
       at org.apache.ibatis.executor.BaseExecutor.queryFromDatabase(org.apache.ibatis.mapping.MappedStatement, java.lang.Object, org.apache.ibatis.session.RowBounds, org.apache.ibatis.session.ResultHandler, org.apache.ibatis.cache.CacheKey, org.apache.ibatis.mapping.BoundSql) (line: 325)
       at org.apache.ibatis.executor.BaseExecutor.query(org.apache.ibatis.mapping.MappedStatement, java.lang.Object, org.apache.ibatis.session.RowBounds, org.apache.ibatis.session.ResultHandler, org.apache.ibatis.cache.CacheKey, org.apache.ibatis.mapping.BoundSql) (line: 156)
       at com.baomidou.mybatisplus.core.executor.MybatisCachingExecutor.query(org.apache.ibatis.mapping.MappedStatement, java.lang.Object, org.apache.ibatis.session.RowBounds, org.apache.ibatis.session.ResultHandler, org.apache.ibatis.cache.CacheKey, org.apache.ibatis.mapping.BoundSql) (line: 165)
   ### Steps to reproduce the behavior, such as: SQL to execute, sharding rule configuration, when exception occur etc.
   
   ### Example codes for reproduce this issue (such as a github link).
   SQL:
    
   select * from test where (id = 1 or id =2) and (id=3 or id =4 ) and (id=3 or id =4 ) and (id=3 or id =4 ) and (id=3 or id =4 ) and (id=3 or id =4 )  AND (id=3 or id =4 )  AND (id=3 or id =4 )   AND (id=3 or id =4 )   AND (id=3 or id =4 )   AND (id=3 or id =4 )  and (id=3 or id =4 ) and (id=3 or id =4 ) and (id=3 or id =4 ) and (id=3 or id =4 ) and (id=3 or id =4 )  AND (id=3 or id =4 )  AND (id=3 or id =4 )   AND (id=3 or id =4 )   AND (id=3 or id =4 )   AND (id=3 or id =4 )  and (id=3 or id =4 ) and (id=3 or id =4 ) and (id=3 or id =4 ) and (id=3 or id =4 ) and (id=3 or id =4 )  AND (id=3 or id =4 )  AND (id=3 or id =4 )   AND (id=3 or id =4 )   AND (id=3 or id =4 )   AND (id=3 or id =4 ) and (id=3 or id =4 ) and (id=3 or id =4 ) and (id=3 or id =4 ) and (id=3 or id =4 ) and (id=3 or id =4 )  AND (id=3 or id =4 )  AND (id=3 or id =4 )   AND (id=3 or id =4 )   AND (id=3 or id =4 )   AND (id=3 or id =4 )  and (id=3 or id =4 ) and (id=3 or id =4 ) and (id=3 or id =4 ) and (id=3 or i
 d =4 ) and (id=3 or id =4 )  AND (id=3 or id =4 )  AND (id=3 or id =4 )   AND (id=3 or id =4 )   AND (id=3 or id =4 )   AND (id=3 or id =4 )  and (id=3 or id =4 ) and (id=3 or id =4 ) and (id=3 or id =4 ) and (id=3 or id =4 ) and (id=3 or id =4 )  AND (id=3 or id =4 )  AND (id=3 or id =4 )   AND (id=3 or id =4 )   AND (id=3 or id =4 )   AND (id=3 or id =4 ) 
   and (id=3 or id =4 ) and (id=3 or id =4 ) and (id=3 or id =4 ) and (id=3 or id =4 ) and (id=3 or id =4 )  AND (id=3 or id =4 )  AND (id=3 or id =4 )   AND (id=3 or id =4 )   AND (id=3 or id =4 )   AND (id=3 or id =4 )  and (id=3 or id =4 ) and (id=3 or id =4 ) and (id=3 or id =4 ) and (id=3 or id =4 ) and (id=3 or id =4 )  AND (id=3 or id =4 )  AND (id=3 or id =4 )   AND (id=3 or id =4 )   AND (id=3 or id =4 )   AND (id=3 or id =4 )  and (id=3 or id =4 ) and (id=3 or id =4 ) and (id=3 or id =4 ) and (id=3 or id =4 ) and (id=3 or id =4 )  AND (id=3 or id =4 )  AND (id=3 or id =4 )   AND (id=3 or id =4 )   AND (id=3 or id =4 )   AND (id=3 or id =4 ) 
   
   
   
   


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


Re: [I] java.lang.OutOfMemoryError: GC overhead limit exceeded [shardingsphere]

Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on issue #24439:
URL: https://github.com/apache/shardingsphere/issues/24439#issuecomment-2015829343

   There hasn't been any activity on this issue recently, and in order to prioritize active issues, it will be marked as stale.


-- 
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] 794086163 commented on issue #24439: java.lang.OutOfMemoryError: GC overhead limit exceeded

Posted by "794086163 (via GitHub)" <gi...@apache.org>.
794086163 commented on issue #24439:
URL: https://github.com/apache/shardingsphere/issues/24439#issuecomment-1457340272

   > @794086163 hi,would you want to fix this issue.
   
   I fixed it, but how do I commit the code?


-- 
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] 794086163 commented on issue #24439: java.lang.OutOfMemoryError: GC overhead limit exceeded

Posted by "794086163 (via GitHub)" <gi...@apache.org>.
794086163 commented on issue #24439:
URL: https://github.com/apache/shardingsphere/issues/24439#issuecomment-1455384422

   > extractAndPredicates
   
   I don't know why SQL parses like this!!
   ![image](https://user-images.githubusercontent.com/37607959/223012665-90926270-5a0a-44de-9ca7-cbd935b48b69.png)
   


-- 
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] 794086163 closed issue #24439: java.lang.OutOfMemoryError: GC overhead limit exceeded

Posted by "794086163 (via GitHub)" <gi...@apache.org>.
794086163 closed issue #24439: java.lang.OutOfMemoryError: GC overhead limit exceeded
URL: https://github.com/apache/shardingsphere/issues/24439


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


Re: [I] java.lang.OutOfMemoryError: GC overhead limit exceeded [shardingsphere]

Posted by "RoySunnySean007 (via GitHub)" <gi...@apache.org>.
RoySunnySean007 commented on issue #24439:
URL: https://github.com/apache/shardingsphere/issues/24439#issuecomment-1871986030

   @794086163 thanks for fixing this issue, do we have the ETA to merge ur pr?


-- 
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] FlyingZC commented on issue #24439: java.lang.OutOfMemoryError: GC overhead limit exceeded

Posted by "FlyingZC (via GitHub)" <gi...@apache.org>.
FlyingZC commented on issue #24439:
URL: https://github.com/apache/shardingsphere/issues/24439#issuecomment-1454694827

   @794086163 hi,would you want to fix this issue.


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


Re: [I] java.lang.OutOfMemoryError: GC overhead limit exceeded [shardingsphere]

Posted by "tangyiming (via GitHub)" <gi...@apache.org>.
tangyiming commented on issue #24439:
URL: https://github.com/apache/shardingsphere/issues/24439#issuecomment-1867594944

   encounter the same issue, any plan to merge this into new release?


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