接口 ObjectOutput

  • 所有超级接口:
    DataOutput

    public interface ObjectOutput
    extends DataOutput
    Object output interface.
    • 方法详细资料

      • writeThrowable

        default void writeThrowable​(Object obj)
                             throws IOException
        The following methods are customized for the requirement of Dubbo's RPC protocol implementation. Legacy protocol implementation will try to write Map, Throwable and Null value directly to the stream, which does not meet the restrictions of all serialization protocols.

        See how ProtobufSerialization, KryoSerialization implemented these methods for more details.

        The binding of RPC protocol and biz serialization protocol is not a good practice. Encoding of RPC protocol should be highly independent and portable, easy to cross platforms and languages, for example, like the http headers, restricting the content of headers / attachments to Ascii strings and uses ISO_8859_1 to encode them. https://tools.ietf.org/html/rfc7540#section-8.1.2

        抛出:
        IOException