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 CancelLegalHold

Source§

impl RuntimePlugin for CreateBackupPlan

Source§

impl RuntimePlugin for CreateBackupSelection

Source§

impl RuntimePlugin for CreateBackupVault

Source§

impl RuntimePlugin for CreateFramework

Source§

impl RuntimePlugin for CreateLegalHold

Source§

impl RuntimePlugin for CreateLogicallyAirGappedBackupVault

Source§

impl RuntimePlugin for CreateReportPlan

Source§

impl RuntimePlugin for CreateRestoreTestingPlan

Source§

impl RuntimePlugin for CreateRestoreTestingSelection

Source§

impl RuntimePlugin for DeleteBackupPlan

Source§

impl RuntimePlugin for DeleteBackupSelection

Source§

impl RuntimePlugin for DeleteBackupVault

Source§

impl RuntimePlugin for DeleteBackupVaultAccessPolicy

Source§

impl RuntimePlugin for DeleteBackupVaultLockConfiguration

Source§

impl RuntimePlugin for DeleteBackupVaultNotifications

Source§

impl RuntimePlugin for DeleteFramework

Source§

impl RuntimePlugin for DeleteRecoveryPoint

Source§

impl RuntimePlugin for DeleteReportPlan

Source§

impl RuntimePlugin for DeleteRestoreTestingPlan

Source§

impl RuntimePlugin for DeleteRestoreTestingSelection

Source§

impl RuntimePlugin for DescribeBackupJob

Source§

impl RuntimePlugin for DescribeBackupVault

Source§

impl RuntimePlugin for DescribeCopyJob

Source§

impl RuntimePlugin for DescribeFramework

Source§

impl RuntimePlugin for DescribeGlobalSettings

Source§

impl RuntimePlugin for DescribeProtectedResource

Source§

impl RuntimePlugin for DescribeRecoveryPoint

Source§

impl RuntimePlugin for DescribeRegionSettings

Source§

impl RuntimePlugin for DescribeReportJob

Source§

impl RuntimePlugin for DescribeReportPlan

Source§

impl RuntimePlugin for DescribeRestoreJob

Source§

impl RuntimePlugin for DisassociateRecoveryPoint

Source§

impl RuntimePlugin for DisassociateRecoveryPointFromParent

Source§

impl RuntimePlugin for ExportBackupPlanTemplate

Source§

impl RuntimePlugin for GetBackupPlan

Source§

impl RuntimePlugin for GetBackupPlanFromJSON

Source§

impl RuntimePlugin for GetBackupPlanFromTemplate

Source§

impl RuntimePlugin for GetBackupSelection

Source§

impl RuntimePlugin for GetBackupVaultAccessPolicy

Source§

impl RuntimePlugin for GetBackupVaultNotifications

Source§

impl RuntimePlugin for GetLegalHold

Source§

impl RuntimePlugin for GetRecoveryPointIndexDetails

Source§

impl RuntimePlugin for GetRecoveryPointRestoreMetadata

Source§

impl RuntimePlugin for GetRestoreJobMetadata

Source§

impl RuntimePlugin for GetRestoreTestingInferredMetadata

Source§

impl RuntimePlugin for GetRestoreTestingPlan

Source§

impl RuntimePlugin for GetRestoreTestingSelection

Source§

impl RuntimePlugin for GetSupportedResourceTypes

Source§

impl RuntimePlugin for ListBackupJobSummaries

Source§

impl RuntimePlugin for ListBackupJobs

Source§

impl RuntimePlugin for ListBackupPlanTemplates

Source§

impl RuntimePlugin for ListBackupPlanVersions

Source§

impl RuntimePlugin for ListBackupPlans

Source§

impl RuntimePlugin for ListBackupSelections

Source§

impl RuntimePlugin for ListBackupVaults

Source§

impl RuntimePlugin for ListCopyJobSummaries

Source§

impl RuntimePlugin for ListCopyJobs

Source§

impl RuntimePlugin for ListFrameworks

Source§

impl RuntimePlugin for ListIndexedRecoveryPoints

Source§

impl RuntimePlugin for ListLegalHolds

Source§

impl RuntimePlugin for ListProtectedResources

Source§

impl RuntimePlugin for ListProtectedResourcesByBackupVault

Source§

impl RuntimePlugin for ListRecoveryPointsByBackupVault

Source§

impl RuntimePlugin for ListRecoveryPointsByLegalHold

Source§

impl RuntimePlugin for ListRecoveryPointsByResource

Source§

impl RuntimePlugin for ListReportJobs

Source§

impl RuntimePlugin for ListReportPlans

Source§

impl RuntimePlugin for ListRestoreJobSummaries

Source§

impl RuntimePlugin for ListRestoreJobs

Source§

impl RuntimePlugin for ListRestoreJobsByProtectedResource

Source§

impl RuntimePlugin for ListRestoreTestingPlans

Source§

impl RuntimePlugin for ListRestoreTestingSelections

Source§

impl RuntimePlugin for ListTags

Source§

impl RuntimePlugin for PutBackupVaultAccessPolicy

Source§

impl RuntimePlugin for PutBackupVaultLockConfiguration

Source§

impl RuntimePlugin for PutBackupVaultNotifications

Source§

impl RuntimePlugin for PutRestoreValidationResult

Source§

impl RuntimePlugin for StartBackupJob

Source§

impl RuntimePlugin for StartCopyJob

Source§

impl RuntimePlugin for StartReportJob

Source§

impl RuntimePlugin for StartRestoreJob

Source§

impl RuntimePlugin for StopBackupJob

Source§

impl RuntimePlugin for TagResource

Source§

impl RuntimePlugin for UntagResource

Source§

impl RuntimePlugin for UpdateBackupPlan

Source§

impl RuntimePlugin for UpdateFramework

Source§

impl RuntimePlugin for UpdateGlobalSettings

Source§

impl RuntimePlugin for UpdateRecoveryPointIndexSettings

Source§

impl RuntimePlugin for UpdateRecoveryPointLifecycle

Source§

impl RuntimePlugin for UpdateRegionSettings

Source§

impl RuntimePlugin for UpdateReportPlan

Source§

impl RuntimePlugin for UpdateRestoreTestingPlan

Source§

impl RuntimePlugin for UpdateRestoreTestingSelection

Source§

impl RuntimePlugin for StaticRuntimePlugin

Source§

impl RuntimePlugin for SharedRuntimePlugin