Modifier and Type | Method and Description |
---|---|
Optional<EventMessage<?>> |
DefaultAMQPMessageConverter.readAMQPMessage(byte[] messageBody,
Map<String,Object> headers) |
Optional<EventMessage<?>> |
AMQPMessageConverter.readAMQPMessage(byte[] messageBody,
Map<String,Object> headers)
Reconstruct an EventMessage from the given
messageBody and headers . |
Modifier and Type | Method and Description |
---|---|
AMQPMessage |
DefaultAMQPMessageConverter.createAMQPMessage(EventMessage<?> eventMessage) |
AMQPMessage |
AMQPMessageConverter.createAMQPMessage(EventMessage<?> eventMessage)
Creates an AMQPMessage from given
eventMessage . |
String |
RoutingKeyResolver.resolveRoutingKey(EventMessage<?> eventMessage)
Returns the Routing Key to use when sending the given
eventMessage to the Message Broker. |
String |
PackageRoutingKeyResolver.resolveRoutingKey(EventMessage<?> event) |
Modifier and Type | Method and Description |
---|---|
<T> EventMessage<T> |
EventMessageReader.readEventMessage()
Reads an EventMessage from the underlying input.
|
Modifier and Type | Method and Description |
---|---|
Optional<EventMessage<?>> |
JavaSerializationAMQPMessageConverter.readAMQPMessage(byte[] messageBody,
Map<String,Object> headers) |
Modifier and Type | Method and Description |
---|---|
AMQPMessage |
JavaSerializationAMQPMessageConverter.createAMQPMessage(EventMessage eventMessage) |
static EventMessageType |
EventMessageType.forMessage(EventMessage message)
Returns the most specific EventMessageType for the given
message . |
void |
EventMessageWriter.writeEventMessage(EventMessage eventMessage)
Writes the given
eventMessage to the underling output. |
Modifier and Type | Method and Description |
---|---|
protected void |
SpringAMQPPublisher.send(List<? extends EventMessage<?>> events)
Sends the given
events to the configured AMQP Exchange. |
Registration |
SpringAMQPMessageSource.subscribe(Consumer<List<? extends EventMessage<?>>> messageProcessor) |
Constructor and Description |
---|
SpringAMQPPublisher(SubscribableMessageSource<EventMessage<?>> messageSource)
Initialize this instance to publish message as they are published on the given
messageSource . |
Modifier and Type | Method and Description |
---|---|
static <T extends EventMessage<?>> |
Conflicts.eventMatching(Predicate<? super T> messageFilter)
Returns a
Predicate for a ConflictResolver that responds affirmative if any event in a list of
unseen events matches the given messageFilter . |
Modifier and Type | Method and Description |
---|---|
protected <P> EventMessage<P> |
AnnotatedAggregate.createMessage(P payload,
MetaData metaData)
|
Modifier and Type | Method and Description |
---|---|
protected void |
AnnotatedAggregate.publish(EventMessage<?> msg)
Publish an event to the aggregate root and its entities first and external event handlers (using the given
event bus) later.
|
void |
AnnotatedChildEntity.publish(EventMessage<?> msg,
P declaringInstance) |
void |
ModelInspector.publish(EventMessage<?> message,
T target)
Deprecated.
|
void |
EntityModel.publish(EventMessage<?> message,
T target)
Publish given event
message on the given target entity. |
void |
ChildEntity.publish(EventMessage<?> msg,
T declaringInstance)
Publish the given
msg to the appropriate handlers on the given declaringInstance |
protected void |
AnnotatedAggregate.publishOnEventBus(EventMessage<?> msg)
Publish an event to external event handlers using the given event bus.
|
protected <T> Stream<Object> |
AggregateMemberAnnotatedChildEntityMapDefinition.resolveEventTargets(EventMessage message,
T parentEntity,
Field field,
ForwardingMode eventForwardingMode) |
protected <T> Stream<Object> |
AggregateMemberAnnotatedChildEntityDefinition.resolveEventTargets(EventMessage message,
T parentEntity,
Field field,
ForwardingMode eventForwardingMode) |
protected <T> Stream<Object> |
AggregateMemberAnnotatedChildEntityCollectionDefinition.resolveEventTargets(EventMessage message,
T parentEntity,
Field field,
ForwardingMode eventForwardingMode) |
protected abstract <T> Stream<Object> |
AbstractChildEntityDefinition.resolveEventTargets(EventMessage message,
T parentEntity,
Field field,
ForwardingMode eventForwardingMode)
Resolve the targets of an incoming
EventMessage to the right Child
Entities. |
Constructor and Description |
---|
AnnotatedChildEntity(EntityModel<C> entityModel,
boolean forwardCommands,
BiFunction<CommandMessage<?>,P,C> commandTargetResolver,
BiFunction<EventMessage<?>,P,Stream<C>> eventTargetResolver)
Initiates a new AnnotatedChildEntity instance that uses the provided
entityModel to delegate command
and event handling to an annotated child entity. |
Modifier and Type | Method and Description |
---|---|
List<MessageHandlerInterceptor<? super EventMessage<?>>> |
EventHandlingConfiguration.interceptorsFor(Configuration configuration,
String processorName)
Deprecated.
|
List<MessageHandlerInterceptor<? super EventMessage<?>>> |
EventProcessingConfiguration.interceptorsFor(String processorName)
Returns a list of interceptors for a processor with given
processorName . |
Modifier and Type | Method and Description |
---|---|
SagaConfiguration<S> |
SagaConfiguration.configureMessageMonitor(Function<Configuration,MessageMonitor<? super EventMessage<?>>> messageMonitor)
Deprecated.
|
EventHandlingConfiguration |
EventHandlingConfiguration.registerDefaultSequencingPolicy(Function<Configuration,SequencingPolicy<? super EventMessage<?>>> policyBuilder)
Registers the sequencing policy created by given
policyBuilder to the processing groups for which no
explicit policy is defined (using EventHandlingConfiguration.registerSequencingPolicy(String, Function) ). |
EventHandlingConfiguration |
EventHandlingConfiguration.registerHandlerInterceptor(BiFunction<Configuration,String,MessageHandlerInterceptor<? super EventMessage<?>>> interceptorBuilder)
Deprecated.
|
SagaConfiguration<S> |
SagaConfiguration.registerHandlerInterceptor(Function<Configuration,MessageHandlerInterceptor<? super EventMessage<?>>> handlerInterceptorBuilder)
Deprecated.
|
EventProcessingConfiguration |
EventProcessingConfiguration.registerHandlerInterceptor(String processorName,
Function<Configuration,MessageHandlerInterceptor<? super EventMessage<?>>> interceptorBuilder)
Register the given
interceptorBuilder to build an Message Handling Interceptor for the Event Processor
with given processorName . |
EventHandlingConfiguration |
EventHandlingConfiguration.registerHandlerInterceptor(String processorName,
Function<Configuration,MessageHandlerInterceptor<? super EventMessage<?>>> interceptorBuilder)
Deprecated.
|
EventHandlingConfiguration |
EventHandlingConfiguration.registerSequencingPolicy(String name,
Function<Configuration,SequencingPolicy<? super EventMessage<?>>> policyBuilder)
Registers the sequencing policy created by given
policyBuilder to the processing group with given
name . |
EventProcessingConfiguration |
EventProcessingConfiguration.registerSubscribingEventProcessor(String name,
Function<Configuration,SubscribableMessageSource<? extends EventMessage<?>>> messageSource)
Register a subscribing event processor with given
name that subscribes to the given messageSource . |
EventHandlingConfiguration |
EventHandlingConfiguration.registerSubscribingEventProcessor(String name,
Function<Configuration,SubscribableMessageSource<? extends EventMessage<?>>> messageSource)
Deprecated.
|
EventHandlingConfiguration |
EventHandlingConfiguration.registerTrackingProcessor(String name,
Function<Configuration,StreamableMessageSource<TrackedEventMessage<?>>> source,
Function<Configuration,TrackingEventProcessorConfiguration> processorConfiguration,
Function<Configuration,SequencingPolicy<? super EventMessage<?>>> sequencingPolicy)
Deprecated.
|
EventHandlingConfiguration |
EventHandlingConfiguration.registerTrackingProcessor(String name,
Function<Configuration,TrackingEventProcessorConfiguration> processorConfiguration,
Function<Configuration,SequencingPolicy<? super EventMessage<?>>> sequencingPolicy)
Deprecated.
|
static <S> SagaConfiguration<S> |
SagaConfiguration.subscribingSagaManager(Class<S> sagaType,
Function<Configuration,SubscribableMessageSource<EventMessage<?>>> messageSourceBuilder)
Initialize a configuration for a Saga of given
sagaType , using a Subscribing Event Processor to process
incoming Events from the message source provided by given messageSourceBuilder |
static <S> SagaConfiguration<S> |
SagaConfiguration.subscribingSagaManager(Class<S> sagaType,
Function<Configuration,SubscribableMessageSource<EventMessage<?>>> messageSourceBuilder,
Function<Configuration,EventProcessingStrategy> eventProcessingStrategy)
Initialize a configuration for a Saga of given
sagaType , using a Subscribing Event Processor to process
incoming Events from the message source provided by given messageSourceBuilder . |
static <S> SagaConfiguration<S> |
SagaConfiguration.subscribingSagaManager(Class<S> sagaType,
String processingGroup,
Function<Configuration,SubscribableMessageSource<EventMessage<?>>> messageSourceBuilder,
Function<Configuration,EventProcessingStrategy> eventProcessingStrategy)
Initialize a configuration for a Saga of given
sagaType , using a Subscribing Event Processor (with
provided name) to process incoming Events from the message source provided by given messageSourceBuilder . |
EventHandlingConfiguration |
EventHandlingConfiguration.usingTrackingProcessors(Function<Configuration,TrackingEventProcessorConfiguration> config,
Function<Configuration,SequencingPolicy<? super EventMessage<?>>> sequencingPolicy)
Deprecated.
|
Modifier and Type | Interface and Description |
---|---|
interface |
DeadlineMessage<T>
Represents a Message for a Deadline, specified by its deadline name and optionally containing a deadline payload.
|
Modifier and Type | Class and Description |
---|---|
class |
GenericDeadlineMessage<T>
Generic implementation of the
DeadlineMessage . |
Modifier and Type | Interface and Description |
---|---|
interface |
TrackedEventMessage<T>
Represents an
EventMessage containing a TrackingToken . |
Modifier and Type | Class and Description |
---|---|
class |
GenericEventMessage<T>
Generic implementation of the EventMessage interface.
|
class |
GenericTrackedEventMessage<T>
Generic implementation of a
TrackedEventMessage . |
Modifier and Type | Method and Description |
---|---|
EventMessage<T> |
EventMessage.andMetaData(Map<String,?> metaData)
Returns a copy of this EventMessage with it MetaData merged with the given
metaData . |
static <T> EventMessage<T> |
GenericEventMessage.asEventMessage(Object event)
Returns the given event as an EventMessage.
|
EventMessage<T> |
EventMessage.withMetaData(Map<String,?> metaData)
Returns a copy of this EventMessage with the given
metaData . |
Modifier and Type | Method and Description |
---|---|
List<? extends EventMessage<?>> |
ErrorContext.failedEvents()
The events part of the batch that failed.
|
SequencingPolicy<? super EventMessage<?>> |
SimpleEventHandlerInvoker.getSequencingPolicy() |
protected List<? extends EventMessage<?>> |
AbstractEventBus.intercept(List<? extends EventMessage<?>> events)
Invokes all the dispatch interceptors.
|
protected List<EventMessage<?>> |
AbstractEventBus.queuedMessages()
Returns a list of all the events staged for publication in this Unit of Work.
|
Modifier and Type | Method and Description |
---|---|
default boolean |
EventListener.canHandle(EventMessage<?> event)
Indicates whether this listener can handle the given event message
|
boolean |
AnnotationEventListenerAdapter.canHandle(EventMessage<?> event) |
boolean |
SimpleEventHandlerInvoker.canHandle(EventMessage<?> eventMessage,
Segment segment) |
boolean |
MultiEventHandlerInvoker.canHandle(EventMessage<?> eventMessage,
Segment segment) |
boolean |
EventHandlerInvoker.canHandle(EventMessage<?> eventMessage,
Segment segment)
Check whether or not this invoker has handlers that can handle the given
eventMessage for a given
segment . |
protected boolean |
AbstractEventProcessor.canHandle(EventMessage<?> eventMessage,
Segment segment)
Indicates whether the processor can/should handle the given
eventMessage for the given segment . |
void |
EventListener.handle(EventMessage<?> event)
Process the given event.
|
default void |
EventHandlerInvoker.handle(EventMessage<?> message)
Deprecated.
Callers should use
EventHandlerInvoker.handle(EventMessage, Segment) instead |
void |
AnnotationEventListenerAdapter.handle(EventMessage<?> event) |
void |
SimpleEventHandlerInvoker.handle(EventMessage<?> message,
Segment segment) |
void |
MultiEventHandlerInvoker.handle(EventMessage<?> message,
Segment segment) |
void |
EventHandlerInvoker.handle(EventMessage<?> message,
Segment segment)
Handle the given
message for the given segment . |
void |
ThrowingListenerErrorHandler.onError(Exception exception,
EventMessage<?> event,
EventListener eventListener)
Deprecated.
|
void |
PropagatingErrorHandler.onError(Exception exception,
EventMessage<?> event,
EventListener eventListener) |
void |
LoggingErrorHandler.onError(Exception exception,
EventMessage<?> event,
EventListener eventListener) |
void |
ListenerInvocationErrorHandler.onError(Exception exception,
EventMessage<?> event,
EventListener eventListener)
Invoked after given
eventListener failed to handle given event . |
default void |
EventBus.publish(EventMessage<?>... events)
Publish a collection of events on this bus (one, or multiple).
|
protected void |
AbstractEventProcessor.reportIgnored(EventMessage<?> eventMessage)
Report the given
eventMessage as ignored. |
Modifier and Type | Method and Description |
---|---|
protected void |
SimpleEventBus.afterCommit(List<? extends EventMessage<?>> events) |
protected void |
AbstractEventBus.afterCommit(List<? extends EventMessage<?>> events)
Process given
events after the Unit of Work has been committed. |
protected void |
AbstractEventBus.commit(List<? extends EventMessage<?>> events)
Process given
events while the Unit of Work root is being committed. |
void |
EventProcessingStrategy.handle(List<? extends EventMessage<?>> events,
Consumer<List<? extends EventMessage<?>>> processor)
Handle the given batch of
events . |
void |
EventProcessingStrategy.handle(List<? extends EventMessage<?>> events,
Consumer<List<? extends EventMessage<?>>> processor)
Handle the given batch of
events . |
void |
DirectEventProcessingStrategy.handle(List<? extends EventMessage<?>> events,
Consumer<List<? extends EventMessage<?>>> processor) |
void |
DirectEventProcessingStrategy.handle(List<? extends EventMessage<?>> events,
Consumer<List<? extends EventMessage<?>>> processor) |
protected List<? extends EventMessage<?>> |
AbstractEventBus.intercept(List<? extends EventMessage<?>> events)
Invokes all the dispatch interceptors.
|
protected void |
AbstractEventBus.prepareCommit(List<? extends EventMessage<?>> events)
Process given
events while the Unit of Work root is preparing for commit. |
protected void |
SubscribingEventProcessor.process(List<? extends EventMessage<?>> eventMessages)
Process the given messages.
|
protected void |
AbstractEventProcessor.processInUnitOfWork(List<? extends EventMessage<?>> eventMessages,
UnitOfWork<? extends EventMessage<?>> unitOfWork,
Segment segment)
Process a batch of events.
|
protected void |
AbstractEventProcessor.processInUnitOfWork(List<? extends EventMessage<?>> eventMessages,
UnitOfWork<? extends EventMessage<?>> unitOfWork,
Segment segment)
Process a batch of events.
|
void |
EventBus.publish(List<? extends EventMessage<?>> events)
Publish a collection of events on this bus (one, or multiple).
|
void |
AbstractEventBus.publish(List<? extends EventMessage<?>> events) |
Registration |
EventBus.registerDispatchInterceptor(MessageDispatchInterceptor<? super EventMessage<?>> dispatchInterceptor)
Register the given
interceptor with this bus. |
Registration |
AbstractEventBus.registerDispatchInterceptor(MessageDispatchInterceptor<? super EventMessage<?>> dispatchInterceptor)
Register the given
interceptor with this bus. |
Registration |
EventProcessor.registerInterceptor(MessageHandlerInterceptor<? super EventMessage<?>> interceptor)
Registers the given
interceptor to this event processor. |
Registration |
AbstractEventProcessor.registerInterceptor(MessageHandlerInterceptor<? super EventMessage<?>> interceptor) |
Registration |
AbstractEventBus.subscribe(Consumer<List<? extends EventMessage<?>>> eventProcessor) |
Constructor and Description |
---|
GenericTrackedEventMessage(TrackingToken trackingToken,
EventMessage<T> delegate)
Creates a GenericTrackedEventMessage with given
trackingToken and delegate event message. |
Constructor and Description |
---|
AbstractEventBus(MessageMonitor<? super EventMessage<?>> messageMonitor)
Initializes an event bus.
|
AbstractEventProcessor(String name,
EventHandlerInvoker eventHandlerInvoker,
RollbackConfiguration rollbackConfiguration,
ErrorHandler errorHandler,
MessageMonitor<? super EventMessage<?>> messageMonitor)
Initializes an event processor with given
name . |
ErrorContext(String eventProcessor,
Exception error,
List<? extends EventMessage<?>> failedEvents) |
SimpleEventBus(int queueCapacity,
MessageMonitor<? super EventMessage<?>> messageMonitor)
Initializes an event bus.
|
SimpleEventHandlerInvoker(List<?> eventListeners,
ListenerInvocationErrorHandler listenerInvocationErrorHandler,
SequencingPolicy<? super EventMessage<?>> sequencingPolicy)
Initialize the EventHandlerInvoker to invoke the given
eventListeners , using the given
listenerInvocationErrorHandler when an error occurs invoking these handlers and the given
sequencingPolicy to describe the expected sequencing of event messages |
SimpleEventHandlerInvoker(List<?> eventListeners,
ParameterResolverFactory parameterResolverFactory,
ListenerInvocationErrorHandler listenerInvocationErrorHandler,
SequencingPolicy<? super EventMessage<?>> sequencingPolicy)
Initializes a
SimpleEventHandlerInvoker containing the given list of eventListeners . |
SubscribingEventProcessor(String name,
EventHandlerInvoker eventHandlerInvoker,
RollbackConfiguration rollbackConfiguration,
SubscribableMessageSource<? extends EventMessage<?>> messageSource,
EventProcessingStrategy processingStrategy,
ErrorHandler errorHandler,
MessageMonitor<? super EventMessage<?>> messageMonitor)
Initializes an EventProcessor with given
name that subscribes to the given messageSource for
events. |
SubscribingEventProcessor(String name,
EventHandlerInvoker eventHandlerInvoker,
RollbackConfiguration rollbackConfiguration,
SubscribableMessageSource<? extends EventMessage<?>> messageSource,
EventProcessingStrategy processingStrategy,
ErrorHandler errorHandler,
MessageMonitor<? super EventMessage<?>> messageMonitor)
Initializes an EventProcessor with given
name that subscribes to the given messageSource for
events. |
SubscribingEventProcessor(String name,
EventHandlerInvoker eventHandlerInvoker,
SubscribableMessageSource<? extends EventMessage<?>> messageSource,
EventProcessingStrategy processingStrategy,
ErrorHandler errorHandler,
MessageMonitor<? super EventMessage<?>> messageMonitor)
Initializes an EventProcessor with given
name that subscribes to the given messageSource for
events. |
SubscribingEventProcessor(String name,
EventHandlerInvoker eventHandlerInvoker,
SubscribableMessageSource<? extends EventMessage<?>> messageSource,
EventProcessingStrategy processingStrategy,
ErrorHandler errorHandler,
MessageMonitor<? super EventMessage<?>> messageMonitor)
Initializes an EventProcessor with given
name that subscribes to the given messageSource for
events. |
SubscribingEventProcessor(String name,
EventHandlerInvoker eventHandlerInvoker,
SubscribableMessageSource<EventMessage<?>> messageSource)
Initializes an EventProcessor with given
name that subscribes to the given messageSource for
events. |
SubscribingEventProcessor(String name,
EventHandlerInvoker eventHandlerInvoker,
SubscribableMessageSource<EventMessage<?>> messageSource,
EventProcessingStrategy processingStrategy,
ErrorHandler errorHandler)
Initializes an EventProcessor with given
name that subscribes to the given messageSource for
events. |
TrackingEventProcessor(String name,
EventHandlerInvoker eventHandlerInvoker,
StreamableMessageSource<TrackedEventMessage<?>> messageSource,
TokenStore tokenStore,
TransactionManager transactionManager,
MessageMonitor<? super EventMessage<?>> messageMonitor)
Initializes an EventProcessor with given
name that subscribes to the given messageSource for
events. |
TrackingEventProcessor(String name,
EventHandlerInvoker eventHandlerInvoker,
StreamableMessageSource<TrackedEventMessage<?>> messageSource,
TokenStore tokenStore,
TransactionManager transactionManager,
MessageMonitor<? super EventMessage<?>> messageMonitor,
RollbackConfiguration rollbackConfiguration,
ErrorHandler errorHandler,
TrackingEventProcessorConfiguration config)
Initializes an EventProcessor with given
name that subscribes to the given messageSource for
events. |
Modifier and Type | Method and Description |
---|---|
Object |
SequentialPerAggregatePolicy.getSequenceIdentifierFor(EventMessage event) |
Modifier and Type | Method and Description |
---|---|
void |
AsynchronousEventProcessingStrategy.handle(List<? extends EventMessage<?>> events,
Consumer<List<? extends EventMessage<?>>> processor) |
void |
AsynchronousEventProcessingStrategy.handle(List<? extends EventMessage<?>> events,
Consumer<List<? extends EventMessage<?>>> processor) |
protected void |
AsynchronousEventProcessingStrategy.schedule(List<? extends EventMessage<?>> events,
Consumer<List<? extends EventMessage<?>>> processor)
Schedules this task for execution when all pre-conditions have been met.
|
protected void |
AsynchronousEventProcessingStrategy.schedule(List<? extends EventMessage<?>> events,
Consumer<List<? extends EventMessage<?>>> processor)
Schedules this task for execution when all pre-conditions have been met.
|
boolean |
EventProcessorTask.scheduleEvents(List<? extends EventMessage<?>> events,
Consumer<List<? extends EventMessage<?>>> processor)
Schedules a batch of events for processing.
|
boolean |
EventProcessorTask.scheduleEvents(List<? extends EventMessage<?>> events,
Consumer<List<? extends EventMessage<?>>> processor)
Schedules a batch of events for processing.
|
Constructor and Description |
---|
AsynchronousEventProcessingStrategy(Executor executor,
SequencingPolicy<? super EventMessage<?>> sequencingPolicy)
Initializes a new
AsynchronousEventProcessingStrategy that uses the given executor to execute
event processing tasks and sequencingPolicy that determines if an event may be processed in sequence or
in parallel. |
Modifier and Type | Method and Description |
---|---|
BiFunction<Integer,EventMessage<?>,EventMessage<?>> |
EventLoggingInterceptor.handle(List<? extends EventMessage<?>> messages) |
BiFunction<Integer,EventMessage<?>,EventMessage<?>> |
EventLoggingInterceptor.handle(List<? extends EventMessage<?>> messages) |
Modifier and Type | Method and Description |
---|---|
BiFunction<Integer,EventMessage<?>,EventMessage<?>> |
EventLoggingInterceptor.handle(List<? extends EventMessage<?>> messages) |
Modifier and Type | Method and Description |
---|---|
boolean |
AnnotatedSaga.canHandle(EventMessage<?> event) |
boolean |
AnnotatedSagaManager.canHandle(EventMessage<?> eventMessage,
Segment segment) |
protected Set<AssociationValue> |
AnnotatedSagaManager.extractAssociationValues(EventMessage<?> event) |
protected abstract Set<AssociationValue> |
AbstractSagaManager.extractAssociationValues(EventMessage<?> event)
Extracts the AssociationValues from the given
event as relevant for a Saga of given
sagaType . |
AssociationValue |
SagaMethodMessageHandlingMember.getAssociationValue(EventMessage<?> eventMessage)
The AssociationValue to find the saga instance with, or
null if no AssociationValue can be found on
the given eventMessage . |
protected SagaInitializationPolicy |
AnnotatedSagaManager.getSagaCreationPolicy(EventMessage<?> event) |
protected abstract SagaInitializationPolicy |
AbstractSagaManager.getSagaCreationPolicy(EventMessage<?> event)
Returns the Saga Initialization Policy for a Saga of the given
sagaType and event . |
void |
AnnotatedSaga.handle(EventMessage<?> event) |
void |
AbstractSagaManager.handle(EventMessage<?> event,
Segment segment) |
<T> Object |
PayloadAssociationResolver.resolve(String associationPropertyName,
EventMessage<?> message,
MessageHandlingMember<T> handler)
Finds the association property value in the message's payload.
|
<T> Object |
MetaDataAssociationResolver.resolve(String associationPropertyName,
EventMessage<?> message,
MessageHandlingMember<T> handler)
Finds the association property value by looking up the association property name in the event message's
MetaData . |
<T> Object |
AssociationResolver.resolve(String associationPropertyName,
EventMessage<?> message,
MessageHandlingMember<T> handler)
Resolves the associationPropertyName as a value.
|
Modifier and Type | Method and Description |
---|---|
List<MessageHandlingMember<? super T>> |
SagaModel.findHandlerMethods(EventMessage<?> event)
Returns a
List of MessageHandlingMember that can handle the given event. |
default boolean |
SagaModel.hasHandlerMethod(EventMessage<?> eventMessage)
Indicates whether the Saga described by this model has a handler for the given
eventMessage |
Optional<AssociationValue> |
SagaModel.resolveAssociation(EventMessage<?> eventMessage)
|
Modifier and Type | Method and Description |
---|---|
protected org.quartz.JobDetail |
QuartzEventScheduler.buildJobDetail(EventMessage event,
org.quartz.JobKey jobKey)
Builds the JobDetail instance for Quartz, which defines the Job that needs to be executed when the trigger
fires.
|
Modifier and Type | Interface and Description |
---|---|
interface |
DomainEventMessage<T>
Represents a Message that wraps a DomainEvent and an Event representing an important change in the Domain.
|
Modifier and Type | Class and Description |
---|---|
class |
GenericDomainEventMessage<T>
Generic implementation of a
DomainEventMessage . |
class |
GenericTrackedDomainEventMessage<T>
Generic implementation of a
DomainEventMessage that is also a TrackedEventMessage . |
Modifier and Type | Method and Description |
---|---|
void |
FilteringEventStorageEngine.appendEvents(EventMessage<?>... events) |
void |
SnapshotTrigger.eventHandled(EventMessage<?> msg)
Invoked when an event is handled by an aggregate.
|
protected void |
EventSourcedAggregate.publish(EventMessage<?> msg) |
protected void |
EventSourcedAggregate.publishOnEventBus(EventMessage<?> msg) |
Modifier and Type | Method and Description |
---|---|
void |
FilteringEventStorageEngine.appendEvents(List<? extends EventMessage<?>> events) |
Constructor and Description |
---|
FilteringEventStorageEngine(EventStorageEngine delegate,
Predicate<? super EventMessage<?>> filter)
Initializes the FilteringEventStorageEngine delegating all event messages matching the given
filter to
the given delegate . |
Modifier and Type | Method and Description |
---|---|
default void |
EventStorageEngine.appendEvents(EventMessage<?>... events)
Append one or more events to the event storage.
|
static <T> DomainEventMessage<T> |
EventUtils.asDomainEventMessage(EventMessage<T> eventMessage)
Convert a plain
EventMessage to a DomainEventMessage . |
static <T> TrackedEventMessage<T> |
EventUtils.asTrackedEventMessage(EventMessage<T> eventMessage,
TrackingToken trackingToken)
|
protected void |
AbstractEventStorageEngine.handlePersistenceException(Exception exception,
EventMessage<?> failedEvent)
Invoke when an Exception is raised while persisting an Event or Snapshot.
|
Modifier and Type | Method and Description |
---|---|
protected void |
EmbeddedEventStore.afterCommit(List<? extends EventMessage<?>> events) |
void |
SequenceEventStorageEngine.appendEvents(List<? extends EventMessage<?>> events) |
void |
EventStorageEngine.appendEvents(List<? extends EventMessage<?>> events)
Append a list of events to the event storage.
|
void |
AbstractEventStorageEngine.appendEvents(List<? extends EventMessage<?>> events) |
protected abstract void |
AbstractEventStorageEngine.appendEvents(List<? extends EventMessage<?>> events,
Serializer serializer)
Append given
events to the backing database. |
protected void |
AbstractEventStore.prepareCommit(List<? extends EventMessage<?>> events) |
Constructor and Description |
---|
AbstractEventEntry(EventMessage<?> eventMessage,
Serializer serializer,
Class<T> contentType)
Construct a new event entry from a published event message to enable storing the event or sending it to a remote
location.
|
Constructor and Description |
---|
AbstractEventStore(EventStorageEngine storageEngine,
MessageMonitor<? super EventMessage<?>> messageMonitor)
Initializes an event store with given
storageEngine and messageMonitor . |
EmbeddedEventStore(EventStorageEngine storageEngine,
MessageMonitor<? super EventMessage<?>> monitor)
|
EmbeddedEventStore(EventStorageEngine storageEngine,
MessageMonitor<? super EventMessage<?>> monitor,
int cachedEvents,
long fetchDelay,
long cleanupDelay,
TimeUnit timeUnit)
|
Modifier and Type | Method and Description |
---|---|
void |
InMemoryEventStorageEngine.appendEvents(List<? extends EventMessage<?>> events) |
Modifier and Type | Method and Description |
---|---|
protected void |
JdbcEventStorageEngine.appendEvents(List<? extends EventMessage<?>> events,
Serializer serializer) |
Modifier and Type | Method and Description |
---|---|
protected Object |
JpaEventStorageEngine.createEventEntity(EventMessage<?> eventMessage,
Serializer serializer)
Returns a Jpa event entity for given
eventMessage . |
Modifier and Type | Method and Description |
---|---|
protected void |
JpaEventStorageEngine.appendEvents(List<? extends EventMessage<?>> events,
Serializer serializer) |
Modifier and Type | Method and Description |
---|---|
Optional<EventMessage<?>> |
KafkaMessageConverter.readKafkaMessage(org.apache.kafka.clients.consumer.ConsumerRecord<K,V> consumerRecord)
Reconstruct an EventMessage from the given
ConsumerRecord . |
Optional<EventMessage<?>> |
DefaultKafkaMessageConverter.readKafkaMessage(org.apache.kafka.clients.consumer.ConsumerRecord<String,byte[]> consumerRecord) |
Modifier and Type | Method and Description |
---|---|
org.apache.kafka.clients.producer.ProducerRecord<K,V> |
KafkaMessageConverter.createKafkaMessage(EventMessage<?> eventMessage,
String topic)
Creates
ProducerRecord for a given EventMessage |
org.apache.kafka.clients.producer.ProducerRecord<String,byte[]> |
DefaultKafkaMessageConverter.createKafkaMessage(EventMessage<?> eventMessage,
String topic) |
static org.apache.kafka.common.header.Headers |
HeaderUtils.toHeaders(EventMessage<?> eventMessage,
SerializedObject<byte[]> serializedObject,
BiFunction<String,Object,org.apache.kafka.common.header.internals.RecordHeader> headerValueMapper)
|
Constructor and Description |
---|
DefaultKafkaMessageConverter(Serializer serializer,
SequencingPolicy<? super EventMessage<?>> sequencingPolicy,
BiFunction<String,Object,org.apache.kafka.common.header.internals.RecordHeader> headerValueMapper)
Initializes the KafkaMessageConverter with the given
serializer , sequencingPolicy and
objectMapper . |
Modifier and Type | Method and Description |
---|---|
static KafkaEventMessage |
KafkaEventMessage.from(EventMessage<?> eventMessage,
org.apache.kafka.clients.consumer.ConsumerRecord<?,?> record,
KafkaTrackingToken token) |
Modifier and Type | Method and Description |
---|---|
MessageMonitor<? super EventMessage<?>> |
KafkaPublisherConfiguration.getMessageMonitor() |
SubscribableMessageSource<EventMessage<?>> |
KafkaPublisherConfiguration.getMessageSource() |
Modifier and Type | Method and Description |
---|---|
protected void |
KafkaPublisher.send(List<? extends EventMessage<?>> events)
Send
events to the configured Kafka topic . |
KafkaPublisherConfiguration.Builder<K,V> |
KafkaPublisherConfiguration.Builder.withMessageMonitor(MessageMonitor<? super EventMessage<?>> messageMonitor)
Configure
MessageMonitor . |
KafkaPublisherConfiguration.Builder<K,V> |
KafkaPublisherConfiguration.Builder.withMessageSource(SubscribableMessageSource<EventMessage<?>> messageSource)
Configure
SubscribableMessageSource . |
Modifier and Type | Method and Description |
---|---|
static Map<String,Object> |
Headers.defaultHeaders(EventMessage<?> message,
SerializedObject<?> serializedObject)
Generate defaults headers to recognise an event message.
|
Modifier and Type | Method and Description |
---|---|
MessageMonitor<? super EventMessage<?>> |
GlobalMetricRegistry.registerEventBus(String name)
Registers new metrics to the registry to monitor an
EventBus . |
MessageMonitor<? super EventMessage<?>> |
GlobalMetricRegistry.registerEventProcessor(String eventProcessorName)
Registers new metrics to the registry to monitor an
EventProcessor . |
Modifier and Type | Method and Description |
---|---|
MessageMonitor.MonitorCallback |
EventProcessorLatencyMonitor.onMessageIngested(EventMessage<?> message) |
Modifier and Type | Method and Description |
---|---|
protected void |
MongoEventStorageEngine.appendEvents(List<? extends EventMessage<?>> events,
Serializer serializer) |
void |
StorageStrategy.appendEvents(com.mongodb.client.MongoCollection<org.bson.Document> eventCollection,
List<? extends EventMessage<?>> events,
Serializer serializer)
Appends the given list of
events to the given eventCollection . |
void |
AbstractMongoEventStorageStrategy.appendEvents(com.mongodb.client.MongoCollection<org.bson.Document> eventCollection,
List<? extends EventMessage<?>> events,
Serializer serializer) |
protected abstract Stream<org.bson.Document> |
AbstractMongoEventStorageStrategy.createEventDocuments(List<? extends EventMessage<?>> events,
Serializer serializer)
Returns a stream of Mongo documents that represent the given batch of events.
|
Modifier and Type | Method and Description |
---|---|
protected Stream<org.bson.Document> |
DocumentPerCommitStorageStrategy.createEventDocuments(List<? extends EventMessage<?>> events,
Serializer serializer) |
Modifier and Type | Method and Description |
---|---|
protected Stream<org.bson.Document> |
DocumentPerEventStorageStrategy.createEventDocuments(List<? extends EventMessage<?>> events,
Serializer serializer) |
Modifier and Type | Method and Description |
---|---|
<T> EventMessage<T> |
EventMessageConverter.convertFromInboundMessage(org.springframework.messaging.Message<T> message)
Converts a Spring inbound
message into an Axon event Message |
<T> EventMessage<T> |
DefaultEventMessageConverter.convertFromInboundMessage(org.springframework.messaging.Message<T> message) |
protected EventMessage<?> |
InboundEventMessageChannelAdapter.transformMessage(org.springframework.messaging.Message<?> message)
Transforms the given incoming Spring Messaging
message to an Axon EventMessage. |
Modifier and Type | Method and Description |
---|---|
protected org.springframework.context.ApplicationEvent |
ApplicationContextEventPublisher.convert(EventMessage<?> eventMessage)
Converts the given Axon
eventMessage to a Spring ApplicationEvent. |
<T> org.springframework.messaging.Message<T> |
EventMessageConverter.convertToOutboundMessage(EventMessage<T> event)
Converts Axon
event into Spring message. |
<T> org.springframework.messaging.Message<T> |
DefaultEventMessageConverter.convertToOutboundMessage(EventMessage<T> event) |
protected org.springframework.messaging.Message<?> |
OutboundEventMessageChannelAdapter.transform(EventMessage<?> event)
Transforms the given Axon
event into a Spring Messaging Message. |
Modifier and Type | Method and Description |
---|---|
protected void |
OutboundEventMessageChannelAdapter.handle(List<? extends EventMessage<?>> events)
If allows by the filter, wraps the given
event in a GenericMessage ands sends it to the
configured MessageChannel . |
Registration |
InboundEventMessageChannelAdapter.subscribe(Consumer<List<? extends EventMessage<?>>> messageProcessor) |
Constructor and Description |
---|
ApplicationContextEventPublisher(SubscribableMessageSource<? extends EventMessage<?>> messageSource)
Initialize the publisher to forward events received from the given
messageSource to the application
context that this bean is part of. |
InboundEventMessageChannelAdapter(List<Consumer<List<? extends EventMessage<?>>>> processors,
EventMessageConverter eventMessageConverter)
Initialize the adapter to publish all incoming events to the subscribed processors.
|
OutboundEventMessageChannelAdapter(SubscribableMessageSource<EventMessage<?>> messageSource,
org.springframework.messaging.MessageChannel channel)
Initialize an adapter to forward messages from the given
messageSource to the given channel . |
OutboundEventMessageChannelAdapter(SubscribableMessageSource<EventMessage<?>> messageSource,
org.springframework.messaging.MessageChannel channel,
Predicate<? super EventMessage<?>> filter)
Initialize an adapter to forward messages from the given
messageSource to the given channel . |
OutboundEventMessageChannelAdapter(SubscribableMessageSource<EventMessage<?>> messageSource,
org.springframework.messaging.MessageChannel channel,
Predicate<? super EventMessage<?>> filter)
Initialize an adapter to forward messages from the given
messageSource to the given channel . |
OutboundEventMessageChannelAdapter(SubscribableMessageSource<EventMessage<?>> messageSource,
org.springframework.messaging.MessageChannel channel,
Predicate<? super EventMessage<?>> filter,
EventMessageConverter eventMessageConverter)
Initialize an adapter to forward messages from the given
messageSource to the given channel . |
OutboundEventMessageChannelAdapter(SubscribableMessageSource<EventMessage<?>> messageSource,
org.springframework.messaging.MessageChannel channel,
Predicate<? super EventMessage<?>> filter,
EventMessageConverter eventMessageConverter)
Initialize an adapter to forward messages from the given
messageSource to the given channel . |
Modifier and Type | Method and Description |
---|---|
List<EventMessage<?>> |
StubAggregateLifecycle.getAppliedEvents()
Returns the list of applied Events for this lifecycle instance.
|
Modifier and Type | Method and Description |
---|---|
ResultValidator<T> |
ResultValidatorImpl.expectEvents(EventMessage... expectedEvents) |
ResultValidator<T> |
ResultValidator.expectEvents(EventMessage... expectedEvents)
Expect the given set of events to have been published.
|
Modifier and Type | Method and Description |
---|---|
ResultValidator<T> |
ResultValidatorImpl.expectEventsMatching(org.hamcrest.Matcher<? extends List<? super EventMessage<?>>> matcher) |
ResultValidator<T> |
ResultValidator.expectEventsMatching(org.hamcrest.Matcher<? extends List<? super EventMessage<?>>> matcher)
Expect the published events to match the given
matcher . |
Constructor and Description |
---|
ResultValidatorImpl(List<EventMessage<?>> publishedEvents,
FieldFilter fieldFilter,
Supplier<Aggregate<T>> aggregateState,
StubDeadlineManager stubDeadlineManager)
Initialize the ResultValidatorImpl with the given
storedEvents and publishedEvents . |
Modifier and Type | Method and Description |
---|---|
EventMessage |
StubEventScheduler.advanceToNextTrigger()
Advances the "current time" of the scheduler to the next scheduled Event, and returns that event.
|
EventMessage |
StubScheduleToken.getEvent() |
EventMessage |
ScheduledItem.getEvent()
The Event scheduled for publication.
|
Modifier and Type | Method and Description |
---|---|
void |
StubEventScheduler.advanceTimeBy(Duration duration,
EventConsumer<EventMessage<?>> eventConsumer)
Advance time by the given
duration and invokes the given eventConsumer for each
event scheduled for publication until that time. |
void |
StubEventScheduler.advanceTimeTo(Instant newDateTime,
EventConsumer<EventMessage<?>> eventConsumer)
Advance time to the given
newDateTime and invokes the given eventConsumer for each
event scheduled for publication until that time. |
Modifier and Type | Method and Description |
---|---|
static org.hamcrest.Matcher<List<EventMessage<?>>> |
Matchers.noEvents()
Matches an empty List of Events.
|
Modifier and Type | Method and Description |
---|---|
void |
EventValidator.handle(EventMessage event) |
protected void |
SagaTestFixture.handleInSaga(EventMessage<?> event)
Handles the given
event in the scope of a Unit of Work. |
Modifier and Type | Method and Description |
---|---|
FixtureExecutionResult |
FixtureExecutionResultImpl.expectPublishedEventsMatching(org.hamcrest.Matcher<? extends List<? super EventMessage<?>>> matcher) |
FixtureExecutionResult |
FixtureExecutionResult.expectPublishedEventsMatching(org.hamcrest.Matcher<? extends List<? super EventMessage<?>>> matcher)
Assert that the saga published events on the EventBus as defined by the given
matcher . |
FixtureExecutionResult |
FixtureExecutionResultImpl.expectScheduledEventMatching(Duration duration,
org.hamcrest.Matcher<? super EventMessage<?>> matcher) |
FixtureExecutionResult |
FixtureExecutionResult.expectScheduledEventMatching(Duration duration,
org.hamcrest.Matcher<? super EventMessage<?>> matcher)
Asserts that an event matching the given
matcher has been scheduled to be published after the given
duration . |
FixtureExecutionResult |
FixtureExecutionResultImpl.expectScheduledEventMatching(Instant scheduledTime,
org.hamcrest.Matcher<? super EventMessage<?>> matcher) |
FixtureExecutionResult |
FixtureExecutionResult.expectScheduledEventMatching(Instant scheduledTime,
org.hamcrest.Matcher<? super EventMessage<?>> matcher)
Asserts that an event matching the given
matcher has been scheduled to be published at the given
scheduledTime . |
Copyright © 2010–2018. All rights reserved.