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 2021/11/20 13:52:01 UTC

[GitHub] [dubbo-samples] duansheli opened a new issue #396: Triple 可以与 Hessian 一起用吗

duansheli opened a new issue #396:
URL: https://github.com/apache/dubbo-samples/issues/396


   文档里只有 Triple + protobuf 的教程
   ![image](https://user-images.githubusercontent.com/8579595/142728771-4deb8a91-99f2-4cb0-92c7-2dd7ae9d0019.png)
   
   没看到 Triple 协议 Hessian 序列化方式 的例子 


-- 
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-samples] guohao commented on issue #396: Triple 可以与 Hessian 一起用吗

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


   可以的,设置对应的序列化类型即可
   
   > @guohao
   
   


-- 
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-samples] AlbumenJ commented on issue #396: Triple 可以与 Hessian 一起用吗

Posted by GitBox <gi...@apache.org>.
AlbumenJ commented on issue #396:
URL: https://github.com/apache/dubbo-samples/issues/396#issuecomment-998844420


   @duansheli 加一下 protobuf 的依赖
   ```xml
           <dependency>
               <groupId>com.google.protobuf</groupId>
               <artifactId>protobuf-java</artifactId>
               <version>3.14.0</version>
           </dependency>
   
   ```


-- 
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-samples] duansheli commented on issue #396: Triple 可以与 Hessian 一起用吗

Posted by GitBox <gi...@apache.org>.
duansheli commented on issue #396:
URL: https://github.com/apache/dubbo-samples/issues/396#issuecomment-974653571


   @guohao 


-- 
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-samples] duansheli commented on issue #396: Triple 可以与 Hessian 一起用吗

Posted by GitBox <gi...@apache.org>.
duansheli commented on issue #396:
URL: https://github.com/apache/dubbo-samples/issues/396#issuecomment-974653571


   @guohao 


-- 
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-samples] duansheli commented on issue #396: Triple 可以与 Hessian 一起用吗

Posted by GitBox <gi...@apache.org>.
duansheli commented on issue #396:
URL: https://github.com/apache/dubbo-samples/issues/396#issuecomment-977648529


   用的配置 
   ```
   dubbo.protocol.name=tri
   dubbo.protocol.serialization=hessian2
   dubbo.provider.serialization=hessian2
   dubbo.provider.protocol=tri
   ```
   
   启动 provider 失败,报错 
   ```
   Extension instance (name: tri, class: interface org.apache.dubbo.rpc.Protocol) couldn't be instantiated: null  
   
   Caused by: java.lang.NoClassDefFoundError: com/google/protobuf/MessageOrBuilder
   	at java.base/java.lang.ClassLoader.defineClass1(Native Method) ~[na:na]
   	at java.base/java.lang.ClassLoader.defineClass(ClassLoader.java:1012) ~[na:na]
   	at java.base/java.security.SecureClassLoader.defineClass(SecureClassLoader.java:150) ~[na:na]
   	at java.base/jdk.internal.loader.BuiltinClassLoader.defineClass(BuiltinClassLoader.java:862) ~[na:na]
   	at java.base/jdk.internal.loader.BuiltinClassLoader.findClassOnClassPathOrNull(BuiltinClassLoader.java:760) ~[na:na]
   	at java.base/jdk.internal.loader.BuiltinClassLoader.loadClassOrNull(BuiltinClassLoader.java:681) ~[na:na]
   	at java.base/jdk.internal.loader.BuiltinClassLoader.loadClass(BuiltinClassLoader.java:639) ~[na:na]
   	at java.base/jdk.internal.loader.ClassLoaders$AppClassLoader.loadClass(ClassLoaders.java:188) ~[na:na]
   	at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:520) ~[na:na]
   	at java.base/java.lang.ClassLoader.defineClass1(Native Method) ~[na:na]
   	at java.base/java.lang.ClassLoader.defineClass(ClassLoader.java:1012) ~[na:na]
   	at java.base/java.security.SecureClassLoader.defineClass(SecureClassLoader.java:150) ~[na:na]
   	at java.base/jdk.internal.loader.BuiltinClassLoader.defineClass(BuiltinClassLoader.java:862) ~[na:na]
   	at java.base/jdk.internal.loader.BuiltinClassLoader.findClassOnClassPathOrNull(BuiltinClassLoader.java:760) ~[na:na]
   	at java.base/jdk.internal.loader.BuiltinClassLoader.loadClassOrNull(BuiltinClassLoader.java:681) ~[na:na]
   	at java.base/jdk.internal.loader.BuiltinClassLoader.loadClass(BuiltinClassLoader.java:639) ~[na:na]
   	at java.base/jdk.internal.loader.ClassLoaders$AppClassLoader.loadClass(ClassLoaders.java:188) ~[na:na]
   	at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:520) ~[na:na]
   	at grpc.health.v1.HealthDubbo.init(HealthDubbo.java:12) ~[dubbo-3.0.4.jar:3.0.4]
   	at grpc.health.v1.Health.<clinit>(Health.java:12) ~[dubbo-3.0.4.jar:3.0.4]
   	at org.apache.dubbo.rpc.protocol.tri.service.TriBuiltinService.<init>(TriBuiltinService.java:58) ~[dubbo-3.0.4.jar:3.0.4]
   	at org.apache.dubbo.rpc.protocol.tri.TripleProtocol.<init>(TripleProtocol.java:49) ~[dubbo-3.0.4.jar:3.0.4]
   	... 35 common frames omitted
   ```
   protocol 设置成  dubbo 
   就能正常启动 
   


-- 
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-samples] guohao closed issue #396: Triple 可以与 Hessian 一起用吗

Posted by GitBox <gi...@apache.org>.
guohao closed issue #396:
URL: https://github.com/apache/dubbo-samples/issues/396


   


-- 
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