cowcomic opened a new issue #9733: URL: https://github.com/apache/shardingsphere/issues/9733
## Bug Report ### Which version of ShardingSphere did you use? 5.0.0-RC1-SNAPSHOT build from git master ### Which project did you use? ShardingSphere-JDBC or ShardingSphere-Proxy? shardingsphere-scaling ### Expected behavior I want to move data from one Sharding to another Sharding ### Actual behavior I make a curl post like this. edit by demo from https://shardingsphere.apache.org/document/current/cn/user-manual/shardingsphere-scaling/usage/ ```curl -X POST \ http://localhost:8888/scaling/job/start \ -H 'content-type: application/json' \ -d '{ "ruleConfiguration": { "source": { "type": "shardingSphereJdbc", "parameter": { "dataSource":" dataSources: ds_0: dataSourceClassName: com.zaxxer.hikari.HikariDataSource props: driverClassName: com.mysql.jdbc.Driver jdbcUrl: jdbc:mysql://192.168.0.142:3306/aaaa?serverTimezone=UTC&useSSL=false username: root password: xxx ds_1: dataSourceClassName: com.zaxxer.hikari.HikariDataSource props: driverClassName: com.mysql.jdbc.Driver jdbcUrl: jdbc:mysql://192.168.0.88:3306/aaaa?serverTimezone=UTC&useSSL=false username: root password: xxx ", "rule":" rules: tables: t_calabash_label: actualDataNodes: ds_${0..1}.t_calabash_label_${0..7} inline: shardingColumn: USERID algorithmExpression: ds_${USERID.toLong() & 0x01} tableStrategy: inline: shardingColumn: USERID algorithmExpression: t_calabash_label_${USERID.toLong() % 8} " } }, "target": { "type": "shardingSphereJdbc", "parameter": { "username": "root", "password": "xxx", "jdbcUrl": "jdbc:mysql://192.168.0.227:3307/aaaa?useUnicode=true&characterEncoding=UTF-8&serverTimezone=Asia/Shanghai" } } }, "jobConfiguration":{ "concurrency":"3" } }' ``` http response is `{"success":false,"errorCode":500,"errorMsg":"java.lang.NullPointerException","model":null}` and server log Exception ``` [INFO ] 2021-03-18 18:42:12.569 [nioEventLoopGroup-2-1] i.n.handler.logging.LoggingHandler - [id: 0xb23471bd, L:/0.0.0.0:8888] READ: [id: 0x63970fc8, L:/127.0.0.1:8888 - R:/127.0.0.1:40004] [INFO ] 2021-03-18 18:42:12.569 [nioEventLoopGroup-2-1] i.n.handler.logging.LoggingHandler - [id: 0xb23471bd, L:/0.0.0.0:8888] READ COMPLETE [INFO ] 2021-03-18 18:42:12.570 [nioEventLoopGroup-3-4] o.a.s.scaling.web.HttpServerHandler - Http request path: /scaling/job/start [INFO ] 2021-03-18 18:42:12.570 [nioEventLoopGroup-3-4] o.a.s.scaling.web.HttpServerHandler - Http request body: { "ruleConfiguration": { "source": { "type": "shardingSphereJdbc", "parameter": { "dataSource":" dataSources: ds_0: dataSourceClassName: com.zaxxer.hikari.HikariDataSource props: driverClassName: com.mysql.jdbc.Driver jdbcUrl: jdbc:mysql://192.168.0.142:3306/aaaa?serverTimezone=UTC&useSSL=false username: root password: xxx ds_1: dataSourceClassName: com.zaxxer.hikari.HikariDataSource props: driverClassName: com.mysql.jdbc.Driver jdbcUrl: jdbc:mysql://192.168.0.88:3306/aaaa?serverTimezone=UTC&useSSL=false username: root password: xxx ", "rule":" rules: tables: t_calabash_label: actualDataNodes: ds_${0..1}.t_calabash_label_${0..7} inline: shardingColumn: USERID algorithmExpression: ds_${USERID.toLong() & 0x01} tableStrategy: inline: shardingColumn: USERID algorithmExpression: t_calabash_label_${USERID.toLong() % 8} " } }, "target": { "type": "shardingSphereJdbc", "parameter": { "username": "root", "password": "xxx", "jdbcUrl": "jdbc:mysql://192.168.0.227:3307/aaaa?useUnicode=true&characterEncoding=UTF-8&serverTimezone=Asia/Shanghai" } } }, "jobConfiguration":{ "concurrency":"3" } } [ERROR] 2021-03-18 18:42:12.571 [nioEventLoopGroup-3-4] o.a.s.scaling.web.HttpServerHandler - Http request handle occur error: java.lang.NullPointerException: null at org.apache.shardingsphere.scaling.core.util.JobConfigurationUtil.fillInProperties(JobConfigurationUtil.java:95) at org.apache.shardingsphere.scaling.core.api.impl.ScalingAPIImpl.start(ScalingAPIImpl.java:84) at org.apache.shardingsphere.scaling.web.HttpServerHandler.startJob(HttpServerHandler.java:92) at org.apache.shardingsphere.scaling.web.HttpServerHandler.channelRead0(HttpServerHandler.java:65) at org.apache.shardingsphere.scaling.web.HttpServerHandler.channelRead0(HttpServerHandler.java:51) at io.netty.channel.SimpleChannelInboundHandler.channelRead(SimpleChannelInboundHandler.java:99) at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:377) at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:363) at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:355) at io.netty.handler.codec.MessageToMessageDecoder.channelRead(MessageToMessageDecoder.java:102) at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:377) at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:363) at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:355) at io.netty.channel.CombinedChannelDuplexHandler$DelegatingChannelHandlerContext.fireChannelRead(CombinedChannelDuplexHandler.java:436) at io.netty.handler.codec.ByteToMessageDecoder.fireChannelRead(ByteToMessageDecoder.java:321) at io.netty.handler.codec.ByteToMessageDecoder.channelRead(ByteToMessageDecoder.java:295) at io.netty.channel.CombinedChannelDuplexHandler.channelRead(CombinedChannelDuplexHandler.java:251) at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:377) at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:363) at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:355) at io.netty.channel.DefaultChannelPipeline$HeadContext.channelRead(DefaultChannelPipeline.java:1410) at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:377) at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:363) at io.netty.channel.DefaultChannelPipeline.fireChannelRead(DefaultChannelPipeline.java:919) at io.netty.channel.nio.AbstractNioByteChannel$NioByteUnsafe.read(AbstractNioByteChannel.java:163) at io.netty.channel.nio.NioEventLoop.processSelectedKey(NioEventLoop.java:714) at io.netty.channel.nio.NioEventLoop.processSelectedKeysOptimized(NioEventLoop.java:650) at io.netty.channel.nio.NioEventLoop.processSelectedKeys(NioEventLoop.java:576) at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:493) at io.netty.util.concurrent.SingleThreadEventExecutor$4.run(SingleThreadEventExecutor.java:989) at io.netty.util.internal.ThreadExecutorMap$2.run(ThreadExecutorMap.java:74) at io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30) at java.lang.Thread.run(Thread.java:748) ``` ---------------------------------------------------------------- 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: [email protected]
