Pre-check
- [x] I am sure that all the content I provide is in English.
Search before asking
- [x] I had searched in the issues and found no similar issues.
Apache Dubbo Component
Java Samples (apache/dubbo-samples)
Dubbo Version
When changing the protocol of the Callback example in https://github.com/apache/dubbo-samples/tree/master/2-advanced/dubbo-samples-callback to use the Triple protocol the following error is thrown by the Consumer
Caused by: java.lang.UnsupportedOperationException: ObjectDeserializer[interface org.apache.dubbo.samples.callback.api.CallbackListener]
at com.alibaba.com.caucho.hessian.io.ObjectDeserializer.readObject(ObjectDeserializer.java:76)
at com.alibaba.com.caucho.hessian.io.AbstractDeserializer.readObject(AbstractDeserializer.java:127)
at com.alibaba.com.caucho.hessian.io.Hessian2Input.readObjectInstance(Hessian2Input.java:2956)
at com.alibaba.com.caucho.hessian.io.Hessian2Input.readObject(Hessian2Input.java:2289)
at com.alibaba.com.caucho.hessian.io.Hessian2Input.readObject(Hessian2Input.java:2218)
at com.alibaba.com.caucho.hessian.io.Hessian2Input.readObject(Hessian2Input.java:2262)
at com.alibaba.com.caucho.hessian.io.Hessian2Input.readObject(Hessian2Input.java:2218)
at org.apache.dubbo.common.serialize.hessian2.Hessian2ObjectInput.readObject(Hessian2ObjectInput.java:118)
at org.apache.dubbo.common.serialize.DefaultSerializationExceptionWrapper$ProxyObjectInput.readObject(DefaultSerializationExceptionWrapper.java:161)
Steps to reproduce this issue
1) Change Provider https://github.com/apache/dubbo-samples/blob/master/2-advanced/dubbo-samples-callback/dubbo-samples-callback-provider/src/main/resources/application.yml to use the Triple protocol e.g.
dubbo:
application:
name: callback-provider
serialize-check-status: DISABLE
check-serializable: false
registry:
address: zookeeper://${zookeeper.address:127.0.0.1}:2181
protocol:
name: tri
#name: dubbo
port: 20880
provider:
token: true
callbacks: 1000
2) Change Consumer https://github.com/apache/dubbo-samples/blob/master/2-advanced/dubbo-samples-callback/dubbo-samples-callback-consumer/src/main/resources/application.yml to use the Triple protocol e.g.
dubbo:
application:
name: callback-consumer
qos-enable: false
serialize-check-status: DISABLE
check-serializable: false
protocol:
name: tri
#name: dubbo
port: -1
registry:
address: zookeeper://${zookeeper.address:127.0.0.1}:2181
The following exception is thrown by the Consumer
Caused by: java.lang.UnsupportedOperationException: ObjectDeserializer[interface org.apache.dubbo.samples.callback.api.CallbackListener]
at com.alibaba.com.caucho.hessian.io.ObjectDeserializer.readObject(ObjectDeserializer.java:76)
at com.alibaba.com.caucho.hessian.io.AbstractDeserializer.readObject(AbstractDeserializer.java:127)
at com.alibaba.com.caucho.hessian.io.Hessian2Input.readObjectInstance(Hessian2Input.java:2956)
at com.alibaba.com.caucho.hessian.io.Hessian2Input.readObject(Hessian2Input.java:2289)
at com.alibaba.com.caucho.hessian.io.Hessian2Input.readObject(Hessian2Input.java:2218)
at com.alibaba.com.caucho.hessian.io.Hessian2Input.readObject(Hessian2Input.java:2262)
at com.alibaba.com.caucho.hessian.io.Hessian2Input.readObject(Hessian2Input.java:2218)
at org.apache.dubbo.common.serialize.hessian2.Hessian2ObjectInput.readObject(Hessian2ObjectInput.java:118)
at org.apache.dubbo.common.serialize.DefaultSerializationExceptionWrapper$ProxyObjectInput.readObject(DefaultSerializationExceptionWrapper.java:161)
What you expected to happen
I would expect the same behaviour as when the protocol is set to dubbo e.g Consumer log file to display
Changed: 2025-06-18 08:16:02
Changed: 2025-06-18 08:16:04
Changed: 2025-06-18 08:16:09
Changed: 2025-06-18 08:16:14
Anything else
No response
Are you willing to submit a pull request to fix on your own?
- [ ] Yes I am willing to submit a pull request on my own!
Code of Conduct
- [x] I agree to follow this project's Code of Conduct
Comment From: RainYuY
I believe this is a missing feature. If confirmed, I will try to implement the callback functionality for the Triple protocol later. @oxsean @AlbumenJ PTAL
Comment From: RainYuY
Callback is not currently planned for Triple. If your use case requires similar functionality, we recommend considering the stream mode as an alternative.