Reputation: 419
How to get the count of messages in-memory message store in WSO2 ESB?
I want to get the count in XML configuration, like to be used in proxy service or sequence or message processor etc.
I want it to be used in XML.
Upvotes: 0
Views: 330
Reputation: 327
You can use script mediator with this code:
var msg_store = mc.getConfiguration().getMessageStore('YourMessageStoreName')
var log = mc.getServiceLog()
log.info("Current size of Message Store "+msg_store.size())
Upvotes: 1
Reputation: 419
I got it by pushing the message to db and get as per the count required as in this answer of me take a look at my answer
Upvotes: 0