Class JDBCProducer
- java.lang.Object
-
- org.apache.synapse.message.store.impl.jdbc.JDBCProducer
-
- All Implemented Interfaces:
MessageProducer
public class JDBCProducer extends Object implements MessageProducer
JDBC Store Producer
-
-
Constructor Summary
Constructors Constructor Description JDBCProducer(JDBCMessageStore store)Initialize producer
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleancleanup()Cleanup the producerStringgetId()Get producer idvoidsetId(int id)Set producer idbooleanstoreMessage(MessageContext synCtx)Add a message to the end of the table.
-
-
-
Constructor Detail
-
JDBCProducer
public JDBCProducer(JDBCMessageStore store)
Initialize producer- Parameters:
store- - JDBC message store
-
-
Method Detail
-
storeMessage
public boolean storeMessage(MessageContext synCtx)
Add a message to the end of the table. If fetching success return true else false- Specified by:
storeMessagein interfaceMessageProducer- Parameters:
synCtx- message to insert- Returns:
- - success/failure of fetching
-
cleanup
public boolean cleanup()
Cleanup the producer- Specified by:
cleanupin interfaceMessageProducer- Returns:
- true Since no producer specific things
-
setId
public void setId(int id)
Set producer id- Specified by:
setIdin interfaceMessageProducer- Parameters:
id- ID
-
getId
public String getId()
Get producer id- Specified by:
getIdin interfaceMessageProducer- Returns:
- producerId - Producer identifier
-
-