Class OkHttpResponse

  • All Implemented Interfaces:
    com.google.protobuf.Message, com.google.protobuf.MessageLite, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, OkHttpResponseOrBuilder, Serializable

    public final class OkHttpResponse
    extends com.google.protobuf.GeneratedMessageV3
    implements OkHttpResponseOrBuilder
     HTTP attributes for an OK response.
     [#next-free-field: 9]
     
    Protobuf type envoy.service.auth.v3.OkHttpResponse
    See Also:
    Serialized Form
    • Field Detail

      • HEADERS_TO_REMOVE_FIELD_NUMBER

        public static final int HEADERS_TO_REMOVE_FIELD_NUMBER
        See Also:
        Constant Field Values
      • DYNAMIC_METADATA_FIELD_NUMBER

        public static final int DYNAMIC_METADATA_FIELD_NUMBER
        See Also:
        Constant Field Values
      • RESPONSE_HEADERS_TO_ADD_FIELD_NUMBER

        public static final int RESPONSE_HEADERS_TO_ADD_FIELD_NUMBER
        See Also:
        Constant Field Values
      • QUERY_PARAMETERS_TO_SET_FIELD_NUMBER

        public static final int QUERY_PARAMETERS_TO_SET_FIELD_NUMBER
        See Also:
        Constant Field Values
      • QUERY_PARAMETERS_TO_REMOVE_FIELD_NUMBER

        public static final int QUERY_PARAMETERS_TO_REMOVE_FIELD_NUMBER
        See Also:
        Constant Field Values
    • Method Detail

      • newInstance

        protected Object newInstance​(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused)
        Overrides:
        newInstance in class com.google.protobuf.GeneratedMessageV3
      • getUnknownFields

        public final com.google.protobuf.UnknownFieldSet getUnknownFields()
        Specified by:
        getUnknownFields in interface com.google.protobuf.MessageOrBuilder
        Overrides:
        getUnknownFields in class com.google.protobuf.GeneratedMessageV3
      • getDescriptor

        public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
      • internalGetFieldAccessorTable

        protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
        Specified by:
        internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessageV3
      • getHeadersList

        public List<HeaderValueOption> getHeadersList()
         HTTP entity headers in addition to the original request headers. This allows the authorization
         service to append, to add or to override headers from the original request before
         dispatching it to the upstream. Note that the :ref:`append field in HeaderValueOption <envoy_v3_api_field_config.core.v3.HeaderValueOption.append>` defaults to
         false when used in this message. By setting the ``append`` field to ``true``,
         the filter will append the correspondent header value to the matched request header.
         By leaving ``append`` as false, the filter will either add a new header, or override an existing
         one if there is a match.
         
        repeated .envoy.config.core.v3.HeaderValueOption headers = 2;
        Specified by:
        getHeadersList in interface OkHttpResponseOrBuilder
      • getHeadersOrBuilderList

        public List<? extends HeaderValueOptionOrBuilder> getHeadersOrBuilderList()
         HTTP entity headers in addition to the original request headers. This allows the authorization
         service to append, to add or to override headers from the original request before
         dispatching it to the upstream. Note that the :ref:`append field in HeaderValueOption <envoy_v3_api_field_config.core.v3.HeaderValueOption.append>` defaults to
         false when used in this message. By setting the ``append`` field to ``true``,
         the filter will append the correspondent header value to the matched request header.
         By leaving ``append`` as false, the filter will either add a new header, or override an existing
         one if there is a match.
         
        repeated .envoy.config.core.v3.HeaderValueOption headers = 2;
        Specified by:
        getHeadersOrBuilderList in interface OkHttpResponseOrBuilder
      • getHeadersCount

        public int getHeadersCount()
         HTTP entity headers in addition to the original request headers. This allows the authorization
         service to append, to add or to override headers from the original request before
         dispatching it to the upstream. Note that the :ref:`append field in HeaderValueOption <envoy_v3_api_field_config.core.v3.HeaderValueOption.append>` defaults to
         false when used in this message. By setting the ``append`` field to ``true``,
         the filter will append the correspondent header value to the matched request header.
         By leaving ``append`` as false, the filter will either add a new header, or override an existing
         one if there is a match.
         
        repeated .envoy.config.core.v3.HeaderValueOption headers = 2;
        Specified by:
        getHeadersCount in interface OkHttpResponseOrBuilder
      • getHeaders

        public HeaderValueOption getHeaders​(int index)
         HTTP entity headers in addition to the original request headers. This allows the authorization
         service to append, to add or to override headers from the original request before
         dispatching it to the upstream. Note that the :ref:`append field in HeaderValueOption <envoy_v3_api_field_config.core.v3.HeaderValueOption.append>` defaults to
         false when used in this message. By setting the ``append`` field to ``true``,
         the filter will append the correspondent header value to the matched request header.
         By leaving ``append`` as false, the filter will either add a new header, or override an existing
         one if there is a match.
         
        repeated .envoy.config.core.v3.HeaderValueOption headers = 2;
        Specified by:
        getHeaders in interface OkHttpResponseOrBuilder
      • getHeadersOrBuilder

        public HeaderValueOptionOrBuilder getHeadersOrBuilder​(int index)
         HTTP entity headers in addition to the original request headers. This allows the authorization
         service to append, to add or to override headers from the original request before
         dispatching it to the upstream. Note that the :ref:`append field in HeaderValueOption <envoy_v3_api_field_config.core.v3.HeaderValueOption.append>` defaults to
         false when used in this message. By setting the ``append`` field to ``true``,
         the filter will append the correspondent header value to the matched request header.
         By leaving ``append`` as false, the filter will either add a new header, or override an existing
         one if there is a match.
         
        repeated .envoy.config.core.v3.HeaderValueOption headers = 2;
        Specified by:
        getHeadersOrBuilder in interface OkHttpResponseOrBuilder
      • getHeadersToRemoveList

        public com.google.protobuf.ProtocolStringList getHeadersToRemoveList()
         HTTP entity headers to remove from the original request before dispatching
         it to the upstream. This allows the authorization service to act on auth
         related headers (like ``Authorization``), process them, and consume them.
         Under this model, the upstream will either receive the request (if it's
         authorized) or not receive it (if it's not), but will not see headers
         containing authorization credentials.
         Pseudo headers (such as ``:authority``, ``:method``, ``:path`` etc), as well as
         the header ``Host``, may not be removed as that would make the request
         malformed. If mentioned in ``headers_to_remove`` these special headers will
         be ignored.
         When using the HTTP service this must instead be set by the HTTP
         authorization service as a comma separated list like so:
         ``x-envoy-auth-headers-to-remove: one-auth-header, another-auth-header``.
         
        repeated string headers_to_remove = 5;
        Specified by:
        getHeadersToRemoveList in interface OkHttpResponseOrBuilder
        Returns:
        A list containing the headersToRemove.
      • getHeadersToRemoveCount

        public int getHeadersToRemoveCount()
         HTTP entity headers to remove from the original request before dispatching
         it to the upstream. This allows the authorization service to act on auth
         related headers (like ``Authorization``), process them, and consume them.
         Under this model, the upstream will either receive the request (if it's
         authorized) or not receive it (if it's not), but will not see headers
         containing authorization credentials.
         Pseudo headers (such as ``:authority``, ``:method``, ``:path`` etc), as well as
         the header ``Host``, may not be removed as that would make the request
         malformed. If mentioned in ``headers_to_remove`` these special headers will
         be ignored.
         When using the HTTP service this must instead be set by the HTTP
         authorization service as a comma separated list like so:
         ``x-envoy-auth-headers-to-remove: one-auth-header, another-auth-header``.
         
        repeated string headers_to_remove = 5;
        Specified by:
        getHeadersToRemoveCount in interface OkHttpResponseOrBuilder
        Returns:
        The count of headersToRemove.
      • getHeadersToRemove

        public String getHeadersToRemove​(int index)
         HTTP entity headers to remove from the original request before dispatching
         it to the upstream. This allows the authorization service to act on auth
         related headers (like ``Authorization``), process them, and consume them.
         Under this model, the upstream will either receive the request (if it's
         authorized) or not receive it (if it's not), but will not see headers
         containing authorization credentials.
         Pseudo headers (such as ``:authority``, ``:method``, ``:path`` etc), as well as
         the header ``Host``, may not be removed as that would make the request
         malformed. If mentioned in ``headers_to_remove`` these special headers will
         be ignored.
         When using the HTTP service this must instead be set by the HTTP
         authorization service as a comma separated list like so:
         ``x-envoy-auth-headers-to-remove: one-auth-header, another-auth-header``.
         
        repeated string headers_to_remove = 5;
        Specified by:
        getHeadersToRemove in interface OkHttpResponseOrBuilder
        Parameters:
        index - The index of the element to return.
        Returns:
        The headersToRemove at the given index.
      • getHeadersToRemoveBytes

        public com.google.protobuf.ByteString getHeadersToRemoveBytes​(int index)
         HTTP entity headers to remove from the original request before dispatching
         it to the upstream. This allows the authorization service to act on auth
         related headers (like ``Authorization``), process them, and consume them.
         Under this model, the upstream will either receive the request (if it's
         authorized) or not receive it (if it's not), but will not see headers
         containing authorization credentials.
         Pseudo headers (such as ``:authority``, ``:method``, ``:path`` etc), as well as
         the header ``Host``, may not be removed as that would make the request
         malformed. If mentioned in ``headers_to_remove`` these special headers will
         be ignored.
         When using the HTTP service this must instead be set by the HTTP
         authorization service as a comma separated list like so:
         ``x-envoy-auth-headers-to-remove: one-auth-header, another-auth-header``.
         
        repeated string headers_to_remove = 5;
        Specified by:
        getHeadersToRemoveBytes in interface OkHttpResponseOrBuilder
        Parameters:
        index - The index of the value to return.
        Returns:
        The bytes of the headersToRemove at the given index.
      • hasDynamicMetadata

        @Deprecated
        public boolean hasDynamicMetadata()
        Deprecated.
        envoy.service.auth.v3.OkHttpResponse.dynamic_metadata is deprecated. See envoy/service/auth/v3/external_auth.proto;l=97
         This field has been deprecated in favor of :ref:`CheckResponse.dynamic_metadata
         <envoy_v3_api_field_service.auth.v3.CheckResponse.dynamic_metadata>`. Until it is removed,
         setting this field overrides :ref:`CheckResponse.dynamic_metadata
         <envoy_v3_api_field_service.auth.v3.CheckResponse.dynamic_metadata>`.
         
        .google.protobuf.Struct dynamic_metadata = 3 [deprecated = true, (.envoy.annotations.deprecated_at_minor_version) = "3.0"];
        Specified by:
        hasDynamicMetadata in interface OkHttpResponseOrBuilder
        Returns:
        Whether the dynamicMetadata field is set.
      • getDynamicMetadata

        @Deprecated
        public com.google.protobuf.Struct getDynamicMetadata()
        Deprecated.
        envoy.service.auth.v3.OkHttpResponse.dynamic_metadata is deprecated. See envoy/service/auth/v3/external_auth.proto;l=97
         This field has been deprecated in favor of :ref:`CheckResponse.dynamic_metadata
         <envoy_v3_api_field_service.auth.v3.CheckResponse.dynamic_metadata>`. Until it is removed,
         setting this field overrides :ref:`CheckResponse.dynamic_metadata
         <envoy_v3_api_field_service.auth.v3.CheckResponse.dynamic_metadata>`.
         
        .google.protobuf.Struct dynamic_metadata = 3 [deprecated = true, (.envoy.annotations.deprecated_at_minor_version) = "3.0"];
        Specified by:
        getDynamicMetadata in interface OkHttpResponseOrBuilder
        Returns:
        The dynamicMetadata.
      • getDynamicMetadataOrBuilder

        @Deprecated
        public com.google.protobuf.StructOrBuilder getDynamicMetadataOrBuilder()
        Deprecated.
         This field has been deprecated in favor of :ref:`CheckResponse.dynamic_metadata
         <envoy_v3_api_field_service.auth.v3.CheckResponse.dynamic_metadata>`. Until it is removed,
         setting this field overrides :ref:`CheckResponse.dynamic_metadata
         <envoy_v3_api_field_service.auth.v3.CheckResponse.dynamic_metadata>`.
         
        .google.protobuf.Struct dynamic_metadata = 3 [deprecated = true, (.envoy.annotations.deprecated_at_minor_version) = "3.0"];
        Specified by:
        getDynamicMetadataOrBuilder in interface OkHttpResponseOrBuilder
      • getResponseHeadersToAddList

        public List<HeaderValueOption> getResponseHeadersToAddList()
         This field allows the authorization service to send HTTP response headers
         to the downstream client on success. Note that the :ref:`append field in HeaderValueOption <envoy_v3_api_field_config.core.v3.HeaderValueOption.append>`
         defaults to false when used in this message.
         
        repeated .envoy.config.core.v3.HeaderValueOption response_headers_to_add = 6;
        Specified by:
        getResponseHeadersToAddList in interface OkHttpResponseOrBuilder
      • getResponseHeadersToAddOrBuilderList

        public List<? extends HeaderValueOptionOrBuilder> getResponseHeadersToAddOrBuilderList()
         This field allows the authorization service to send HTTP response headers
         to the downstream client on success. Note that the :ref:`append field in HeaderValueOption <envoy_v3_api_field_config.core.v3.HeaderValueOption.append>`
         defaults to false when used in this message.
         
        repeated .envoy.config.core.v3.HeaderValueOption response_headers_to_add = 6;
        Specified by:
        getResponseHeadersToAddOrBuilderList in interface OkHttpResponseOrBuilder
      • getResponseHeadersToAddCount

        public int getResponseHeadersToAddCount()
         This field allows the authorization service to send HTTP response headers
         to the downstream client on success. Note that the :ref:`append field in HeaderValueOption <envoy_v3_api_field_config.core.v3.HeaderValueOption.append>`
         defaults to false when used in this message.
         
        repeated .envoy.config.core.v3.HeaderValueOption response_headers_to_add = 6;
        Specified by:
        getResponseHeadersToAddCount in interface OkHttpResponseOrBuilder
      • getResponseHeadersToAdd

        public HeaderValueOption getResponseHeadersToAdd​(int index)
         This field allows the authorization service to send HTTP response headers
         to the downstream client on success. Note that the :ref:`append field in HeaderValueOption <envoy_v3_api_field_config.core.v3.HeaderValueOption.append>`
         defaults to false when used in this message.
         
        repeated .envoy.config.core.v3.HeaderValueOption response_headers_to_add = 6;
        Specified by:
        getResponseHeadersToAdd in interface OkHttpResponseOrBuilder
      • getResponseHeadersToAddOrBuilder

        public HeaderValueOptionOrBuilder getResponseHeadersToAddOrBuilder​(int index)
         This field allows the authorization service to send HTTP response headers
         to the downstream client on success. Note that the :ref:`append field in HeaderValueOption <envoy_v3_api_field_config.core.v3.HeaderValueOption.append>`
         defaults to false when used in this message.
         
        repeated .envoy.config.core.v3.HeaderValueOption response_headers_to_add = 6;
        Specified by:
        getResponseHeadersToAddOrBuilder in interface OkHttpResponseOrBuilder
      • getQueryParametersToSetList

        public List<QueryParameter> getQueryParametersToSetList()
         This field allows the authorization service to set (and overwrite) query
         string parameters on the original request before it is sent upstream.
         
        repeated .envoy.config.core.v3.QueryParameter query_parameters_to_set = 7;
        Specified by:
        getQueryParametersToSetList in interface OkHttpResponseOrBuilder
      • getQueryParametersToSetOrBuilderList

        public List<? extends QueryParameterOrBuilder> getQueryParametersToSetOrBuilderList()
         This field allows the authorization service to set (and overwrite) query
         string parameters on the original request before it is sent upstream.
         
        repeated .envoy.config.core.v3.QueryParameter query_parameters_to_set = 7;
        Specified by:
        getQueryParametersToSetOrBuilderList in interface OkHttpResponseOrBuilder
      • getQueryParametersToSetCount

        public int getQueryParametersToSetCount()
         This field allows the authorization service to set (and overwrite) query
         string parameters on the original request before it is sent upstream.
         
        repeated .envoy.config.core.v3.QueryParameter query_parameters_to_set = 7;
        Specified by:
        getQueryParametersToSetCount in interface OkHttpResponseOrBuilder
      • getQueryParametersToSet

        public QueryParameter getQueryParametersToSet​(int index)
         This field allows the authorization service to set (and overwrite) query
         string parameters on the original request before it is sent upstream.
         
        repeated .envoy.config.core.v3.QueryParameter query_parameters_to_set = 7;
        Specified by:
        getQueryParametersToSet in interface OkHttpResponseOrBuilder
      • getQueryParametersToSetOrBuilder

        public QueryParameterOrBuilder getQueryParametersToSetOrBuilder​(int index)
         This field allows the authorization service to set (and overwrite) query
         string parameters on the original request before it is sent upstream.
         
        repeated .envoy.config.core.v3.QueryParameter query_parameters_to_set = 7;
        Specified by:
        getQueryParametersToSetOrBuilder in interface OkHttpResponseOrBuilder
      • getQueryParametersToRemoveList

        public com.google.protobuf.ProtocolStringList getQueryParametersToRemoveList()
         This field allows the authorization service to specify which query parameters
         should be removed from the original request before it is sent upstream. Each
         element in this list is a case-sensitive query parameter name to be removed.
         
        repeated string query_parameters_to_remove = 8;
        Specified by:
        getQueryParametersToRemoveList in interface OkHttpResponseOrBuilder
        Returns:
        A list containing the queryParametersToRemove.
      • getQueryParametersToRemoveCount

        public int getQueryParametersToRemoveCount()
         This field allows the authorization service to specify which query parameters
         should be removed from the original request before it is sent upstream. Each
         element in this list is a case-sensitive query parameter name to be removed.
         
        repeated string query_parameters_to_remove = 8;
        Specified by:
        getQueryParametersToRemoveCount in interface OkHttpResponseOrBuilder
        Returns:
        The count of queryParametersToRemove.
      • getQueryParametersToRemove

        public String getQueryParametersToRemove​(int index)
         This field allows the authorization service to specify which query parameters
         should be removed from the original request before it is sent upstream. Each
         element in this list is a case-sensitive query parameter name to be removed.
         
        repeated string query_parameters_to_remove = 8;
        Specified by:
        getQueryParametersToRemove in interface OkHttpResponseOrBuilder
        Parameters:
        index - The index of the element to return.
        Returns:
        The queryParametersToRemove at the given index.
      • getQueryParametersToRemoveBytes

        public com.google.protobuf.ByteString getQueryParametersToRemoveBytes​(int index)
         This field allows the authorization service to specify which query parameters
         should be removed from the original request before it is sent upstream. Each
         element in this list is a case-sensitive query parameter name to be removed.
         
        repeated string query_parameters_to_remove = 8;
        Specified by:
        getQueryParametersToRemoveBytes in interface OkHttpResponseOrBuilder
        Parameters:
        index - The index of the value to return.
        Returns:
        The bytes of the queryParametersToRemove at the given index.
      • isInitialized

        public final boolean isInitialized()
        Specified by:
        isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
        Overrides:
        isInitialized in class com.google.protobuf.GeneratedMessageV3
      • writeTo

        public void writeTo​(com.google.protobuf.CodedOutputStream output)
                     throws IOException
        Specified by:
        writeTo in interface com.google.protobuf.MessageLite
        Overrides:
        writeTo in class com.google.protobuf.GeneratedMessageV3
        Throws:
        IOException
      • getSerializedSize

        public int getSerializedSize()
        Specified by:
        getSerializedSize in interface com.google.protobuf.MessageLite
        Overrides:
        getSerializedSize in class com.google.protobuf.GeneratedMessageV3
      • equals

        public boolean equals​(Object obj)
        Specified by:
        equals in interface com.google.protobuf.Message
        Overrides:
        equals in class com.google.protobuf.AbstractMessage
      • hashCode

        public int hashCode()
        Specified by:
        hashCode in interface com.google.protobuf.Message
        Overrides:
        hashCode in class com.google.protobuf.AbstractMessage
      • parseFrom

        public static OkHttpResponse parseFrom​(ByteBuffer data)
                                        throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static OkHttpResponse parseFrom​(ByteBuffer data,
                                               com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                        throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static OkHttpResponse parseFrom​(com.google.protobuf.ByteString data)
                                        throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static OkHttpResponse parseFrom​(com.google.protobuf.ByteString data,
                                               com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                        throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static OkHttpResponse parseFrom​(byte[] data)
                                        throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static OkHttpResponse parseFrom​(byte[] data,
                                               com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                        throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static OkHttpResponse parseFrom​(com.google.protobuf.CodedInputStream input,
                                               com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                        throws IOException
        Throws:
        IOException
      • newBuilderForType

        public OkHttpResponse.Builder newBuilderForType()
        Specified by:
        newBuilderForType in interface com.google.protobuf.Message
        Specified by:
        newBuilderForType in interface com.google.protobuf.MessageLite
      • toBuilder

        public OkHttpResponse.Builder toBuilder()
        Specified by:
        toBuilder in interface com.google.protobuf.Message
        Specified by:
        toBuilder in interface com.google.protobuf.MessageLite
      • newBuilderForType

        protected OkHttpResponse.Builder newBuilderForType​(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)
        Specified by:
        newBuilderForType in class com.google.protobuf.GeneratedMessageV3
      • getDefaultInstance

        public static OkHttpResponse getDefaultInstance()
      • parser

        public static com.google.protobuf.Parser<OkHttpResponse> parser()
      • getParserForType

        public com.google.protobuf.Parser<OkHttpResponse> getParserForType()
        Specified by:
        getParserForType in interface com.google.protobuf.Message
        Specified by:
        getParserForType in interface com.google.protobuf.MessageLite
        Overrides:
        getParserForType in class com.google.protobuf.GeneratedMessageV3
      • getDefaultInstanceForType

        public OkHttpResponse getDefaultInstanceForType()
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder