final class JmsConsumerStage extends GraphStage[SourceShape[FlowEnvelope]]
The JmsSource realizes an inbound Stream of FlowMessages consumed from a given JMS destination. The messages can be consumed using an arbitrary sink of FlowMessages. The sink must acknowledge or deny the message eventually. If the message is not acknowledged with a given time frame, the message will be denied and eventually redelivered.
A JMS session will only consume one message at a time, the next message will be consumed only after the previous message of that session has been denied or acknowledged. The messages that are waiting for acknowledgement are maintained within a map of (session-id / inflight messages).
Any exception while consuming a message within a session will cause that session to close, so that any inflight messages for that session will be redelivered. A new session will be created automatically for any sessions that have been closed with such an exception.
One of the use cases is a retry pattern. In that pattern the message must remain in the underlying destination for a minimum amount of time (i.e. 5 seconds). The message receive loop will check the JMSTimestamp against the System.currentTimeMillis to check whether a message can be passed downstream already.
- Alphabetic
- By Inheritance
- JmsConsumerStage
- GraphStage
- GraphStageWithMaterializedValue
- Graph
- AnyRef
- Any
- Hide All
- Show All
- Public
- Protected
Instance Constructors
- new JmsConsumerStage(name: String, consumerSettings: JmsConsumerSettings, minMessageDelay: Option[FiniteDuration] = None)(implicit actorSystem: ActorSystem)
Type Members
- type Shape = SourceShape[FlowEnvelope]
- Definition Classes
- Graph
Value Members
- final def !=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def ##: Int
- Definition Classes
- AnyRef → Any
- final def ==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- def addAttributes(attr: Attributes): Graph[SourceShape[FlowEnvelope], NotUsed]
- Definition Classes
- Graph
- final def asInstanceOf[T0]: T0
- Definition Classes
- Any
- def async(dispatcher: String, inputBufferSize: Int): Graph[SourceShape[FlowEnvelope], NotUsed]
- Definition Classes
- Graph
- def async(dispatcher: String): Graph[SourceShape[FlowEnvelope], NotUsed]
- Definition Classes
- Graph
- def async: Graph[SourceShape[FlowEnvelope], NotUsed]
- Definition Classes
- Graph
- def clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.CloneNotSupportedException]) @native()
- def createLogic(inheritedAttributes: Attributes): GraphStageLogic
- Definition Classes
- JmsConsumerStage → GraphStage
- final def createLogicAndMaterializedValue(inheritedAttributes: Attributes): (GraphStageLogic, NotUsed)
- Definition Classes
- GraphStage → GraphStageWithMaterializedValue
- final def eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- def equals(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef → Any
- def finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.Throwable])
- final def getClass(): Class[_ <: AnyRef]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
- def hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
- def initialAttributes: Attributes
- Attributes
- protected
- Definition Classes
- GraphStageWithMaterializedValue
- final def isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- def named(name: String): Graph[SourceShape[FlowEnvelope], NotUsed]
- Definition Classes
- Graph
- final def ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- final def notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- final def notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- val shape: SourceShape[FlowEnvelope]
- Definition Classes
- JmsConsumerStage → Graph
- final def synchronized[T0](arg0: => T0): T0
- Definition Classes
- AnyRef
- def toString(): String
- Definition Classes
- AnyRef → Any
- final def wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException]) @native()
- final def withAttributes(attr: Attributes): Graph[SourceShape[FlowEnvelope], NotUsed]
- Definition Classes
- GraphStageWithMaterializedValue → Graph