Uses of Class
dk.cloudcreate.essentials.components.foundation.messaging.queue.Message
-
-
Uses of Message in dk.cloudcreate.essentials.components.foundation.messaging.eip.store_and_forward
Methods in dk.cloudcreate.essentials.components.foundation.messaging.eip.store_and_forward with parameters of type Message Modifier and Type Method Description voidPatternMatchingMessageHandler. accept(Message message)voidInbox. addMessageReceived(Message message)Register or add a message that has been received
This message will be stored durably (without any duplication check) in connection with the currently activeUnitOfWork(or a newUnitOfWorkwill be created in case no there isn't an activeUnitOfWork).
The message will be delivered asynchronously to the message consumervoidInboxes.DurableQueueBasedInboxes.DurableQueueBasedInbox. addMessageReceived(Message message)protected voidPatternMatchingMessageHandler. handleUnmatchedMessage(Message message)Override this method to provide custom handling forMessage's who'sgetPayload()aren't matched
Default behaviour is to throw anIllegalArgumentExceptionunlessPatternMatchingMessageHandler.isAllowUnmatchedMessages()is set to true (default value is false)voidOutbox. sendMessage(Message message)Send a message asynchronously.
This message will be stored durably (without any duplication check) in connection with the currently activeUnitOfWork(or a newUnitOfWorkwill be created in case no there isn't an activeUnitOfWork).
The message will be delivered asynchronously to the message consumervoidOutboxes.DurableQueueBasedOutboxes.DurableQueueBasedOutbox. sendMessage(Message payload)Method parameters in dk.cloudcreate.essentials.components.foundation.messaging.eip.store_and_forward with type arguments of type Message Modifier and Type Method Description InboxInbox. consume(Consumer<Message> messageConsumer)Start consuming messages from the Outbox using the provided message consumer.
Only needs to be called if the instance was created without a message consumerInboxInboxes.DurableQueueBasedInboxes.DurableQueueBasedInbox. consume(Consumer<Message> messageConsumer)OutboxOutbox. consume(Consumer<Message> messageConsumer)Start consuming messages from the Outbox using the provided message consumer.
Only needs to be called if the instance was created without a message consumerOutboxOutboxes.DurableQueueBasedOutboxes.DurableQueueBasedOutbox. consume(Consumer<Message> messageConsumer)InboxInboxes.DurableQueueBasedInboxes. getOrCreateInbox(InboxConfig inboxConfig, Consumer<Message> messageConsumer)InboxInboxes. getOrCreateInbox(InboxConfig inboxConfig, Consumer<Message> messageConsumer)Get an existingInboxinstance or create a new instance.OutboxOutboxes.DurableQueueBasedOutboxes. getOrCreateOutbox(OutboxConfig outboxConfig, Consumer<Message> messageConsumer)OutboxOutboxes. getOrCreateOutbox(OutboxConfig outboxConfig, Consumer<Message> messageConsumer)Get an existingOutboxinstance or create a new instance.Constructor parameters in dk.cloudcreate.essentials.components.foundation.messaging.eip.store_and_forward with type arguments of type Message Constructor Description DurableQueueBasedInbox(InboxConfig config, Consumer<Message> messageConsumer)DurableQueueBasedOutbox(OutboxConfig config, Consumer<Message> messageConsumer) -
Uses of Message in dk.cloudcreate.essentials.components.foundation.messaging.queue
Subclasses of Message in dk.cloudcreate.essentials.components.foundation.messaging.queue Modifier and Type Class Description classOrderedMessageRepresents a message that will be delivered in order.
This of course requires that message are queued in order and that the consumer is single threaded.
All messages sharing the sameOrderedMessage.key, will be delivered according to theirOrderedMessage.order
An example of a message key is the id of the entity the message relates toFields in dk.cloudcreate.essentials.components.foundation.messaging.queue declared as Message Modifier and Type Field Description MessageDefaultQueuedMessage. messageThe deserialized message payloadMethods in dk.cloudcreate.essentials.components.foundation.messaging.queue that return Message Modifier and Type Method Description MessageDefaultQueuedMessage. getMessage()MessageQueuedMessage. getMessage()Get the message queuedstatic MessageMessage. of(Object payload)Create a newMessageand an emptyMessageMetaDatastatic MessageMessage. of(Object payload, MessageMetaData metaData)Create a newMessageMethods in dk.cloudcreate.essentials.components.foundation.messaging.queue with parameters of type Message Modifier and Type Method Description default QueueEntryIdDurableQueues. queueMessage(QueueName queueName, Message message)Queue a message for asynchronous delivery without delay to aDurableQueueConsumer
Note this method MUST be called within an existingUnitOfWorkIF usingTransactionalMode.FullyTransactionaldefault QueueEntryIdDurableQueues. queueMessage(QueueName queueName, Message message, Exception causeOfEnqueuing, Duration deliveryDelay)Queue a message for asynchronous delivery optional delay to aDurableQueueConsumer
Note this method MUST be called within an existingUnitOfWorkIF usingTransactionalMode.FullyTransactionaldefault QueueEntryIdDurableQueues. queueMessage(QueueName queueName, Message message, Duration deliveryDelay)Queue a message for asynchronous delivery optional delay to aDurableQueueConsumer
Note this method MUST be called within an existingUnitOfWorkIF usingTransactionalMode.FullyTransactionaldefault QueueEntryIdDurableQueues. queueMessage(QueueName queueName, Message message, Optional<Exception> causeOfEnqueuing, Optional<Duration> deliveryDelay)Queue a message for asynchronous delivery optional delay to aDurableQueueConsumer
Note this method MUST be called within an existingUnitOfWorkIF usingTransactionalMode.FullyTransactionaldefault QueueEntryIdDurableQueues. queueMessage(QueueName queueName, Message message, Optional<Duration> deliveryDelay)Queue a message for asynchronous delivery optional delay to aDurableQueueConsumer
Note this method MUST be called within an existingUnitOfWorkIF usingTransactionalMode.FullyTransactionaldefault QueueEntryIdDurableQueues. queueMessageAsDeadLetterMessage(QueueName queueName, Message message, Exception causeOfError)Queue the message directly as a Dead Letter Message.Method parameters in dk.cloudcreate.essentials.components.foundation.messaging.queue with type arguments of type Message Modifier and Type Method Description default List<QueueEntryId>DurableQueues. queueMessages(QueueName queueName, List<? extends Message> messages)Queue multiple messages to the same queue.default List<QueueEntryId>DurableQueues. queueMessages(QueueName queueName, List<? extends Message> messages, Duration deliveryDelay)Queue multiple messages to the same queue.default List<QueueEntryId>DurableQueues. queueMessages(QueueName queueName, List<? extends Message> messages, Optional<Duration> deliveryDelay)Queue multiple messages to the same queue.Constructors in dk.cloudcreate.essentials.components.foundation.messaging.queue with parameters of type Message Constructor Description DefaultQueuedMessage(QueueEntryId id, QueueName queueName, Message message, OffsetDateTime addedTimestamp, OffsetDateTime nextDeliveryTimestamp, String lastDeliveryError, int totalDeliveryAttempts, int redeliveryAttempts, boolean isDeadLetterMessage) -
Uses of Message in dk.cloudcreate.essentials.components.foundation.messaging.queue.operations
Fields in dk.cloudcreate.essentials.components.foundation.messaging.queue.operations with type parameters of type Message Modifier and Type Field Description List<? extends Message>QueueMessages. messagesMethods in dk.cloudcreate.essentials.components.foundation.messaging.queue.operations that return Message Modifier and Type Method Description MessageQueueMessage. getMessage()Get the message being queuedMessageQueueMessageAsDeadLetterMessage. getMessage()Get the dead letter messageMethods in dk.cloudcreate.essentials.components.foundation.messaging.queue.operations that return types with arguments of type Message Modifier and Type Method Description List<? extends Message>QueueMessages. getMessages()Methods in dk.cloudcreate.essentials.components.foundation.messaging.queue.operations with parameters of type Message Modifier and Type Method Description voidQueueMessage. setMessage(Message message)voidQueueMessageAsDeadLetterMessage. setMessage(Message message)QueueMessageAsDeadLetterMessageBuilderQueueMessageAsDeadLetterMessageBuilder. setMessage(Message message)QueueMessageBuilderQueueMessageBuilder. setMessage(Message message)Method parameters in dk.cloudcreate.essentials.components.foundation.messaging.queue.operations with type arguments of type Message Modifier and Type Method Description voidQueueMessages. setMessages(List<Message> messages)QueueMessagesBuilderQueueMessagesBuilder. setMessages(List<Message> messages)Constructors in dk.cloudcreate.essentials.components.foundation.messaging.queue.operations with parameters of type Message Constructor Description QueueMessage(QueueName queueName, Message message, Exception causeOfEnqueuing, Duration deliveryDelay)Queue a message for asynchronous delivery optional delay to aDurableQueueConsumer
Note this method MUST be called within an existingUnitOfWorkIF usingTransactionalMode.FullyTransactionalQueueMessage(QueueName queueName, Message message, Optional<Exception> causeOfEnqueuing, Optional<Duration> deliveryDelay)Queue a message for asynchronous delivery optional delay to aDurableQueueConsumer
Note this method MUST be called within an existingUnitOfWorkIF usingTransactionalMode.FullyTransactionalQueueMessageAsDeadLetterMessage(QueueName queueName, Message message, Exception causeOfError)Queue the message directly as a Dead Letter Message.Constructor parameters in dk.cloudcreate.essentials.components.foundation.messaging.queue.operations with type arguments of type Message Constructor Description QueueMessages(QueueName queueName, List<? extends Message> messages, Duration deliveryDelay)Queue multiple messages to the same queue.QueueMessages(QueueName queueName, List<? extends Message> messages, Optional<Duration> deliveryDelay)Queue multiple messages to the same queue.
-