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/09/08 07:18:01 UTC

[GitHub] [shardingsphere] qudonghui opened a new issue, #20878: Use scaling feature with mysql 8.x are EXECUTE_INCREMENTAL_TASK_FAILURE

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

   ### Which version of ShardingSphere did you use?
   docker  apache/shardingsphere-proxy   latest
   
   ### Which project did you use? ShardingSphere-JDBC or ShardingSphere-Proxy?
   ShardingSphere-Proxy
   
   ### Actual behavior
   ![image](https://user-images.githubusercontent.com/39752827/189056177-41d89bc8-5353-4efa-a871-95615bad4393.png)
   
   ### Steps to reproduce the behavior, such as: SQL to execute, sharding rule configuration, when exception occur etc.
   ```
   mysql> use sharding_db;
   Database changed
   
   mysql> CREATE SHARDING TABLE RULE oms_order_basic_info (
       -> DATANODES("oms_0.oms_order_basic_info"),
       -> DATABASE_STRATEGY(TYPE=standard,SHARDING_COLUMN=data_route,SHARDING_ALGORITHM=database_inline)
       -> );
   Query OK, 0 rows affected (0.29 sec)
   
   ## ADD RESOURCE  pass
   
   mysql> show sharding algorithms;
   +-----------------+-------------+-----------------------------------------------------------------------------------------------+
   | name            | type        | props                                                                                         |
   +-----------------+-------------+-----------------------------------------------------------------------------------------------+
   | database_inline | CLASS_BASED | algorithmClassName=com.mengfan.shardingsphere.algorithm.DbStandardAlgorithm,strategy=STANDARD |
   +-----------------+-------------+-----------------------------------------------------------------------------------------------+
   1 row in set (0.00 sec)
   
   mysql> ALTER SHARDING TABLE RULE oms_order_basic_info (
       -> DATANODES("oms-$->{2021..2022}-$->{1..4}.oms_order_basic_info"),
       -> DATABASE_STRATEGY(TYPE=standard,SHARDING_COLUMN=data_route,SHARDING_ALGORITHM=database_inline)
       -> );
   Query OK, 0 rows affected (0.08 sec)
   
   
   mysql> show scaling list;
   +----------------------------------------------+----------------------+----------------------+--------+---------------------+-----------+
   | id                                           | tables               | sharding_total_count | active | create_time         | stop_time |
   +----------------------------------------------+----------------------+----------------------+--------+---------------------+-----------+
   | 0130317c30317c3054317c7368617264696e675f6462 | oms_order_basic_info | 1                    | true   | 2022-09-08 06:22:55 | NULL      |
   +----------------------------------------------+----------------------+----------------------+--------+---------------------+-----------+
   1 row in set (0.02 sec)
   
   mysql> show scaling status 0130317c30317c3054317c7368617264696e675f6462;
   +------+-------------+----------------------------------+--------+-------------------------------+--------------------------+
   | item | data_source | status                           | active | inventory_finished_percentage | incremental_idle_seconds |
   +------+-------------+----------------------------------+--------+-------------------------------+--------------------------+
   | 0    | oms_0       | EXECUTE_INCREMENTAL_TASK_FAILURE | true   | 100                           | 1670                     |
   +------+-------------+----------------------------------+--------+-------------------------------+--------------------------+
   1 row in set (0.01 sec)
   
   ```
   ### Exception
   ```
   java.lang.RuntimeException: java.util.concurrent.ExecutionException: java.lang.RuntimeException: Bad handshake
           at org.apache.shardingsphere.data.pipeline.mysql.ingest.client.MySQLClient.waitExpectedResponse(MySQLClient.java:218)
           at org.apache.shardingsphere.data.pipeline.mysql.ingest.client.MySQLClient.connect(MySQLClient.java:95)
           at org.apache.shardingsphere.data.pipeline.mysql.ingest.MySQLIncrementalDumper.dump(MySQLIncrementalDumper.java:95)
           at org.apache.shardingsphere.data.pipeline.mysql.ingest.MySQLIncrementalDumper.doStart(MySQLIncrementalDumper.java:87)
           at org.apache.shardingsphere.data.pipeline.api.executor.AbstractLifecycleExecutor.start(AbstractLifecycleExecutor.java:41)
           at org.apache.shardingsphere.data.pipeline.core.task.IncrementalTask.doStart(IncrementalTask.java:85)
           at org.apache.shardingsphere.data.pipeline.api.executor.AbstractLifecycleExecutor.start(AbstractLifecycleExecutor.java:41)
           at org.apache.shardingsphere.data.pipeline.api.executor.AbstractLifecycleExecutor.run(AbstractLifecycleExecutor.java:61)
           at java.base/java.util.concurrent.CompletableFuture$AsyncRun.run(CompletableFuture.java:1804)
           at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136)
           at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635)
           at java.base/java.lang.Thread.run(Thread.java:833)
   Caused by: java.util.concurrent.ExecutionException: java.lang.RuntimeException: Bad handshake
           at io.netty.util.concurrent.DefaultPromise.get(DefaultPromise.java:350)
           at org.apache.shardingsphere.data.pipeline.mysql.ingest.client.MySQLClient.waitExpectedResponse(MySQLClient.java:206)
           ... 11 common frames omitted
   Caused by: java.lang.RuntimeException: Bad handshake
           at org.apache.shardingsphere.data.pipeline.mysql.ingest.client.netty.MySQLNegotiateHandler.channelRead(MySQLNegotiateHandler.java:100)
           at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379)
           at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365)
           at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:357)
           at io.netty.handler.codec.ByteToMessageDecoder.channelRead(ByteToMessageDecoder.java:305)
           at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379)
           at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365)
           at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:357)
           at io.netty.handler.codec.ByteToMessageDecoder.fireChannelRead(ByteToMessageDecoder.java:327)
           at io.netty.handler.codec.ByteToMessageDecoder.channelRead(ByteToMessageDecoder.java:299)
           at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379)
           at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365)
           at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:357)
           at io.netty.handler.codec.ByteToMessageDecoder.fireChannelRead(ByteToMessageDecoder.java:327)
           at io.netty.handler.codec.ByteToMessageDecoder.channelRead(ByteToMessageDecoder.java:299)
           at io.netty.handler.codec.ByteToMessageCodec.channelRead(ByteToMessageCodec.java:103)
           at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379)
           at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365)
           at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:357)
           at io.netty.channel.DefaultChannelPipeline$HeadContext.channelRead(DefaultChannelPipeline.java:1410)
           at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379)
           at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365)
           at io.netty.channel.DefaultChannelPipeline.fireChannelRead(DefaultChannelPipeline.java:919)
           at io.netty.channel.nio.AbstractNioByteChannel$NioByteUnsafe.read(AbstractNioByteChannel.java:166)
           at io.netty.channel.nio.NioEventLoop.processSelectedKey(NioEventLoop.java:722)
           at io.netty.channel.nio.NioEventLoop.processSelectedKeysOptimized(NioEventLoop.java:658)
           at io.netty.channel.nio.NioEventLoop.processSelectedKeys(NioEventLoop.java:584)
           at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:496)
           at io.netty.util.concurrent.SingleThreadEventExecutor$4.run(SingleThreadEventExecutor.java:986)
           at io.netty.util.internal.ThreadExecutorMap$2.run(ThreadExecutorMap.java:74)
           at io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30)
           ... 1 common frames omitted
   ```
   
   ### Mysql Configuration
   ```
   
   mysql> show variables like '%log_bin%';
   +---------------------------------+------------------------------------------+
   | Variable_name                   | Value                                    |
   +---------------------------------+------------------------------------------+
   | log_bin                         | ON                                       |
   | log_bin_basename                | /docker/local/mysql/data/mysql-bin       |
   | log_bin_index                   | /docker/local/mysql/data/mysql-bin.index |
   | log_bin_trust_function_creators | OFF                                      |
   | log_bin_use_v1_row_events       | OFF                                      |
   | sql_log_bin                     | ON                                       |
   +---------------------------------+------------------------------------------+
   6 rows in set (0.00 sec)
   
   mysql> show variables like '%binlog%';
   +------------------------------------------------+----------------------+
   | Variable_name                                  | Value                |
   +------------------------------------------------+----------------------+
   | binlog_cache_size                              | 32768                |
   | binlog_checksum                                | CRC32                |
   | binlog_direct_non_transactional_updates        | OFF                  |
   | binlog_encryption                              | OFF                  |
   | binlog_error_action                            | ABORT_SERVER         |
   | binlog_expire_logs_seconds                     | 0                    |
   | binlog_format                                  | ROW                  |
   | binlog_group_commit_sync_delay                 | 0                    |
   | binlog_group_commit_sync_no_delay_count        | 0                    |
   | binlog_gtid_simple_recovery                    | ON                   |
   | binlog_max_flush_queue_time                    | 0                    |
   | binlog_order_commits                           | ON                   |
   | binlog_rotate_encryption_master_key_at_startup | OFF                  |
   | binlog_row_event_max_size                      | 8192                 |
   | binlog_row_image                               | FULL                 |
   | binlog_row_metadata                            | MINIMAL              |
   | binlog_row_value_options                       |                      |
   | binlog_rows_query_log_events                   | OFF                  |
   | binlog_stmt_cache_size                         | 32768                |
   | binlog_transaction_compression                 | OFF                  |
   | binlog_transaction_compression_level_zstd      | 3                    |
   | binlog_transaction_dependency_history_size     | 25000                |
   | binlog_transaction_dependency_tracking         | COMMIT_ORDER         |
   | innodb_api_enable_binlog                       | OFF                  |
   | log_statements_unsafe_for_binlog               | ON                   |
   | max_binlog_cache_size                          | 18446744073709547520 |
   | max_binlog_size                                | 134217728            |
   | max_binlog_stmt_cache_size                     | 18446744073709547520 |
   | sync_binlog                                    | 1                    |
   +------------------------------------------------+----------------------+
   
   
   mysql> select version();
   +-----------+
   | version() |
   +-----------+
   | 8.0.23    |
   +-----------+
   1 row in set (0.00 sec)
   
   
   mysql> show variables like 'default_authentication_plugin';
   +-------------------------------+-----------------------+
   | Variable_name                 | Value                 |
   +-------------------------------+-----------------------+
   | default_authentication_plugin | caching_sha2_password |
   +-------------------------------+-----------------------+
   1 row in set (0.02 sec)
   
   
   mysql> select host,user,plugin from mysql.user;
   +-----------+------------------+-----------------------+
   | host      | user             | plugin                |
   +-----------+------------------+-----------------------+
   | %         | root             | mysql_native_password |
   | localhost | mysql.infoschema | caching_sha2_password |
   | localhost | mysql.session    | caching_sha2_password |
   | localhost | mysql.sys        | caching_sha2_password |
   | localhost | root             | mysql_native_password |
   +-----------+------------------+-----------------------+
   5 rows in set (0.00 sec)
   
   ```
   
   


-- 
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] azexcy commented on issue #20878: Use scaling feature with mysql 8.x are EXECUTE_INCREMENTAL_TASK_FAILURE

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

   @qudonghui  
   hello, the issue is similar to  https://github.com/apache/shardingsphere/issues/17092
   the `default_authentication_plugin` is caching_sha2_password,  but the account of root is `mysql_native_password`, they are not equal, if use scaling, please make them equal now


-- 
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] github-actions[bot] commented on issue #20878: Use scaling feature with mysql 8.x are EXECUTE_INCREMENTAL_TASK_FAILURE

Posted by GitBox <gi...@apache.org>.
github-actions[bot] commented on issue #20878:
URL: https://github.com/apache/shardingsphere/issues/20878#issuecomment-1272348519

   Hello , this issue has not received a reply for several days.
   This issue is supposed to be closed.


-- 
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] azexcy commented on issue #20878: Use scaling feature with mysql 8.x are EXECUTE_INCREMENTAL_TASK_FAILURE

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

   @qudonghui 
   I see that a custom sharding algorithm is used here, maybe it's need proxy meta data, so you can try executing `REFRESH TABLE METADATA;` firstly, before `check migration` DistSQL


-- 
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] qudonghui commented on issue #20878: Use scaling feature with mysql 8.x are EXECUTE_INCREMENTAL_TASK_FAILURE

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

   这是来自QQ邮箱的假期自动回复邮件。
    
   您好,我最近正在休假中,无法亲自回复您的邮件。我将在假期结束后,尽快给您回复。


-- 
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] github-actions[bot] closed issue #20878: Use scaling feature with mysql 8.x are EXECUTE_INCREMENTAL_TASK_FAILURE

Posted by GitBox <gi...@apache.org>.
github-actions[bot] closed issue #20878: Use scaling feature with mysql 8.x are EXECUTE_INCREMENTAL_TASK_FAILURE
URL: https://github.com/apache/shardingsphere/issues/20878


-- 
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] qudonghui commented on issue #20878: Use scaling feature with mysql 8.x are EXECUTE_INCREMENTAL_TASK_FAILURE

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

   Thank you for your reply. When I modify the default_ authentication_ After the plugin, the sclaling status is always in
   EXECUTE_INCREMENTAL_TASK
   ![image](https://user-images.githubusercontent.com/39752827/189075154-31a8f62b-bbf1-4fea-b09e-39b3f1465847.png)
   
   ![image](https://user-images.githubusercontent.com/39752827/189075274-3b011672-638b-49c7-9a33-27a86d733ad9.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