DX Unified Infrastructure Management

  • 1.  Documentation on probe callbacks?

    Posted Apr 24, 2018 04:44 PM

    Hello,

     

    I've been poking around and found some functionality that would be useful to me in the ADE probe. I would love to be able to write something to deploy probe(s) in an automated fashion. I found some documentation, however it might be outdated. 

     

    Unable to deploy probes via ADE REST call. - CA Knowledge 

     

    I'm trying to deploy using $ADE_ADDRESS/callback2/deploy_probe, with the following:

     

    HTTP POST application/xml

    <nimPds>

    <package>cdm</package>

    <robot>$ROBOTADDR</robot>

    </nimPds>

     

    I get a 500 response with the message "Received status (3) on response (for sendRcv) for cmd = 'deploy_probe'

     

    If I looked in the ADE log, it states ''invalid argument, Parameter 'packageName' cannot be null or empty." If I try the call with packageName instead of package, I get the same message. 

     

    If I try a different call (submit_job) I get a successful response with a job ID, but the job seemingly never starts, and I can't receive a status back. 

     

    Has anyone utilitized the ADE REST API? On a similar note, is there any documentation for callbacks for other probes on what is required to get a successful response? In CA PM, you could get the information required for a successful REST call through a restcall. If you do options against the call in UIM, it tells you that it expects nimPds in either json or XML, but that's about it. 

     

    Any insight would be appreciated!

     

    Thanks,

    Josh



  • 2.  Re: Documentation on probe callbacks?

    Posted Apr 25, 2018 09:26 AM

    Personally I've had abysmal luck with ADE. It's only a fraction as reliable as distsrv and much slower in my environment.

     

    As such, I've done all my distribution automation with callbacks into distsrv.

     

    Something like this (using LUA) is all you need:

     

    toInstall = pds.create()
    pds.putString(toInstall,"job_id","DeployPackage")
    pds.putString(toInstall,"package","Replace with Name of the package")
    pds.putString(toInstall,"robot", "Replace with Robot Address")
    pds.putInt(toInstall,"update",0)
    pds.putInt(toInstall,"start_at",0)

    a,b = nimbus.request("/Replace with PathToYourCentralHub/distsrv", "job_add",toInstall)

     

    There is a REST call to make this probe callback too so you can continue to use that interface

     

    -Garin



  • 3.  Re: Documentation on probe callbacks?

    Posted Apr 25, 2018 04:11 PM

    I tested and was able to get this working using the following in my lab environment

     

    POST http://<umpserver>/rest/probe/DOMAIN/PRIMARYHUB/HUBNAME/ROBOT/automated_deployment_engine/callback2/deploy_probe

     

    Headers
    Content-Type  application/xml

    Accept application/xml

     

    Body
    <nimPds>
    <nimString key="package">cdm</nimString>
    <nimString key="version">6.20</nimString>
    <nimString key="robot">/DOMAIN/HUB/ROBOT</nimString>
    <nimString key="update">0</nimString>
    <nimString key="startAt">0</nimString>
    </nimPds>

     

    Response

    <?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
    <nimPds>
    <nimString key="JobID">
    b4c78514200d4566aa15ee20025a7a9b
    </nimString>
    </nimPds>
    Hopefully this helps out.
    Greg