Find your people. Pick a challenge. Ship something real. The CreatorCon Hackathon is coming to the Community Pavilion for one epic night. Every skill level, every role welcome. Join us on May 5th and learn more here.

Read ECC Queue payload

vicy
Kilo Explorer

Hello,

I have written a jar file uploaded on mid server. I am able pass message to write to ecc_queue and update problem object. Also, I am writing pay loads to ecc_queue every time problem is inserted or updated.

What I want to know if there is a way to read ecc_queue payload(xml data) using custom class that are part of jar file and parse the xml file.


Thanks
Vicky

6 REPLIES 6

Sounds like the right kind of flow. I hope this works for you!


Mukesh Sharma
Kilo Guru

Do it this way......

var grQue=new GlideRecord('ecc_queue');
grQue.addQuery('sys_id','443660881b51c4d00d5221be6e4bcb15');
grQue.query();
if(grQue.next())
{
var text =grQue.payload+'';
var xmlhelp = new XMLHelper(text);
var x = xmlhelp.toObject();
gs.print("tag is: " + x.result.stdout);
}