問題:java.lang.ClassCastException: java.lang.Integer cannot be cast to com.xxl.rpc.remoting.net.params.XxlRpcResponse
這是什麼狗屁錯誤,完全看不懂,打斷點也看不懂.....
根據定位過去,報錯就是這行代碼XxlRpcResponse xxlRpcResponse = (XxlRpcResponse)this.serializer.deserialize(responseBytes, XxlRpcResponse.class);這裏integer轉XxlRpcResponse。奇了個怪。爲啥呢。 byte[] responseBytes = ByteBufUtil.getBytes(msg.content());上面有這樣一句代碼,查看msg的值,發現status是400。em,沒調通。什麼情況,http調用不通?
大膽的猜想,可能是網絡的問題之類的吧。於是就有了以下的命令:
再次執行xxl-job調度就正確了。