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 AssociateMember

Source§

impl RuntimePlugin for BatchAssociateCodeSecurityScanConfiguration

Source§

impl RuntimePlugin for BatchDisassociateCodeSecurityScanConfiguration

Source§

impl RuntimePlugin for BatchGetAccountStatus

Source§

impl RuntimePlugin for BatchGetCodeSnippet

Source§

impl RuntimePlugin for BatchGetFindingDetails

Source§

impl RuntimePlugin for BatchGetFreeTrialInfo

Source§

impl RuntimePlugin for BatchGetMemberEc2DeepInspectionStatus

Source§

impl RuntimePlugin for BatchUpdateMemberEc2DeepInspectionStatus

Source§

impl RuntimePlugin for CancelFindingsReport

Source§

impl RuntimePlugin for CancelSbomExport

Source§

impl RuntimePlugin for CreateCisScanConfiguration

Source§

impl RuntimePlugin for CreateCodeSecurityIntegration

Source§

impl RuntimePlugin for CreateCodeSecurityScanConfiguration

Source§

impl RuntimePlugin for CreateFilter

Source§

impl RuntimePlugin for CreateFindingsReport

Source§

impl RuntimePlugin for CreateSbomExport

Source§

impl RuntimePlugin for DeleteCisScanConfiguration

Source§

impl RuntimePlugin for DeleteCodeSecurityIntegration

Source§

impl RuntimePlugin for DeleteCodeSecurityScanConfiguration

Source§

impl RuntimePlugin for DeleteFilter

Source§

impl RuntimePlugin for DescribeOrganizationConfiguration

Source§

impl RuntimePlugin for Disable

Source§

impl RuntimePlugin for DisableDelegatedAdminAccount

Source§

impl RuntimePlugin for DisassociateMember

Source§

impl RuntimePlugin for Enable

Source§

impl RuntimePlugin for EnableDelegatedAdminAccount

Source§

impl RuntimePlugin for GetCisScanReport

Source§

impl RuntimePlugin for GetCisScanResultDetails

Source§

impl RuntimePlugin for GetClustersForImage

Source§

impl RuntimePlugin for GetCodeSecurityIntegration

Source§

impl RuntimePlugin for GetCodeSecurityScan

Source§

impl RuntimePlugin for GetCodeSecurityScanConfiguration

Source§

impl RuntimePlugin for GetConfiguration

Source§

impl RuntimePlugin for GetDelegatedAdminAccount

Source§

impl RuntimePlugin for GetEc2DeepInspectionConfiguration

Source§

impl RuntimePlugin for GetEncryptionKey

Source§

impl RuntimePlugin for GetFindingsReportStatus

Source§

impl RuntimePlugin for GetMember

Source§

impl RuntimePlugin for GetSbomExport

Source§

impl RuntimePlugin for ListAccountPermissions

Source§

impl RuntimePlugin for ListCisScanConfigurations

Source§

impl RuntimePlugin for ListCisScanResultsAggregatedByChecks

Source§

impl RuntimePlugin for ListCisScanResultsAggregatedByTargetResource

Source§

impl RuntimePlugin for ListCisScans

Source§

impl RuntimePlugin for ListCodeSecurityIntegrations

Source§

impl RuntimePlugin for ListCodeSecurityScanConfigurationAssociations

Source§

impl RuntimePlugin for ListCodeSecurityScanConfigurations

Source§

impl RuntimePlugin for ListCoverage

Source§

impl RuntimePlugin for ListCoverageStatistics

Source§

impl RuntimePlugin for ListDelegatedAdminAccounts

Source§

impl RuntimePlugin for ListFilters

Source§

impl RuntimePlugin for ListFindingAggregations

Source§

impl RuntimePlugin for ListFindings

Source§

impl RuntimePlugin for ListMembers

Source§

impl RuntimePlugin for ListTagsForResource

Source§

impl RuntimePlugin for ListUsageTotals

Source§

impl RuntimePlugin for ResetEncryptionKey

Source§

impl RuntimePlugin for SearchVulnerabilities

Source§

impl RuntimePlugin for SendCisSessionHealth

Source§

impl RuntimePlugin for SendCisSessionTelemetry

Source§

impl RuntimePlugin for StartCisSession

Source§

impl RuntimePlugin for StartCodeSecurityScan

Source§

impl RuntimePlugin for StopCisSession

Source§

impl RuntimePlugin for TagResource

Source§

impl RuntimePlugin for UntagResource

Source§

impl RuntimePlugin for UpdateCisScanConfiguration

Source§

impl RuntimePlugin for UpdateCodeSecurityIntegration

Source§

impl RuntimePlugin for UpdateCodeSecurityScanConfiguration

Source§

impl RuntimePlugin for UpdateConfiguration

Source§

impl RuntimePlugin for UpdateEc2DeepInspectionConfiguration

Source§

impl RuntimePlugin for UpdateEncryptionKey

Source§

impl RuntimePlugin for UpdateFilter

Source§

impl RuntimePlugin for UpdateOrgEc2DeepInspectionConfiguration

Source§

impl RuntimePlugin for UpdateOrganizationConfiguration

Source§

impl RuntimePlugin for StaticRuntimePlugin

Source§

impl RuntimePlugin for SharedRuntimePlugin