Class AbstractEndpoint
java.lang.Object
io.awspring.cloud.sqs.config.AbstractEndpoint
- All Implemented Interfaces:
Endpoint,HandlerMethodEndpoint
- Direct Known Subclasses:
MultiMethodSqsEndpoint,SqsEndpoint
Base class for implementing a
HandlerMethodEndpoint.- Since:
- 3.0
- Author:
- Tomaz Fernandes, José Iêdo
-
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedAbstractEndpoint(Collection<String> queueNames, @Nullable String listenerContainerFactoryName, String id) -
Method Summary
Modifier and TypeMethodDescriptionvoidconfigureListenerMode(Consumer<ListenerMode> consumer) Allows configuring theListenerModefor this endpoint.protected <T> AsyncMessageListener<T> createAsyncMessageListenerInstance(InvocableHandlerMethod handlerMethod) protected <T> MessageListener<T> createMessageListenerInstance(InvocableHandlerMethod handlerMethod) getBean()Get the bean instance to be used when handling a message for this endpoint.getId()An optional id for this endpoint.The name of the factory bean that will process this endpoint.The logical names for this endpoint.@Nullable MessageHandlerMethodFactoryGet theMessageHandlerMethodFactoryto be used for handling messages in this endpoint.voidsetArgumentResolvers(@Nullable List<HandlerMethodArgumentResolver> argumentResolvers) Set the argument resolvers to be used for inferring payload types if a methodPayloadTypeInferrer is set.voidSet the bean instance to be used when handling a message for this endpoint.voidsetHandlerMethodFactory(MessageHandlerMethodFactory handlerMethodFactory) Set theMessageHandlerMethodFactoryto be used for handling messages in this endpoint.voidSet the method to be used when handling a message for this endpoint.voidsetMethodPayloadTypeInferrer(@Nullable MethodPayloadTypeInferrer inferrer) Set theMethodPayloadTypeInferrerto be used for inferring payload types from method signatures.<T> voidsetupContainer(MessageListenerContainer<T> container) Configure the provided container for this endpoint.
-
Constructor Details
-
AbstractEndpoint
protected AbstractEndpoint(Collection<String> queueNames, @Nullable String listenerContainerFactoryName, String id)
-
-
Method Details
-
getLogicalNames
Description copied from interface:EndpointThe logical names for this endpoint.- Specified by:
getLogicalNamesin interfaceEndpoint- Returns:
- the logical names.
-
getListenerContainerFactoryName
Description copied from interface:EndpointThe name of the factory bean that will process this endpoint.- Specified by:
getListenerContainerFactoryNamein interfaceEndpoint- Returns:
- the factory bean name.
-
getId
-
setBean
Set the bean instance to be used when handling a message for this endpoint.- Specified by:
setBeanin interfaceHandlerMethodEndpoint- Parameters:
bean- the bean instance.
-
getBean
Get the bean instance to be used when handling a message for this endpoint.- Returns:
- the bean instance.
-
setMethod
Set the method to be used when handling a message for this endpoint.- Specified by:
setMethodin interfaceHandlerMethodEndpoint- Parameters:
method- the method.
-
setHandlerMethodFactory
Set theMessageHandlerMethodFactoryto be used for handling messages in this endpoint.- Specified by:
setHandlerMethodFactoryin interfaceHandlerMethodEndpoint- Parameters:
handlerMethodFactory- the factory.
-
getMessageHandlerMethodFactory
Get theMessageHandlerMethodFactoryto be used for handling messages in this endpoint.- Returns:
- the factory.
-
setMethodPayloadTypeInferrer
Set theMethodPayloadTypeInferrerto be used for inferring payload types from method signatures.- Specified by:
setMethodPayloadTypeInferrerin interfaceHandlerMethodEndpoint- Parameters:
inferrer- the inferrer instance, or null to disable inference.
-
setArgumentResolvers
Set the argument resolvers to be used for inferring payload types if a methodPayloadTypeInferrer is set.- Specified by:
setArgumentResolversin interfaceHandlerMethodEndpoint- Parameters:
argumentResolvers- the argument resolvers, may be null.
-
configureListenerMode
Description copied from interface:HandlerMethodEndpointAllows configuring theListenerModefor this endpoint.- Specified by:
configureListenerModein interfaceHandlerMethodEndpoint- Parameters:
consumer- a consumer for the strategy used by this endpoint.
-
setupContainer
Configure the provided container for this endpoint.- Specified by:
setupContainerin interfaceEndpoint- Parameters:
container- the container to be configured.
-
createMessageListenerInstance
protected <T> MessageListener<T> createMessageListenerInstance(InvocableHandlerMethod handlerMethod) -
createAsyncMessageListenerInstance
protected <T> AsyncMessageListener<T> createAsyncMessageListenerInstance(InvocableHandlerMethod handlerMethod)
-