Tag Archives: doubbo

[Solved] Dubbo Project Service Startup Locally Error: org.apache.dubbo.remoting.remotingexception: client (URL: dubbo://192.168.56.1:20882

org.apache.dubbo.remoting.RemotingException: client(url: dubbo://192.168.56.1:20883/com.test.dubbo.dubbo.StorageDubboService
at org.apache.dubbo.remoting.transport.netty4.NettyClient.doConnect(NettyClient.java:131)
    at org.apache.dubbo.remoting.transport.AbstractClient.connect(AbstractClient.java:186)
    at org.apache.dubbo.remoting.transport.AbstractClient.reconnect(AbstractClient.java:242)
    at org.apache.dubbo.remoting.exchange.support.header.HeaderExchangeClient.reconnect(HeaderExchangeClient.java:152)
    at org.apache.dubbo.remoting.exchange.support.header.ReconnectTimerTask.doTask(ReconnectTimerTask.java:49)
    at org.apache.dubbo.remoting.exchange.support.header.AbstractTimerTask.run(AbstractTimerTask.java:87)
    at org.apache.dubbo.common.timer.HashedWheelTimer$HashedWheelTimeout.expire(HashedWheelTimer.java:648)
    at org.apache.dubbo.common.timer.HashedWheelTimer$HashedWheelBucket.expireTimeouts(HashedWheelTimer.java:727)
    at org.apache.dubbo.common.timer.HashedWheelTimer$Worker.run(HashedWheelTimer.java:449)
    at java.lang.Thread.run(Thread.java:745)
Caused by: io.netty.channel.AbstractChannel$AnnotatedConnectException: Connection refused: no further information: /192.168.56.1:20883
Caused by: java.net.ConnectException: Connection refused: no further information

Today, I reported the above error in debugging a local Dubbo project. After checking the online answer, there are two solutions as follows:

1. Change the host of the configured Dubbo to the IP of your local network card (it should be noted that some friends may have several adapter network IP (for example, they are connected to the wireless), and this error message will also include the same error message of your wireless address IP, but if your producer and consumer debug on the same device, it will not affect the registration call)

2. The configuration in the configuration file (YML or properties) is as follows:

dubbo.protocol.host=192.168.56.1 

It is important to note that both consumer and producer configurations should be added!

[Solved] Dubbo Error: Failed to invoke the method…

Background: There are two microservices, one is the house service and the other is the pms service, which are called remotely through dubbo.

Now a List<OrderChildVo> getOrderChildList(OrderParam param) method has been added under OrderService in pms service, and the version number has been upgraded to 2.0.3.

The new getOrderChildList method added in pms needs to be called in the house service.

 

Encountered problems: error Failed to invoke the method getOrderChildList …… NullPointerException

 

Troubleshooting process: 1. Check that the version number of the pms dependency in the house is 2.0.3

2. In the producer configuration file of pms, the OrderService is published. In the consumer configuration file in house, OrderService is also subscribed. There are also configuration groups.

3. In the class of the service used in the house, the OrderService is injected with the @Resource annotation

4. Log in to the dubbo client, and the producer sees that the getOrderChildList method has provided services normally. The subscription of house in the consumer list also subscribes to the getOrderChildList method normally. Also restarted zookeeper

5. Another old method called OrderService.getOrderListByCondition() was called in the house, and it was found that no error was reported and it could be used normally. Through this step, it can be determined that the problem lies in the getOrderChildList method itself.

 

The final problem: Finally, it was discovered that the entity class OrderChildVo of the return value of this method did not implement the serialization interface Serializable.