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 AcceptInvitation

Source§

impl RuntimePlugin for BatchGetCustomDataIdentifiers

Source§

impl RuntimePlugin for BatchUpdateAutomatedDiscoveryAccounts

Source§

impl RuntimePlugin for CreateAllowList

Source§

impl RuntimePlugin for CreateClassificationJob

Source§

impl RuntimePlugin for CreateCustomDataIdentifier

Source§

impl RuntimePlugin for CreateFindingsFilter

Source§

impl RuntimePlugin for CreateInvitations

Source§

impl RuntimePlugin for CreateMember

Source§

impl RuntimePlugin for CreateSampleFindings

Source§

impl RuntimePlugin for DeclineInvitations

Source§

impl RuntimePlugin for DeleteAllowList

Source§

impl RuntimePlugin for DeleteCustomDataIdentifier

Source§

impl RuntimePlugin for DeleteFindingsFilter

Source§

impl RuntimePlugin for DeleteInvitations

Source§

impl RuntimePlugin for DeleteMember

Source§

impl RuntimePlugin for DescribeBuckets

Source§

impl RuntimePlugin for DescribeClassificationJob

Source§

impl RuntimePlugin for DescribeOrganizationConfiguration

Source§

impl RuntimePlugin for DisableMacie

Source§

impl RuntimePlugin for DisableOrganizationAdminAccount

Source§

impl RuntimePlugin for DisassociateFromAdministratorAccount

Source§

impl RuntimePlugin for DisassociateFromMasterAccount

Source§

impl RuntimePlugin for DisassociateMember

Source§

impl RuntimePlugin for EnableMacie

Source§

impl RuntimePlugin for EnableOrganizationAdminAccount

Source§

impl RuntimePlugin for GetAdministratorAccount

Source§

impl RuntimePlugin for GetAllowList

Source§

impl RuntimePlugin for GetAutomatedDiscoveryConfiguration

Source§

impl RuntimePlugin for GetBucketStatistics

Source§

impl RuntimePlugin for GetClassificationExportConfiguration

Source§

impl RuntimePlugin for GetClassificationScope

Source§

impl RuntimePlugin for GetCustomDataIdentifier

Source§

impl RuntimePlugin for GetFindingStatistics

Source§

impl RuntimePlugin for GetFindings

Source§

impl RuntimePlugin for GetFindingsFilter

Source§

impl RuntimePlugin for GetFindingsPublicationConfiguration

Source§

impl RuntimePlugin for GetInvitationsCount

Source§

impl RuntimePlugin for GetMacieSession

Source§

impl RuntimePlugin for GetMasterAccount

Source§

impl RuntimePlugin for GetMember

Source§

impl RuntimePlugin for GetResourceProfile

Source§

impl RuntimePlugin for GetRevealConfiguration

Source§

impl RuntimePlugin for GetSensitiveDataOccurrences

Source§

impl RuntimePlugin for GetSensitiveDataOccurrencesAvailability

Source§

impl RuntimePlugin for GetSensitivityInspectionTemplate

Source§

impl RuntimePlugin for GetUsageStatistics

Source§

impl RuntimePlugin for GetUsageTotals

Source§

impl RuntimePlugin for ListAllowLists

Source§

impl RuntimePlugin for ListAutomatedDiscoveryAccounts

Source§

impl RuntimePlugin for ListClassificationJobs

Source§

impl RuntimePlugin for ListClassificationScopes

Source§

impl RuntimePlugin for ListCustomDataIdentifiers

Source§

impl RuntimePlugin for ListFindings

Source§

impl RuntimePlugin for ListFindingsFilters

Source§

impl RuntimePlugin for ListInvitations

Source§

impl RuntimePlugin for ListManagedDataIdentifiers

Source§

impl RuntimePlugin for ListMembers

Source§

impl RuntimePlugin for ListOrganizationAdminAccounts

Source§

impl RuntimePlugin for ListResourceProfileArtifacts

Source§

impl RuntimePlugin for ListResourceProfileDetections

Source§

impl RuntimePlugin for ListSensitivityInspectionTemplates

Source§

impl RuntimePlugin for ListTagsForResource

Source§

impl RuntimePlugin for PutClassificationExportConfiguration

Source§

impl RuntimePlugin for PutFindingsPublicationConfiguration

Source§

impl RuntimePlugin for SearchResources

Source§

impl RuntimePlugin for TagResource

Source§

impl RuntimePlugin for TestCustomDataIdentifier

Source§

impl RuntimePlugin for UntagResource

Source§

impl RuntimePlugin for UpdateAllowList

Source§

impl RuntimePlugin for UpdateAutomatedDiscoveryConfiguration

Source§

impl RuntimePlugin for UpdateClassificationJob

Source§

impl RuntimePlugin for UpdateClassificationScope

Source§

impl RuntimePlugin for UpdateFindingsFilter

Source§

impl RuntimePlugin for UpdateMacieSession

Source§

impl RuntimePlugin for UpdateMemberSession

Source§

impl RuntimePlugin for UpdateOrganizationConfiguration

Source§

impl RuntimePlugin for UpdateResourceProfile

Source§

impl RuntimePlugin for UpdateResourceProfileDetections

Source§

impl RuntimePlugin for UpdateRevealConfiguration

Source§

impl RuntimePlugin for UpdateSensitivityInspectionTemplate

Source§

impl RuntimePlugin for StaticRuntimePlugin

Source§

impl RuntimePlugin for SharedRuntimePlugin