Package com.axemble.vdoc.sdk.interfaces
Interface IJMSMessageProcessor<M extends IJMSMessage>
public interface IJMSMessageProcessor<M extends IJMSMessage>
-
Method Summary
Modifier and TypeMethodDescriptiondefault voidInvoked after processing the message batchdefault voidInvoked before processing the message batchdefault intReturn the batch size for message processingdefault StringReturn the filter/discriminant if needs.default IntegerReturn the number of parallel consumers to rundefault IntegerReturn the timeout to process a unique message.voidprocessMessage(M message) Invoked to process a message
-
Method Details
-
getMessageFilter
Return the filter/discriminant if needs. If not return null This filter only apply on message properties Example : "JMSType = 'car' AND color = 'blue' AND weight > 2500"- Returns:
- the filter or null if none
-
getBatchSize
default int getBatchSize()Return the batch size for message processing- Returns:
- the batch size
-
getPerMessageSecondTimeout
Return the timeout to process a unique message. If return is null then the default timeout is applied- Returns:
- the timeout to process a message
-
getNumberOfParallelConsumers
Return the number of parallel consumers to run- Returns:
- the number of parallel consumers to run
-
beforeProcessMessages
default void beforeProcessMessages()Invoked before processing the message batch -
processMessage
Invoked to process a message- Parameters:
message- the message to process
-
afterProcessMessages
default void afterProcessMessages()Invoked after processing the message batch
-