Flow service contextID

I’m working with webMethods 6.0.1 developer and I need to know how to save the context ID of a flow service.
In fact I would like to be able to resubmit the service from WmMonitor, so I need to have the service context Id to retrieve it.
Any help ?
thank you


You can obtain the context ID using this java code:

com.wm.app.b2b.server.InvokeState is = com.wm.app.b2b.server.InvokeState.getCurrentState();
com.wm.app.audit.IAuditRuntime ar = is.getAuditRuntime();
Stirng context = ar.getContextStack();

This gives you the context stack, the first position is your current context id.

Nevertheless, I really don’t understand why you need it… You’ll probably use the service name or service status plus timestamp on your queries.