Translation pattern removing DNs?

Version 1
    This document was generated from CDN thread

    Created by: David Robinson on 03-05-2012 12:22:56 PM
    Hello all,
     
    I came across an issue recently concerning the addition of translation patterns and existing DNs.  The situation is as follows:
     
    We have a v8 PBX and CUCM system set up.  We retrieve various data from this configuration via AXL requests.  We also occassionaly add translation patterns as well.  When adding a translation via the addTransPattern AXL request we are seeing some strange behavior.  If the new translation pattern has a pattern value that matches an existing 10-digit DN (I think it only affects DNs on the same route partition), the existing DN (in our case, the DN is on some phone that is already provisioned) is removed from the system.  Then the translation pattern is added successfully.  
     
    If you attempt to add the translation pattern via the CUCM UI, you get an error that tells you that the DN already exists and the translation pattern is not added. 
     
    Why the different behavior?  Is the AXL behavior by design?  Is this a known issue? 
     
    If more info of any kind is needed, please let me know.
     
    Thanks,
    David

    Subject: RE: Translation pattern removing DNs?
    Replied by: David Staudt on 13-06-2012 04:29:26 PM
    AFAIK not a known issue but makes sense, and would agree the behaviour needs to be improved.  
     
    Hopefully you can workaround this by putting in your own check via AXL to see if the DN exists before calling addTransPattern (you may need to do it via executeSQLQuery.)
     
    CSCua45421 has been opened to track this issue.

    Subject: RE: Translation pattern removing DNs?
    Replied by: David Staudt on 14-06-2012 12:41:55 PM
    Not able to reproduce this on UCM 8.0(1), can you provide some additional information:
     
    - Full version # of UCM
    - Full XML of the request/response that occurs
     
    This was my test run, with '2234' an existing line on a device:
     
    <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns="http://www.cisco.com/AXL/API/8.0">
       <soapenv:Header/>
       <soapenv:Body>
          <ns:addTransPattern sequence="1">
             <transPattern>
                <pattern>2234</pattern>
                <usage>Translation</usage>
                <routePartitionName/>
             </transPattern>
          </ns:addTransPattern>
       </soapenv:Body>
    </soapenv:Envelope>
    -------------------------------
    <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
       <soapenv:Body>
          <soapenv:Fault>
             <faultcode>SOAP-ENV:Client</faultcode>
             <faultstring>Cannot insert or update pattern. A DN exists with the same pattern and partition.</faultstring>
             <detail>
                <axlError>
                   <axlcode>4052</axlcode>
                   <axlmessage>Cannot insert or update pattern. A DN exists with the same pattern and partition.</axlmessage>
                   <request>addTransPattern</request>
                </axlError>
             </detail>
          </soapenv:Fault>
       </soapenv:Body>
    </soapenv:Envelope>