Class BandwidthLimit

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

    public final class BandwidthLimit
    extends com.google.protobuf.GeneratedMessageV3
    implements BandwidthLimitOrBuilder
     [#next-free-field: 8]
     
    Protobuf type envoy.extensions.filters.http.bandwidth_limit.v3.BandwidthLimit
    See Also:
    Serialized Form
    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
      static class  BandwidthLimit.Builder
      [#next-free-field: 8]
      static class  BandwidthLimit.EnableMode
      Defines the mode for the bandwidth limit filter.
      • Nested classes/interfaces inherited from class com.google.protobuf.GeneratedMessageV3

        com.google.protobuf.GeneratedMessageV3.BuilderParent, com.google.protobuf.GeneratedMessageV3.ExtendableBuilder<MessageType extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage,​BuilderType extends com.google.protobuf.GeneratedMessageV3.ExtendableBuilder<MessageType,​BuilderType>>, com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageType extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage>, com.google.protobuf.GeneratedMessageV3.ExtendableMessageOrBuilder<MessageType extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage>, com.google.protobuf.GeneratedMessageV3.FieldAccessorTable, com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter
      • Nested classes/interfaces inherited from class com.google.protobuf.AbstractMessageLite

        com.google.protobuf.AbstractMessageLite.InternalOneOfEnum
    • Field Detail

      • STAT_PREFIX_FIELD_NUMBER

        public static final int STAT_PREFIX_FIELD_NUMBER
        See Also:
        Constant Field Values
      • ENABLE_MODE_FIELD_NUMBER

        public static final int ENABLE_MODE_FIELD_NUMBER
        See Also:
        Constant Field Values
      • LIMIT_KBPS_FIELD_NUMBER

        public static final int LIMIT_KBPS_FIELD_NUMBER
        See Also:
        Constant Field Values
      • FILL_INTERVAL_FIELD_NUMBER

        public static final int FILL_INTERVAL_FIELD_NUMBER
        See Also:
        Constant Field Values
      • RUNTIME_ENABLED_FIELD_NUMBER

        public static final int RUNTIME_ENABLED_FIELD_NUMBER
        See Also:
        Constant Field Values
      • ENABLE_RESPONSE_TRAILERS_FIELD_NUMBER

        public static final int ENABLE_RESPONSE_TRAILERS_FIELD_NUMBER
        See Also:
        Constant Field Values
      • RESPONSE_TRAILER_PREFIX_FIELD_NUMBER

        public static final int RESPONSE_TRAILER_PREFIX_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
      • getStatPrefix

        public String getStatPrefix()
         The human readable prefix to use when emitting stats.
         
        string stat_prefix = 1 [(.validate.rules) = { ... }
        Specified by:
        getStatPrefix in interface BandwidthLimitOrBuilder
        Returns:
        The statPrefix.
      • getStatPrefixBytes

        public com.google.protobuf.ByteString getStatPrefixBytes()
         The human readable prefix to use when emitting stats.
         
        string stat_prefix = 1 [(.validate.rules) = { ... }
        Specified by:
        getStatPrefixBytes in interface BandwidthLimitOrBuilder
        Returns:
        The bytes for statPrefix.
      • getEnableModeValue

        public int getEnableModeValue()
         The enable mode for the bandwidth limit filter.
         Default is Disabled.
         
        .envoy.extensions.filters.http.bandwidth_limit.v3.BandwidthLimit.EnableMode enable_mode = 2 [(.validate.rules) = { ... }
        Specified by:
        getEnableModeValue in interface BandwidthLimitOrBuilder
        Returns:
        The enum numeric value on the wire for enableMode.
      • getEnableMode

        public BandwidthLimit.EnableMode getEnableMode()
         The enable mode for the bandwidth limit filter.
         Default is Disabled.
         
        .envoy.extensions.filters.http.bandwidth_limit.v3.BandwidthLimit.EnableMode enable_mode = 2 [(.validate.rules) = { ... }
        Specified by:
        getEnableMode in interface BandwidthLimitOrBuilder
        Returns:
        The enableMode.
      • hasLimitKbps

        public boolean hasLimitKbps()
         The limit supplied in KiB/s.
         .. note::
           It's fine for the limit to be unset for the global configuration since the bandwidth limit
           can be applied at a the virtual host or route level. Thus, the limit must be set for the
           per route configuration otherwise the config will be rejected.
         .. note::
           When using per route configuration, the limit becomes unique to that route.
         
        .google.protobuf.UInt64Value limit_kbps = 3 [(.validate.rules) = { ... }
        Specified by:
        hasLimitKbps in interface BandwidthLimitOrBuilder
        Returns:
        Whether the limitKbps field is set.
      • getLimitKbps

        public com.google.protobuf.UInt64Value getLimitKbps()
         The limit supplied in KiB/s.
         .. note::
           It's fine for the limit to be unset for the global configuration since the bandwidth limit
           can be applied at a the virtual host or route level. Thus, the limit must be set for the
           per route configuration otherwise the config will be rejected.
         .. note::
           When using per route configuration, the limit becomes unique to that route.
         
        .google.protobuf.UInt64Value limit_kbps = 3 [(.validate.rules) = { ... }
        Specified by:
        getLimitKbps in interface BandwidthLimitOrBuilder
        Returns:
        The limitKbps.
      • getLimitKbpsOrBuilder

        public com.google.protobuf.UInt64ValueOrBuilder getLimitKbpsOrBuilder()
         The limit supplied in KiB/s.
         .. note::
           It's fine for the limit to be unset for the global configuration since the bandwidth limit
           can be applied at a the virtual host or route level. Thus, the limit must be set for the
           per route configuration otherwise the config will be rejected.
         .. note::
           When using per route configuration, the limit becomes unique to that route.
         
        .google.protobuf.UInt64Value limit_kbps = 3 [(.validate.rules) = { ... }
        Specified by:
        getLimitKbpsOrBuilder in interface BandwidthLimitOrBuilder
      • hasFillInterval

        public boolean hasFillInterval()
         Optional Fill interval in milliseconds for the token refills. Defaults to 50ms.
         It must be at least 20ms to avoid too aggressive refills.
         
        .google.protobuf.Duration fill_interval = 4 [(.validate.rules) = { ... }
        Specified by:
        hasFillInterval in interface BandwidthLimitOrBuilder
        Returns:
        Whether the fillInterval field is set.
      • getFillInterval

        public com.google.protobuf.Duration getFillInterval()
         Optional Fill interval in milliseconds for the token refills. Defaults to 50ms.
         It must be at least 20ms to avoid too aggressive refills.
         
        .google.protobuf.Duration fill_interval = 4 [(.validate.rules) = { ... }
        Specified by:
        getFillInterval in interface BandwidthLimitOrBuilder
        Returns:
        The fillInterval.
      • getFillIntervalOrBuilder

        public com.google.protobuf.DurationOrBuilder getFillIntervalOrBuilder()
         Optional Fill interval in milliseconds for the token refills. Defaults to 50ms.
         It must be at least 20ms to avoid too aggressive refills.
         
        .google.protobuf.Duration fill_interval = 4 [(.validate.rules) = { ... }
        Specified by:
        getFillIntervalOrBuilder in interface BandwidthLimitOrBuilder
      • hasRuntimeEnabled

        public boolean hasRuntimeEnabled()
         Runtime flag that controls whether the filter is enabled or not. If not specified, defaults
         to enabled.
         
        .envoy.config.core.v3.RuntimeFeatureFlag runtime_enabled = 5;
        Specified by:
        hasRuntimeEnabled in interface BandwidthLimitOrBuilder
        Returns:
        Whether the runtimeEnabled field is set.
      • getRuntimeEnabled

        public RuntimeFeatureFlag getRuntimeEnabled()
         Runtime flag that controls whether the filter is enabled or not. If not specified, defaults
         to enabled.
         
        .envoy.config.core.v3.RuntimeFeatureFlag runtime_enabled = 5;
        Specified by:
        getRuntimeEnabled in interface BandwidthLimitOrBuilder
        Returns:
        The runtimeEnabled.
      • getEnableResponseTrailers

        public boolean getEnableResponseTrailers()
         Enable response trailers.
         .. note::
           * If set true, the response trailers ``bandwidth-request-delay-ms`` and ``bandwidth-response-delay-ms`` will be added, prefixed by ``response_trailer_prefix``.
           * bandwidth-request-delay-ms: delay time in milliseconds it took for the request stream transfer.
           * bandwidth-response-delay-ms: delay time in milliseconds it took for the response stream transfer.
           * If :ref:`enable_mode <envoy_v3_api_field_extensions.filters.http.bandwidth_limit.v3.BandwidthLimit.enable_mode>` is ``DISABLED`` or ``REQUEST``, the trailers will not be set.
           * If both the request and response delay time is 0, the trailers will not be set.
         
        bool enable_response_trailers = 6;
        Specified by:
        getEnableResponseTrailers in interface BandwidthLimitOrBuilder
        Returns:
        The enableResponseTrailers.
      • getResponseTrailerPrefix

        public String getResponseTrailerPrefix()
         Optional The prefix for the response trailers.
         
        string response_trailer_prefix = 7 [(.validate.rules) = { ... }
        Specified by:
        getResponseTrailerPrefix in interface BandwidthLimitOrBuilder
        Returns:
        The responseTrailerPrefix.
      • getResponseTrailerPrefixBytes

        public com.google.protobuf.ByteString getResponseTrailerPrefixBytes()
         Optional The prefix for the response trailers.
         
        string response_trailer_prefix = 7 [(.validate.rules) = { ... }
        Specified by:
        getResponseTrailerPrefixBytes in interface BandwidthLimitOrBuilder
        Returns:
        The bytes for responseTrailerPrefix.
      • 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 BandwidthLimit parseFrom​(ByteBuffer data)
                                        throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

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

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

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

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

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

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

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

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

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

        public static BandwidthLimit getDefaultInstance()
      • parser

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

        public com.google.protobuf.Parser<BandwidthLimit> 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 BandwidthLimit getDefaultInstanceForType()
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder