RuntimePlugin

Trait RuntimePlugin 

Source
pub trait RuntimePlugin:
    Debug
    + Send
    + Sync {
    // Provided methods
    fn order(&self) -> Order { ... }
    fn config(&self) -> Option<FrozenLayer> { ... }
    fn runtime_components(
        &self,
        current_components: &RuntimeComponentsBuilder,
    ) -> Cow<'_, RuntimeComponentsBuilder> { ... }
}
Expand description

Runtime plugin trait

A RuntimePlugin is the unit of configuration for augmenting the client with new behavior.

Runtime plugins can register interceptors, set runtime components, and modify configuration.

Provided Methods§

Source

fn order(&self) -> Order

Runtime plugin ordering.

There are two runtime plugin “levels” that run in the following order:

  1. Service runtime plugins - runtime plugins that pertain to the entire service.
  2. Operation runtime plugins - runtime plugins relevant only to a single operation.

This function is used to determine runtime plugin order within those levels. So regardless of this Order value, service runtime plugins will still always execute before operation runtime plugins. However, Defaults service runtime plugins will run before Overrides service runtime plugins.

Source

fn config(&self) -> Option<FrozenLayer>

Optionally returns additional config that should be added to the ConfigBag.

As a best practice, a frozen layer should be stored on the runtime plugin instance as a member, and then cloned upon return since that clone is cheap. Constructing a new Layer and freezing it will require a lot of allocations.

Source

fn runtime_components( &self, current_components: &RuntimeComponentsBuilder, ) -> Cow<'_, RuntimeComponentsBuilder>

Returns a RuntimeComponentsBuilder to incorporate into the final runtime components.

The order of runtime plugins determines which runtime components “win”. Components set by later runtime plugins will override those set by earlier runtime plugins.

If no runtime component changes are desired, just return an empty builder.

This method returns a Cow for flexibility. Some implementers may want to store the components builder as a member and return a reference to it, while others may need to create the builder every call. If possible, returning a reference is preferred for performance.

Components configured by previous runtime plugins are in the current_components argument, and can be used to create nested/wrapped components, such as a connector calling into an inner (customer provided) connector.

Implementations on Foreign Types§

Source§

impl RuntimePlugin for PayloadSigningOverrideRuntimePlugin

Source§

impl RuntimePlugin for NoAuthRuntimePlugin

Source§

impl RuntimePlugin for EnforceContentLengthRuntimePlugin

Source§

impl RuntimePlugin for MetricsRuntimePlugin

Source§

impl RuntimePlugin for CannedResponseDeserializer

Source§

impl RuntimePlugin for CannedRequestSerializer

Implementors§

Source§

impl RuntimePlugin for AcceptSharedDirectory

Source§

impl RuntimePlugin for AddIpRoutes

Source§

impl RuntimePlugin for AddRegion

Source§

impl RuntimePlugin for AddTagsToResource

Source§

impl RuntimePlugin for CancelSchemaExtension

Source§

impl RuntimePlugin for ConnectDirectory

Source§

impl RuntimePlugin for CreateAlias

Source§

impl RuntimePlugin for CreateComputer

Source§

impl RuntimePlugin for CreateConditionalForwarder

Source§

impl RuntimePlugin for CreateDirectory

Source§

impl RuntimePlugin for CreateHybridAD

Source§

impl RuntimePlugin for CreateLogSubscription

Source§

impl RuntimePlugin for CreateMicrosoftAD

Source§

impl RuntimePlugin for CreateSnapshot

Source§

impl RuntimePlugin for CreateTrust

Source§

impl RuntimePlugin for DeleteADAssessment

Source§

impl RuntimePlugin for DeleteConditionalForwarder

Source§

impl RuntimePlugin for DeleteDirectory

Source§

impl RuntimePlugin for DeleteLogSubscription

Source§

impl RuntimePlugin for DeleteSnapshot

Source§

impl RuntimePlugin for DeleteTrust

Source§

impl RuntimePlugin for DeregisterCertificate

Source§

impl RuntimePlugin for DeregisterEventTopic

Source§

impl RuntimePlugin for DescribeADAssessment

Source§

impl RuntimePlugin for DescribeCAEnrollmentPolicy

Source§

impl RuntimePlugin for DescribeCertificate

Source§

impl RuntimePlugin for DescribeClientAuthenticationSettings

Source§

impl RuntimePlugin for DescribeConditionalForwarders

Source§

impl RuntimePlugin for DescribeDirectories

Source§

impl RuntimePlugin for DescribeDirectoryDataAccess

Source§

impl RuntimePlugin for DescribeDomainControllers

Source§

impl RuntimePlugin for DescribeEventTopics

Source§

impl RuntimePlugin for DescribeHybridADUpdate

Source§

impl RuntimePlugin for DescribeLDAPSSettings

Source§

impl RuntimePlugin for DescribeRegions

Source§

impl RuntimePlugin for DescribeSettings

Source§

impl RuntimePlugin for DescribeSharedDirectories

Source§

impl RuntimePlugin for DescribeSnapshots

Source§

impl RuntimePlugin for DescribeTrusts

Source§

impl RuntimePlugin for DescribeUpdateDirectory

Source§

impl RuntimePlugin for DisableCAEnrollmentPolicy

Source§

impl RuntimePlugin for DisableClientAuthentication

Source§

impl RuntimePlugin for DisableDirectoryDataAccess

Source§

impl RuntimePlugin for DisableLDAPS

Source§

impl RuntimePlugin for DisableRadius

Source§

impl RuntimePlugin for DisableSso

Source§

impl RuntimePlugin for EnableCAEnrollmentPolicy

Source§

impl RuntimePlugin for EnableClientAuthentication

Source§

impl RuntimePlugin for EnableDirectoryDataAccess

Source§

impl RuntimePlugin for EnableLDAPS

Source§

impl RuntimePlugin for EnableRadius

Source§

impl RuntimePlugin for EnableSso

Source§

impl RuntimePlugin for GetDirectoryLimits

Source§

impl RuntimePlugin for GetSnapshotLimits

Source§

impl RuntimePlugin for ListADAssessments

Source§

impl RuntimePlugin for ListCertificates

Source§

impl RuntimePlugin for ListIpRoutes

Source§

impl RuntimePlugin for ListLogSubscriptions

Source§

impl RuntimePlugin for ListSchemaExtensions

Source§

impl RuntimePlugin for ListTagsForResource

Source§

impl RuntimePlugin for RegisterCertificate

Source§

impl RuntimePlugin for RegisterEventTopic

Source§

impl RuntimePlugin for RejectSharedDirectory

Source§

impl RuntimePlugin for RemoveIpRoutes

Source§

impl RuntimePlugin for RemoveRegion

Source§

impl RuntimePlugin for RemoveTagsFromResource

Source§

impl RuntimePlugin for ResetUserPassword

Source§

impl RuntimePlugin for RestoreFromSnapshot

Source§

impl RuntimePlugin for ShareDirectory

Source§

impl RuntimePlugin for StartADAssessment

Source§

impl RuntimePlugin for StartSchemaExtension

Source§

impl RuntimePlugin for UnshareDirectory

Source§

impl RuntimePlugin for UpdateConditionalForwarder

Source§

impl RuntimePlugin for UpdateDirectorySetup

Source§

impl RuntimePlugin for UpdateHybridAD

Source§

impl RuntimePlugin for UpdateNumberOfDomainControllers

Source§

impl RuntimePlugin for UpdateRadius

Source§

impl RuntimePlugin for UpdateSettings

Source§

impl RuntimePlugin for UpdateTrust

Source§

impl RuntimePlugin for VerifyTrust

Source§

impl RuntimePlugin for StaticRuntimePlugin

Source§

impl RuntimePlugin for SharedRuntimePlugin