You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@dubbo.apache.org by GitBox <gi...@apache.org> on 2022/03/15 15:36:57 UTC

[GitHub] [dubbo] luger1990 opened a new issue #9790: Received inconsistent serialization type from client, reject to deserialize! Expected:hessian2 Actual:xxx

luger1990 opened a new issue #9790:
URL: https://github.com/apache/dubbo/issues/9790


   使用spring boot + dubbo3 + triple协议,消费者端调用报错:
   Received inconsistent serialization type from client, reject to deserialize! Expected:hessian2 Actual:
   
   provider端配置如下:
   ```
   server:
     port: 8881
   spring:
     application:
       name: dubbo-grpc-provider
     profiles:
       active: dev
     main:
       allow-bean-definition-overriding: true
   dubbo:
     application:
       name: ${spring.application.name}
       id: ${spring.application.name}
       register-mode: instance
     registry:
       address: nacos://127.0.0.1:8848
     scan:
       base-packages: me.luger
     protocol:
       name: tri
       port: 20880
       accesslog: true
     monitor:
       protocol: registry
   ```
   
   consumer端配置如下:
   ```
   server:
     port: 8882
   spring:
     application:
       name: dubbo-grpc-consumer
     profiles:
       active: dev
     main:
       allow-bean-definition-overriding: true
   dubbo:
     application:
       name: ${spring.application.name}
       id: ${spring.application.name}
       register-mode: instance
     registry:
       address: nacos://127.0.0.1:8848
     cloud:
       subscribed-services: dubbo-grpc-provider
     consumer:
       timeout: 3000
   ```
   
   详细报错如下:
   
   > org.apache.dubbo.rpc.RpcException: Received inconsistent serialization type from client, reject to deserialize! Expected:hessian2 Actual:taylor
   > 	at org.apache.dubbo.rpc.protocol.tri.AbstractClientStream.getThrowableFromTrailers(AbstractClientStream.java:188) ~[dubbo-3.0.6.jar:3.0.6]
   > 	at org.apache.dubbo.rpc.protocol.tri.UnaryClientStream$ClientUnaryInboundTransportObserver.onError(UnaryClientStream.java:86) ~[dubbo-3.0.6.jar:3.0.6]
   > 	at org.apache.dubbo.rpc.protocol.tri.UnaryClientStream$ClientUnaryInboundTransportObserver.lambda$onComplete$0(UnaryClientStream.java:56) ~[dubbo-3.0.6.jar:3.0.6]
   > 	at org.apache.dubbo.common.threadpool.serial.SerializingExecutor.run(SerializingExecutor.java:99) ~[dubbo-3.0.6.jar:3.0.6]
   > 	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) ~[na:1.8.0_191]
   > 	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) ~[na:1.8.0_191]
   > 	at org.apache.dubbo.common.threadlocal.InternalRunnable.run(InternalRunnable.java:41) ~[dubbo-3.0.6.jar:3.0.6]
   > 	at java.lang.Thread.run(Thread.java:748) [na:1.8.0_191]
   
   
   ps:还有个问题,为什么消费者和提供者都启动之后再nacos中只有生产者中可以看到数据。如下图
   ![image](https://user-images.githubusercontent.com/2096878/158414378-b03e9c79-7c9b-4eb5-a42c-b01a427c5300.png)
   ![image](https://user-images.githubusercontent.com/2096878/158414461-e2a929ef-c182-43e9-a9ce-13421efdf526.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@dubbo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo] chickenlj closed issue #9790: Received inconsistent serialization type from client, reject to deserialize! Expected:hessian2 Actual:xxx

Posted by GitBox <gi...@apache.org>.
chickenlj closed issue #9790:
URL: https://github.com/apache/dubbo/issues/9790


   


-- 
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@dubbo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo] vio-lin commented on issue #9790: Received inconsistent serialization type from client, reject to deserialize! Expected:hessian2 Actual:xxx

Posted by GitBox <gi...@apache.org>.
vio-lin commented on issue #9790:
URL: https://github.com/apache/dubbo/issues/9790#issuecomment-1069989121


   是不是ip一样然后服务端重启了。因为客户端有段逻辑会缓存以前链接过的client
   我记得有版本会把这个url给缓存起来。 按着ip+端口 缓存一个url。
   我们遇到过然后把不同序列化格式服务开在不同的端口上。


-- 
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@dubbo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo] guohao commented on issue #9790: Received inconsistent serialization type from client, reject to deserialize! Expected:hessian2 Actual:xxx

Posted by GitBox <gi...@apache.org>.
guohao commented on issue #9790:
URL: https://github.com/apache/dubbo/issues/9790#issuecomment-1070308633


   看起来是读取了header 里的序列化方式,尝试下 3.0.7-SNAPSHOT 版本


-- 
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@dubbo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org