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 NoAuthRuntimePlugin

source§

impl RuntimePlugin for CannedResponseDeserializer

source§

impl RuntimePlugin for CannedRequestSerializer

Implementors§

source§

impl RuntimePlugin for ActivateEvaluationForm

source§

impl RuntimePlugin for AssociateAnalyticsDataSet

source§

impl RuntimePlugin for AssociateApprovedOrigin

source§

impl RuntimePlugin for AssociateBot

source§

impl RuntimePlugin for AssociateDefaultVocabulary

source§

impl RuntimePlugin for AssociateFlow

source§

impl RuntimePlugin for AssociateInstanceStorageConfig

source§

impl RuntimePlugin for AssociateLambdaFunction

source§

impl RuntimePlugin for AssociateLexBot

source§

impl RuntimePlugin for AssociatePhoneNumberContactFlow

source§

impl RuntimePlugin for AssociateQueueQuickConnects

source§

impl RuntimePlugin for AssociateRoutingProfileQueues

source§

impl RuntimePlugin for AssociateSecurityKey

source§

impl RuntimePlugin for AssociateTrafficDistributionGroupUser

source§

impl RuntimePlugin for BatchAssociateAnalyticsDataSet

source§

impl RuntimePlugin for BatchDisassociateAnalyticsDataSet

source§

impl RuntimePlugin for BatchGetFlowAssociation

source§

impl RuntimePlugin for BatchPutContact

source§

impl RuntimePlugin for ClaimPhoneNumber

source§

impl RuntimePlugin for CreateAgentStatus

source§

impl RuntimePlugin for CreateContactFlow

source§

impl RuntimePlugin for CreateContactFlowModule

source§

impl RuntimePlugin for CreateEvaluationForm

source§

impl RuntimePlugin for CreateHoursOfOperation

source§

impl RuntimePlugin for CreateInstance

source§

impl RuntimePlugin for CreateIntegrationAssociation

source§

impl RuntimePlugin for CreateParticipant

source§

impl RuntimePlugin for CreatePersistentContactAssociation

source§

impl RuntimePlugin for CreatePrompt

source§

impl RuntimePlugin for CreateQueue

source§

impl RuntimePlugin for CreateQuickConnect

source§

impl RuntimePlugin for CreateRoutingProfile

source§

impl RuntimePlugin for CreateRule

source§

impl RuntimePlugin for CreateSecurityProfile

source§

impl RuntimePlugin for CreateTaskTemplate

source§

impl RuntimePlugin for CreateTrafficDistributionGroup

source§

impl RuntimePlugin for CreateUseCase

source§

impl RuntimePlugin for CreateUser

source§

impl RuntimePlugin for CreateUserHierarchyGroup

source§

impl RuntimePlugin for CreateView

source§

impl RuntimePlugin for CreateViewVersion

source§

impl RuntimePlugin for CreateVocabulary

source§

impl RuntimePlugin for DeactivateEvaluationForm

source§

impl RuntimePlugin for DeleteContactEvaluation

source§

impl RuntimePlugin for DeleteContactFlow

source§

impl RuntimePlugin for DeleteContactFlowModule

source§

impl RuntimePlugin for DeleteEvaluationForm

source§

impl RuntimePlugin for DeleteHoursOfOperation

source§

impl RuntimePlugin for DeleteInstance

source§

impl RuntimePlugin for DeleteIntegrationAssociation

source§

impl RuntimePlugin for DeletePrompt

source§

impl RuntimePlugin for DeleteQueue

source§

impl RuntimePlugin for DeleteQuickConnect

source§

impl RuntimePlugin for DeleteRoutingProfile

source§

impl RuntimePlugin for DeleteRule

source§

impl RuntimePlugin for DeleteSecurityProfile

source§

impl RuntimePlugin for DeleteTaskTemplate

source§

impl RuntimePlugin for DeleteTrafficDistributionGroup

source§

impl RuntimePlugin for DeleteUseCase

source§

impl RuntimePlugin for DeleteUser

source§

impl RuntimePlugin for DeleteUserHierarchyGroup

source§

impl RuntimePlugin for DeleteView

source§

impl RuntimePlugin for DeleteViewVersion

source§

impl RuntimePlugin for DeleteVocabulary

source§

impl RuntimePlugin for DescribeAgentStatus

source§

impl RuntimePlugin for DescribeContact

source§

impl RuntimePlugin for DescribeContactEvaluation

source§

impl RuntimePlugin for DescribeContactFlow

source§

impl RuntimePlugin for DescribeContactFlowModule

source§

impl RuntimePlugin for DescribeEvaluationForm

source§

impl RuntimePlugin for DescribeHoursOfOperation

source§

impl RuntimePlugin for DescribeInstance

source§

impl RuntimePlugin for DescribeInstanceAttribute

source§

impl RuntimePlugin for DescribeInstanceStorageConfig

source§

impl RuntimePlugin for DescribePhoneNumber

source§

impl RuntimePlugin for DescribePrompt

source§

impl RuntimePlugin for DescribeQueue

source§

impl RuntimePlugin for DescribeQuickConnect

source§

impl RuntimePlugin for DescribeRoutingProfile

source§

impl RuntimePlugin for DescribeRule

source§

impl RuntimePlugin for DescribeSecurityProfile

source§

impl RuntimePlugin for DescribeTrafficDistributionGroup

source§

impl RuntimePlugin for DescribeUser

source§

impl RuntimePlugin for DescribeUserHierarchyGroup

source§

impl RuntimePlugin for DescribeUserHierarchyStructure

source§

impl RuntimePlugin for DescribeView

source§

impl RuntimePlugin for DescribeVocabulary

source§

impl RuntimePlugin for DisassociateAnalyticsDataSet

source§

impl RuntimePlugin for DisassociateApprovedOrigin

source§

impl RuntimePlugin for DisassociateBot

source§

impl RuntimePlugin for DisassociateFlow

source§

impl RuntimePlugin for DisassociateInstanceStorageConfig

source§

impl RuntimePlugin for DisassociateLambdaFunction

source§

impl RuntimePlugin for DisassociateLexBot

source§

impl RuntimePlugin for DisassociatePhoneNumberContactFlow

source§

impl RuntimePlugin for DisassociateQueueQuickConnects

source§

impl RuntimePlugin for DisassociateRoutingProfileQueues

source§

impl RuntimePlugin for DisassociateSecurityKey

source§

impl RuntimePlugin for DisassociateTrafficDistributionGroupUser

source§

impl RuntimePlugin for DismissUserContact

source§

impl RuntimePlugin for GetContactAttributes

source§

impl RuntimePlugin for GetCurrentMetricData

source§

impl RuntimePlugin for GetCurrentUserData

source§

impl RuntimePlugin for GetFederationToken

source§

impl RuntimePlugin for GetFlowAssociation

source§

impl RuntimePlugin for GetMetricData

source§

impl RuntimePlugin for GetMetricDataV2

source§

impl RuntimePlugin for GetPromptFile

source§

impl RuntimePlugin for GetTaskTemplate

source§

impl RuntimePlugin for GetTrafficDistribution

source§

impl RuntimePlugin for ImportPhoneNumber

source§

impl RuntimePlugin for ListAgentStatuses

source§

impl RuntimePlugin for ListAnalyticsDataAssociations

source§

impl RuntimePlugin for ListApprovedOrigins

source§

impl RuntimePlugin for ListBots

source§

impl RuntimePlugin for ListContactEvaluations

source§

impl RuntimePlugin for ListContactFlowModules

source§

impl RuntimePlugin for ListContactFlows

source§

impl RuntimePlugin for ListContactReferences

source§

impl RuntimePlugin for ListDefaultVocabularies

source§

impl RuntimePlugin for ListEvaluationFormVersions

source§

impl RuntimePlugin for ListEvaluationForms

source§

impl RuntimePlugin for ListFlowAssociations

source§

impl RuntimePlugin for ListHoursOfOperations

source§

impl RuntimePlugin for ListInstanceAttributes

source§

impl RuntimePlugin for ListInstanceStorageConfigs

source§

impl RuntimePlugin for ListInstances

source§

impl RuntimePlugin for ListIntegrationAssociations

source§

impl RuntimePlugin for ListLambdaFunctions

source§

impl RuntimePlugin for ListLexBots

source§

impl RuntimePlugin for ListPhoneNumbers

source§

impl RuntimePlugin for ListPhoneNumbersV2

source§

impl RuntimePlugin for ListPrompts

source§

impl RuntimePlugin for ListQueueQuickConnects

source§

impl RuntimePlugin for ListQueues

source§

impl RuntimePlugin for ListQuickConnects

source§

impl RuntimePlugin for ListRealtimeContactAnalysisSegmentsV2

source§

impl RuntimePlugin for ListRoutingProfileQueues

source§

impl RuntimePlugin for ListRoutingProfiles

source§

impl RuntimePlugin for ListRules

source§

impl RuntimePlugin for ListSecurityKeys

source§

impl RuntimePlugin for ListSecurityProfileApplications

source§

impl RuntimePlugin for ListSecurityProfilePermissions

source§

impl RuntimePlugin for ListSecurityProfiles

source§

impl RuntimePlugin for ListTagsForResource

source§

impl RuntimePlugin for ListTaskTemplates

source§

impl RuntimePlugin for ListTrafficDistributionGroupUsers

source§

impl RuntimePlugin for ListTrafficDistributionGroups

source§

impl RuntimePlugin for ListUseCases

source§

impl RuntimePlugin for ListUserHierarchyGroups

source§

impl RuntimePlugin for ListUsers

source§

impl RuntimePlugin for ListViewVersions

source§

impl RuntimePlugin for ListViews

source§

impl RuntimePlugin for MonitorContact

source§

impl RuntimePlugin for PauseContact

source§

impl RuntimePlugin for PutUserStatus

source§

impl RuntimePlugin for ReleasePhoneNumber

source§

impl RuntimePlugin for ReplicateInstance

source§

impl RuntimePlugin for ResumeContact

source§

impl RuntimePlugin for ResumeContactRecording

source§

impl RuntimePlugin for SearchAvailablePhoneNumbers

source§

impl RuntimePlugin for SearchHoursOfOperations

source§

impl RuntimePlugin for SearchPrompts

source§

impl RuntimePlugin for SearchQueues

source§

impl RuntimePlugin for SearchQuickConnects

source§

impl RuntimePlugin for SearchResourceTags

source§

impl RuntimePlugin for SearchRoutingProfiles

source§

impl RuntimePlugin for SearchSecurityProfiles

source§

impl RuntimePlugin for SearchUsers

source§

impl RuntimePlugin for SearchVocabularies

source§

impl RuntimePlugin for SendChatIntegrationEvent

source§

impl RuntimePlugin for StartChatContact

source§

impl RuntimePlugin for StartContactEvaluation

source§

impl RuntimePlugin for StartContactRecording

source§

impl RuntimePlugin for StartContactStreaming

source§

impl RuntimePlugin for StartOutboundVoiceContact

source§

impl RuntimePlugin for StartTaskContact

source§

impl RuntimePlugin for StartWebRTCContact

source§

impl RuntimePlugin for StopContact

source§

impl RuntimePlugin for StopContactRecording

source§

impl RuntimePlugin for StopContactStreaming

source§

impl RuntimePlugin for SubmitContactEvaluation

source§

impl RuntimePlugin for SuspendContactRecording

source§

impl RuntimePlugin for TagContact

source§

impl RuntimePlugin for TagResource

source§

impl RuntimePlugin for TransferContact

source§

impl RuntimePlugin for UntagContact

source§

impl RuntimePlugin for UntagResource

source§

impl RuntimePlugin for UpdateAgentStatus

source§

impl RuntimePlugin for UpdateContact

source§

impl RuntimePlugin for UpdateContactAttributes

source§

impl RuntimePlugin for UpdateContactEvaluation

source§

impl RuntimePlugin for UpdateContactFlowContent

source§

impl RuntimePlugin for UpdateContactFlowMetadata

source§

impl RuntimePlugin for UpdateContactFlowModuleContent

source§

impl RuntimePlugin for UpdateContactFlowModuleMetadata

source§

impl RuntimePlugin for UpdateContactFlowName

source§

impl RuntimePlugin for UpdateContactSchedule

source§

impl RuntimePlugin for UpdateEvaluationForm

source§

impl RuntimePlugin for UpdateHoursOfOperation

source§

impl RuntimePlugin for UpdateInstanceAttribute

source§

impl RuntimePlugin for UpdateInstanceStorageConfig

source§

impl RuntimePlugin for UpdateParticipantRoleConfig

source§

impl RuntimePlugin for UpdatePhoneNumber

source§

impl RuntimePlugin for UpdatePhoneNumberMetadata

source§

impl RuntimePlugin for UpdatePrompt

source§

impl RuntimePlugin for UpdateQueueHoursOfOperation

source§

impl RuntimePlugin for UpdateQueueMaxContacts

source§

impl RuntimePlugin for UpdateQueueName

source§

impl RuntimePlugin for UpdateQueueOutboundCallerConfig

source§

impl RuntimePlugin for UpdateQueueStatus

source§

impl RuntimePlugin for UpdateQuickConnectConfig

source§

impl RuntimePlugin for UpdateQuickConnectName

source§

impl RuntimePlugin for UpdateRoutingProfileAgentAvailabilityTimer

source§

impl RuntimePlugin for UpdateRoutingProfileConcurrency

source§

impl RuntimePlugin for UpdateRoutingProfileDefaultOutboundQueue

source§

impl RuntimePlugin for UpdateRoutingProfileName

source§

impl RuntimePlugin for UpdateRoutingProfileQueues

source§

impl RuntimePlugin for UpdateRule

source§

impl RuntimePlugin for UpdateSecurityProfile

source§

impl RuntimePlugin for UpdateTaskTemplate

source§

impl RuntimePlugin for UpdateTrafficDistribution

source§

impl RuntimePlugin for UpdateUserHierarchy

source§

impl RuntimePlugin for UpdateUserHierarchyGroupName

source§

impl RuntimePlugin for UpdateUserHierarchyStructure

source§

impl RuntimePlugin for UpdateUserIdentityInfo

source§

impl RuntimePlugin for UpdateUserPhoneConfig

source§

impl RuntimePlugin for UpdateUserRoutingProfile

source§

impl RuntimePlugin for UpdateUserSecurityProfiles

source§

impl RuntimePlugin for UpdateViewContent

source§

impl RuntimePlugin for UpdateViewMetadata

source§

impl RuntimePlugin for StaticRuntimePlugin

source§

impl RuntimePlugin for SharedRuntimePlugin