Enum RPCMessage.Type

    • Enum Constant Detail

      • RPC_LOCAL_BLOCK_OPEN_REQUEST

        public static final RPCMessage.Type RPC_LOCAL_BLOCK_OPEN_REQUEST
      • RPC_LOCAL_BLOCK_OPEN_RESPONSE

        public static final RPCMessage.Type RPC_LOCAL_BLOCK_OPEN_RESPONSE
      • RPC_LOCAL_BLOCK_CLOSE_REQUEST

        public static final RPCMessage.Type RPC_LOCAL_BLOCK_CLOSE_REQUEST
      • RPC_LOCAL_BLOCK_CREATE_REQUEST

        public static final RPCMessage.Type RPC_LOCAL_BLOCK_CREATE_REQUEST
      • RPC_LOCAL_BLOCK_CREATE_RESPONSE

        public static final RPCMessage.Type RPC_LOCAL_BLOCK_CREATE_RESPONSE
      • RPC_LOCAL_BLOCK_COMPLETE_REQUEST

        public static final RPCMessage.Type RPC_LOCAL_BLOCK_COMPLETE_REQUEST
      • RPC_ASYNC_CACHE_REQUEST

        public static final RPCMessage.Type RPC_ASYNC_CACHE_REQUEST
    • Method Detail

      • values

        public static RPCMessage.Type[] values()
        Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
        for (RPCMessage.Type c : RPCMessage.Type.values())
            System.out.println(c);
        
        Returns:
        an array containing the constants of this enum type, in the order they are declared
      • valueOf

        public static RPCMessage.Type valueOf​(java.lang.String name)
        Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
        Parameters:
        name - the name of the enum constant to be returned.
        Returns:
        the enum constant with the specified name
        Throws:
        java.lang.IllegalArgumentException - if this enum type has no constant with the specified name
        java.lang.NullPointerException - if the argument is null
      • getEncodedLength

        public int getEncodedLength()
        Description copied from interface: EncodedMessage
        Returns the number bytes for the message when it is encoded.
        Specified by:
        getEncodedLength in interface EncodedMessage
        Returns:
        the length of the encoded message, in bytes
      • encode

        public void encode​(io.netty.buffer.ByteBuf out)
        Description copied from interface: EncodedMessage
        Encodes the message to the output ByteBuf.
        Specified by:
        encode in interface EncodedMessage
        Parameters:
        out - the output ByteBuf where the message should be encoded
      • getId

        public int getId()
        Returns the int identifier of the type. Note: This is only used for getting the int representation of the type for alluxio.worker.DataServerMessage, since that class needs to manually encode all messages. alluxio.worker.DataServerMessage and this method should no longer be needed when the client is converted to use Netty.
        Returns:
        the int id of the type
      • decode

        public static RPCMessage.Type decode​(io.netty.buffer.ByteBuf in)
        Returns the type represented by the id from the input ByteBuf. This must be updated to add new message types.
        Parameters:
        in - The input ByteBuf to decode into a type
        Returns:
        The decoded message type