UpdateLine in 4.2.3

Version 1
    This document was generated from CDN thread

    Created by: sat R on 22-06-2009 03:32:39 PM
    Hi,
     
    My objective is to clear the call forward for the given destination + partition. Following is the request I am sending to the server
     
    <SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope">
        <SOAP-ENV:Body>
            <updateLine xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" sequence="23434"

    xmlns="http://www.cisco.com/AXL/API/1.0">
                3637056
                <routePartitionName xmlns="">01-General OnNet</routePartitionName>
                <routeFilterName xmlns="" />
                <newRoutePartitionId xmlns="" />
                <aarNeighborhoodId xmlns="" />
                <callForwardAll xmlns="">
                    <forwardToVoiceMail>false</forwardToVoiceMail>
                    <callingSearchSpaceName /><destination />
                </callForwardAll>
                <callForwardBusy xsi:nil="true" xmlns="" />
                <callForwardBusyInt xsi:nil="true" xmlns="" />
                <callForwardNoAnswer xsi:nil="true" xmlns="" />
                <callForwardNoAnswerInt xsi:nil="true" xmlns="" />
                <callForwardNoCoverage xsi:nil="true" xmlns="" />
                <callForwardNoCoverageInt xsi:nil="true" xmlns="" />
                <alertingName xmlns="" />
                <shareLineAppearanceCSSId xmlns="" />
                <voiceMailProfileId xmlns="" />
            </updateLine>
        </SOAP-ENV:Body>
    </SOAP-ENV:Envelope>
     
     
    The server is always responding with
     
    <SOAP-ENV:Envelope  xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"

    SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"><SOAP-ENV:Body><SOAP-ENV:Fault><faultcode>SOAP-ENV:Client</faultcode><faultstring><![CDATA[Duplicate value not

    allowed]]></faultstring><detail  xmlns:axl="http://www.cisco.com/AXL/API/1.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"

    xsi:schemaLocation="http://www.cisco.com/AXL/API/1.0 http://USNJPAR1ADMS01/CCMApi/AXL/V1/axlsoap.xsd">    <axl:error  sequence="23434">        <code>23</code>        <message>   

            <![CDATA[Duplicate value not allowed]]>
            </message>        <request>
                updateLine
            </request>    </axl:error></detail></SOAP-ENV:Fault></SOAP-ENV:Body></SOAP-ENV:Envelope>
     
     
    Can somebody help to figure out the reason for error response?

    Subject: RE: UpdateLine in 4.2.3
    Replied by: Stephan Steiner on 23-06-2009 03:16:59 PM
    Is there a particular reason you're specifying an empty xml namespace for each element? And what about the xsi:nil=true tags?
     
    Also, you specify a routeFilterName but route filter doesn't apply to directory numbers so we should never see that there (not sure what autogenerated code makes of it though but I know that route filters only apply to translation patterns and route patterns)
     
    Finally.. since you specify a partition, I presume you mean to select the directory number by pattern and partition. Is 3637056 your directory number in partition 01-General OnNet? If so, where's the pattern tag around 3637056 ? If not.. where's your uuid that uniquely identifies the directory number?

    Subject: RE: UpdateLine in 4.2.3
    Replied by: sat R on 24-06-2009 08:43:22 AM
    It is typo mistake. The pattern should be "< pattern xmlns="">3637056< /pattern>".
     
    For UpdateLine, we should either specify UUID or the
    combination of PATTERN + ROUTE PARTITION + ROUTE FILTER to uniquely
    identify the directory number. Since this DirectoryNumber 3637056 in
    Partition 01-General OnNet, I gave the combination of Partition, Route
    Partition and Route Filter.
     
    Either be the UUID or the combination of those pattern + route partition + route filter, we are always getting the duplicate entries are not allowed error response from the server.

    Subject: RE: UpdateLine in 4.2.3
    Replied by: Stephan Steiner on 24-06-2009 03:53:38 PM
    I haven't tested this myself, but what if you send the following command instead:
     
    <SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope">
        <SOAP-ENV:Body>
            <updateLine xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" sequence="23434"
    xmlns="http://www.cisco.com/AXL/API/1.0">
                3637056
                <routePartitionName>01-General OnNet</routePartitionName>
                <callForwardAll>
                    <forwardToVoiceMail>false</forwardToVoiceMail>
                    <callingSearchSpaceName /><destination />
                </callForwardAll>
            </updateLine>
        </SOAP-ENV:Body>
    </SOAP-ENV:Envelope>
     
    No namespaces and the minimum information required for the command to succeed.
     
    With regards to your original AXL request - it contained
     
    <newRoutePartitionId xmlns="" />
     
    If you have either newRoutePartitionId or newRoutePartitionName, you're effectively changing the partition of your directory number. I have never tried it with using the uuid (in the update case, uuids are used in all tags that end in Id), but with the name, it's empty name = none.. so I suspect you'd be changing the DN 3637056/01-General OnNet to 3637056/<None> which is probably not what you want.. and if you check the directory numbers.. do you not maybe already have a 3637056/<None> ? I know such errors happen to me frequently when I'm developing something new (supporting new CCM objects).. I work on something, it doesn't quite work out but some things have been done and then suddenly I end up with duplicates and I wonder why CCM tells me there's already an object.

    Subject: RE: UpdateLine in 4.2.3
    Replied by: sat R on 25-06-2009 05:10:34 AM
    Thanks Stephen,
     
    I have tested as per your suggestion and it worked as expected. Since there is a need to perform multiple update line functionalities in different function calls, I created a common updateLine class which basically sends the "newPartitionName" and "aarNeighbourhoodName". I changed the code to send out the updateLine soap message without newPartitionName and aarNeighbourhoodName (though not knowing what is mean by neighbourhood I have sent it ).
     
    <SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope">
        <SOAP-ENV:Body>
            <updateLine xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="http://www.cisco.com/AXL/API/1.0">
                <uuid>{99F64048-D5BF-4036-AD4A-86AF54AD0B5D}</uuid>
                <callForwardAll>
                    <forwardToVoiceMail>false</forwardToVoiceMail>
                    <callingSearchSpaceName />
                    <destination>6013637056</destination>
                    <duration />
                </callForwardAll>
            </updateLine>
        </SOAP-ENV:Body>
    </SOAP-ENV:Envelope>
     
    Also the other requirement is to change the partition for the given directory number. Since there is an option of newRoutePartitionName in the updateLine, my guess is changing the partition in the updateLine should be technically possible. But even for this, server always responds with the "duplicate values are not allowed".
     
    I tried almost most of the combinations like:
     
    <SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope">
        <SOAP-ENV:Body>
            <updateLine xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="http://www.cisco.com/AXL/API/1.0">
                < pattern>3637056< /pattern>
                <routePartitionName>AXLTest</routePartitionName>
                <routeFilterName />
                <newRoutePartitionName>testglx</newRoutePartitionName>
            </updateLine>
        </SOAP-ENV:Body>
    </SOAP-ENV:Envelope>

    ---------------------------------------------------------------------------------------------------------------------------------------------

    <SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope">
        <SOAP-ENV:Body>
            <updateLine xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="http://www.cisco.com/AXL/API/1.0">
                < pattern>3637056< /pattern>
                <routePartitionName>AXLTest</routePartitionName>
                <routeFilterName />
                <newPattern>3637056</newPattern>
                <newRoutePartitionName>testglx</newRoutePartitionName>
            </updateLine>
        </SOAP-ENV:Body>
    </SOAP-ENV:Envelope>

    ---------------------------------------------------------------------------------------------------------------------------------------------
    <SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope">
        <SOAP-ENV:Body>
            <updateLine xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="http://www.cisco.com/AXL/API/1.0">
                  <uuid>{99F64048-D5BF-4036-AD4A-86AF54AD0B5D}</uuid>
                <newRoutePartitionName>testglx</newRoutePartitionName>
            </updateLine>
        </SOAP-ENV:Body>
    </SOAP-ENV:Envelope>
    ---------------------------------------------------------------------------------------------------------------------------------------------
    <SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope">

        <SOAP-ENV:Body>

            <updateLine
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xmlns:xsd="http://www.w3.org/2001/XMLSchema"
    xmlns="http://www.cisco.com/AXL/API/1.0">

                  <uuid>{99F64048-D5BF-4036-AD4A-86AF54AD0B5D}</uuid>
                  <newPattern>3637056</newPattern>

                <newRoutePartitionName>testglx</newRoutePartitionName>

            </updateLine>

        </SOAP-ENV:Body>

    </SOAP-ENV:Envelope>
    ---------------------------------------------------------------------------------------------------------------------------------------------