Created by: Martin Sloan on 21-03-2012 05:39:23 PM Hello, I've been working with the CUCM Admin XML using Perl with SOAP::Lite and have gotten fairly familiar with the it but recently received a request to gather registration status for the devices in the cluster and now I'm looking toward hopefully gathering the data from RIS. I have a basic script to request the registration but it's failing with "SimpleDeserializer encountered a child element, which is NOT expected, in something it was trying to deserialize." While I'm still searching the net to decode what this could mean in my situation (and checking traces), I thought I'd post here to see if anyone has some suggestions for a noob. The CUCM version is 8.5.1. Here's a look at the message and response from the CUCM: Message: <?xml version="1.0" encoding="UTF-8"?> <soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" soap:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"> <soap:Body> <SelectCmDevice xmlns="http://schemas.cisco.com/ast/soap/"> <CmSelectionCriteria> <Model xsi:type="xsd:int">404</Model> <Status xsi:type="xsd:string">Any</Status> <Class xsi:type="xsd:string">Any</Class> <MaxReturnedDevices xsi:type="xsd:int">200</MaxReturnedDevices> </CmSelectionCriteria> </SelectCmDevice> </soap:Body> </soap:Envelope>
Response: soapenv:Server.userException, org.xml.sax.SAXException: SimpleDeserializer encountered a child element, which is NOT expected, in something it was trying to deserialize. Thanks, Marty
Subject: RE: Device Registration Status with Perl and SOAP::Lite Replied by: David Staudt on 27-03-2012 11:40:19 AM It's possible Risport does not like the order of the elements in the CmSelectionCriteria - the WSDL defines a sequence such as the following (tested on my UCM 8.5(1) system <soapenv:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ris="http://ccm.cisco.com/serviceability/soap/risport70/"> <soapenv:Body> <SelectCmDevice> <CmSelectionCriteria> <MaxReturnedDevices>200</MaxReturnedDevices> <Class>Any</Class> <Model>255</Model> <Status>Any</Status> <SelectBy>Name</SelectBy> <SelectItems> <Item>*</Item> </SelectItems> </CmSelectionCriteria> </SelectCmDevice> </soapenv:Body> </soapenv:Envelope>
Subject: RE: Device Registration Status with Perl and SOAP::Lite Replied by: Martin Sloan on 27-03-2012 03:21:07 PM David,
Thanks for the info, much appreciated! I ended up giving LWP a shot instead of SOAP Lite and was able to get it working. Sometimes SOAP Lite can be a little too abstract for me and so I wasn't able to mold the request just right.
Thanks again,
Marty
Subject: RE: Device Registration Status with Perl and SOAP::Lite Replied by: Tim Lowrey on 28-06-2012 01:19:15 AM Hi David, I just got the same request. Need to get the Device / current IP address of every device on my cluster(s). Just curious, did you get similar with Perl:LWP? Did you just walk CUCM Administration webpages or something else? Thanks, Tim
Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community: