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 ClassesModifier and TypeClassDescriptionstatic final classConfiguration 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
FieldsModifier and TypeFieldDescriptionstatic final intstatic final intstatic final intFields inherited from class com.google.protobuf.GeneratedMessageV3
alwaysUseFieldBuilders, unknownFieldsFields inherited from class com.google.protobuf.AbstractMessage
memoizedSizeFields inherited from class com.google.protobuf.AbstractMessageLite
memoizedHashCode -
Method Summary
Modifier and TypeMethodDescriptionbooleanstatic DynamicModuleConfigstatic final com.google.protobuf.Descriptors.DescriptorbooleanIf true, prevents the module from being unloaded with ``dlclose``.booleanIf true, the dynamic module is loaded with the ``RTLD_GLOBAL`` flag.getName()The name of the dynamic module.com.google.protobuf.ByteStringThe name of the dynamic module.com.google.protobuf.Parser<DynamicModuleConfig>intinthashCode()protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTablefinal booleanstatic DynamicModuleConfig.Builderstatic DynamicModuleConfig.BuildernewBuilder(DynamicModuleConfig prototype) protected DynamicModuleConfig.BuildernewBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) protected ObjectnewInstance(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused) static DynamicModuleConfigparseDelimitedFrom(InputStream input) static DynamicModuleConfigparseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static DynamicModuleConfigparseFrom(byte[] data) static DynamicModuleConfigparseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static DynamicModuleConfigparseFrom(com.google.protobuf.ByteString data) static DynamicModuleConfigparseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static DynamicModuleConfigparseFrom(com.google.protobuf.CodedInputStream input) static DynamicModuleConfigparseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static DynamicModuleConfigparseFrom(InputStream input) static DynamicModuleConfigparseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static DynamicModuleConfigparseFrom(ByteBuffer data) static DynamicModuleConfigparseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static com.google.protobuf.Parser<DynamicModuleConfig>parser()voidwriteTo(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, writeStringNoTagMethods inherited from class com.google.protobuf.AbstractMessage
findInitializationErrors, getInitializationErrorString, hashBoolean, hashEnum, hashEnumList, hashFields, hashLong, toStringMethods inherited from class com.google.protobuf.AbstractMessageLite
addAll, addAll, checkByteStringIsUtf8, toByteArray, toByteString, writeDelimitedTo, writeToMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface com.google.protobuf.MessageLite
toByteArray, toByteString, writeDelimitedTo, writeToMethods 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
- Overrides:
newInstancein classcom.google.protobuf.GeneratedMessageV3
-
getDescriptor
public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() -
internalGetFieldAccessorTable
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()- Specified by:
internalGetFieldAccessorTablein classcom.google.protobuf.GeneratedMessageV3
-
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:
getNamein interfaceDynamicModuleConfigOrBuilder- 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:
getNameBytesin interfaceDynamicModuleConfigOrBuilder- 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:
getDoNotClosein interfaceDynamicModuleConfigOrBuilder- 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:
getLoadGloballyin interfaceDynamicModuleConfigOrBuilder- Returns:
- The loadGlobally.
-
isInitialized
public final boolean isInitialized()- Specified by:
isInitializedin interfacecom.google.protobuf.MessageLiteOrBuilder- Overrides:
isInitializedin classcom.google.protobuf.GeneratedMessageV3
-
writeTo
- Specified by:
writeToin interfacecom.google.protobuf.MessageLite- Overrides:
writeToin classcom.google.protobuf.GeneratedMessageV3- Throws:
IOException
-
getSerializedSize
public int getSerializedSize()- Specified by:
getSerializedSizein interfacecom.google.protobuf.MessageLite- Overrides:
getSerializedSizein classcom.google.protobuf.GeneratedMessageV3
-
equals
- Specified by:
equalsin interfacecom.google.protobuf.Message- Overrides:
equalsin classcom.google.protobuf.AbstractMessage
-
hashCode
public int hashCode()- Specified by:
hashCodein interfacecom.google.protobuf.Message- Overrides:
hashCodein classcom.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
- Throws:
IOException
-
parseFrom
public static DynamicModuleConfig parseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Throws:
IOException
-
parseDelimitedFrom
- 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
- Specified by:
newBuilderForTypein interfacecom.google.protobuf.Message- Specified by:
newBuilderForTypein interfacecom.google.protobuf.MessageLite
-
newBuilder
-
newBuilder
-
toBuilder
- Specified by:
toBuilderin interfacecom.google.protobuf.Message- Specified by:
toBuilderin interfacecom.google.protobuf.MessageLite
-
newBuilderForType
protected DynamicModuleConfig.Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) - Specified by:
newBuilderForTypein classcom.google.protobuf.GeneratedMessageV3
-
getDefaultInstance
-
parser
-
getParserForType
- Specified by:
getParserForTypein interfacecom.google.protobuf.Message- Specified by:
getParserForTypein interfacecom.google.protobuf.MessageLite- Overrides:
getParserForTypein classcom.google.protobuf.GeneratedMessageV3
-
getDefaultInstanceForType
- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageLiteOrBuilder- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageOrBuilder
-