Class DynamicModuleConfig

java.lang.Object
com.google.protobuf.AbstractMessageLite
com.google.protobuf.AbstractMessage
com.google.protobuf.GeneratedMessageV3
io.envoyproxy.envoy.extensions.dynamic_modules.v3.DynamicModuleConfig
All Implemented Interfaces:
com.google.protobuf.Message, com.google.protobuf.MessageLite, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, DynamicModuleConfigOrBuilder, Serializable

public final class DynamicModuleConfig extends com.google.protobuf.GeneratedMessageV3 implements DynamicModuleConfigOrBuilder
 Configuration of a dynamic module. A dynamic module is a shared object file that can be loaded via
 ``dlopen`` by various Envoy extension points.

 How a module is loaded is determined by the extension point that uses it. For example, the HTTP
 filter loads the module when Envoy receives a configuration that references the module. If loading
 the module fails, the configuration will be rejected.

 A module is uniquely identified by its file path and the file's inode, depending on the platform.
 Notably, if the file path and the content of the file are the same, the shared object will be
 reused.

 A module must be compatible with the ABI specified in :repo:`abi.h
 <source/extensions/dynamic_modules/abi.h>`. Currently, compatibility is only guaranteed by an
 exact version match between the Envoy codebase and the dynamic module SDKs. In the future, after
 the ABI is stabilized, this restriction will be revisited. Until then, Envoy checks the hash of
 the ABI header files to ensure that the dynamic modules are built against the same version of the
 ABI.
 
Protobuf type envoy.extensions.dynamic_modules.v3.DynamicModuleConfig
See Also:
  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Class
    Description
    static final class 
    Configuration of a dynamic module.

    Nested classes/interfaces inherited from class com.google.protobuf.GeneratedMessageV3

    com.google.protobuf.GeneratedMessageV3.BuilderParent, com.google.protobuf.GeneratedMessageV3.ExtendableBuilder<MessageT extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT>,BuilderT extends com.google.protobuf.GeneratedMessageV3.ExtendableBuilder<MessageT,BuilderT>>, com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT>>, com.google.protobuf.GeneratedMessageV3.ExtendableMessageOrBuilder<MessageT extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT>>, 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 Summary

    Fields
    Modifier and Type
    Field
    Description
    static final int
     
    static final int
     
    static final int
     

    Fields inherited from class com.google.protobuf.GeneratedMessageV3

    alwaysUseFieldBuilders, unknownFields

    Fields inherited from class com.google.protobuf.AbstractMessage

    memoizedSize

    Fields inherited from class com.google.protobuf.AbstractMessageLite

    memoizedHashCode
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
     
     
     
    static final com.google.protobuf.Descriptors.Descriptor
     
    boolean
    If true, prevents the module from being unloaded with ``dlclose``.
    boolean
    If true, the dynamic module is loaded with the ``RTLD_GLOBAL`` flag.
    The name of the dynamic module.
    com.google.protobuf.ByteString
    The name of the dynamic module.
    com.google.protobuf.Parser<DynamicModuleConfig>
     
    int
     
    int
     
    protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
     
    final boolean
     
     
     
     
    newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)
     
    protected Object
    newInstance(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused)
     
     
    parseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
     
    parseFrom(byte[] data)
     
    parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
     
    parseFrom(com.google.protobuf.ByteString data)
     
    parseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
     
    parseFrom(com.google.protobuf.CodedInputStream input)
     
    parseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
     
     
    parseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
     
     
    parseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
     
    static com.google.protobuf.Parser<DynamicModuleConfig>
     
     
    void
    writeTo(com.google.protobuf.CodedOutputStream output)
     

    Methods inherited from class com.google.protobuf.GeneratedMessageV3

    canUseUnsafe, computeStringSize, computeStringSizeNoTag, emptyBooleanList, emptyDoubleList, emptyFloatList, emptyIntList, emptyList, emptyLongList, getAllFields, getDescriptorForType, getField, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof, internalGetMapField, internalGetMapFieldReflection, isStringEmpty, makeExtensionsImmutable, makeMutableCopy, makeMutableCopy, mergeFromAndMakeImmutableInternal, mutableCopy, mutableCopy, mutableCopy, mutableCopy, mutableCopy, newBooleanList, newBuilderForType, newDoubleList, newFloatList, newIntList, newLongList, parseDelimitedWithIOException, parseDelimitedWithIOException, parseUnknownField, parseUnknownFieldProto3, parseWithIOException, parseWithIOException, parseWithIOException, parseWithIOException, serializeBooleanMapTo, serializeIntegerMapTo, serializeLongMapTo, serializeStringMapTo, writeReplace, writeString, writeStringNoTag

    Methods inherited from class com.google.protobuf.AbstractMessage

    findInitializationErrors, getInitializationErrorString, hashBoolean, hashEnum, hashEnumList, hashFields, hashLong, toString

    Methods inherited from class com.google.protobuf.AbstractMessageLite

    addAll, addAll, checkByteStringIsUtf8, toByteArray, toByteString, writeDelimitedTo, writeTo

    Methods inherited from class java.lang.Object

    clone, finalize, getClass, notify, notifyAll, wait, wait, wait

    Methods inherited from interface com.google.protobuf.MessageLite

    toByteArray, toByteString, writeDelimitedTo, writeTo

    Methods inherited from interface com.google.protobuf.MessageOrBuilder

    findInitializationErrors, getAllFields, getDescriptorForType, getField, getInitializationErrorString, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof
  • Field Details

    • NAME_FIELD_NUMBER

      public static final int NAME_FIELD_NUMBER
      See Also:
    • DO_NOT_CLOSE_FIELD_NUMBER

      public static final int DO_NOT_CLOSE_FIELD_NUMBER
      See Also:
    • LOAD_GLOBALLY_FIELD_NUMBER

      public static final int LOAD_GLOBALLY_FIELD_NUMBER
      See Also:
  • Method Details

    • newInstance

      protected Object newInstance(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused)
      Overrides:
      newInstance 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
    • getName

      public String getName()
       The name of the dynamic module.
      
       The client is expected to have some configuration indicating where to search for the module. In
       Envoy, the search path can only be configured via the environment variable
       ``ENVOY_DYNAMIC_MODULES_SEARCH_PATH``. The actual search path is
       ``${ENVOY_DYNAMIC_MODULES_SEARCH_PATH}/lib${name}.so``.
      
       .. note::
         There is some remaining work to make the search path configurable via command line options.
       
      string name = 1 [(.validate.rules) = { ... }
      Specified by:
      getName in interface DynamicModuleConfigOrBuilder
      Returns:
      The name.
    • getNameBytes

      public com.google.protobuf.ByteString getNameBytes()
       The name of the dynamic module.
      
       The client is expected to have some configuration indicating where to search for the module. In
       Envoy, the search path can only be configured via the environment variable
       ``ENVOY_DYNAMIC_MODULES_SEARCH_PATH``. The actual search path is
       ``${ENVOY_DYNAMIC_MODULES_SEARCH_PATH}/lib${name}.so``.
      
       .. note::
         There is some remaining work to make the search path configurable via command line options.
       
      string name = 1 [(.validate.rules) = { ... }
      Specified by:
      getNameBytes in interface DynamicModuleConfigOrBuilder
      Returns:
      The bytes for name.
    • getDoNotClose

      public boolean getDoNotClose()
       If true, prevents the module from being unloaded with ``dlclose``.
      
       This is useful for modules that have global state that should not be unloaded. A module is
       closed when no more references to it exist in the process. For example, no HTTP filters are
       using the module (e.g. after configuration update).
      
       Defaults to ``false``.
       
      bool do_not_close = 3;
      Specified by:
      getDoNotClose in interface DynamicModuleConfigOrBuilder
      Returns:
      The doNotClose.
    • getLoadGlobally

      public boolean getLoadGlobally()
       If true, the dynamic module is loaded with the ``RTLD_GLOBAL`` flag.
      
       The dynamic module is loaded with the ``RTLD_LOCAL`` flag by default to avoid symbol conflicts
       when multiple modules are loaded. Set this to ``true`` to load the module with the
       ``RTLD_GLOBAL`` flag. This is useful for modules that need to share symbols with other dynamic
       libraries. For example, a module X may load another shared library Y that depends on some
       symbols defined in module X. In this case, module X must be loaded with the ``RTLD_GLOBAL``
       flag so that the symbols defined in module X are visible to library Y.
      
       .. warning::
         Use this option with caution as it may lead to symbol conflicts and undefined behavior if
         multiple modules define the same symbols and are loaded globally.
      
       Defaults to ``false``.
       
      bool load_globally = 4;
      Specified by:
      getLoadGlobally in interface DynamicModuleConfigOrBuilder
      Returns:
      The loadGlobally.
    • 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 DynamicModuleConfig parseFrom(ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException
      Throws:
      com.google.protobuf.InvalidProtocolBufferException
    • parseFrom

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

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

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

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

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

      public static DynamicModuleConfig parseFrom(InputStream input) throws IOException
      Throws:
      IOException
    • parseFrom

      public static DynamicModuleConfig parseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
      Throws:
      IOException
    • parseDelimitedFrom

      public static DynamicModuleConfig parseDelimitedFrom(InputStream input) throws IOException
      Throws:
      IOException
    • parseDelimitedFrom

      public static DynamicModuleConfig parseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
      Throws:
      IOException
    • parseFrom

      public static DynamicModuleConfig parseFrom(com.google.protobuf.CodedInputStream input) throws IOException
      Throws:
      IOException
    • parseFrom

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

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

      public static DynamicModuleConfig.Builder newBuilder()
    • newBuilder

      public static DynamicModuleConfig.Builder newBuilder(DynamicModuleConfig prototype)
    • toBuilder

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

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

      public static DynamicModuleConfig getDefaultInstance()
    • parser

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

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