public interface JmsTupleProducer extends Serializable
Interface to define classes that can produce a Storm Values
objects from a javax.jms.Message
object>.
Implementations are also responsible for declaring the output fields they produce.
If for some reason the implementation can’t process a message (for example if it received a javax.jms.ObjectMessage
when it was expecting a javax.jms.TextMessage
it should return null
to indicate to the JmsSpout
that the message could not be processed.
Modifier and Type | Method and Description |
---|---|
void |
declareOutputFields(OutputFieldsDeclarer declarer)
Declare the output fields produced by this JmsTupleProducer.
|
Values |
toTuple(javax.jms.Message msg)
Process a JMS message object to create a Values object.
|
Values toTuple(javax.jms.Message msg) throws javax.jms.JMSException
Process a JMS message object to create a Values object.
msg
- javax.jms.JMSException
void declareOutputFields(OutputFieldsDeclarer declarer)
Declare the output fields produced by this JmsTupleProducer.
declarer
- The OuputFieldsDeclarer for the spout.Copyright © 2020 The Apache Software Foundation. All rights reserved.