DX Infrastructure Management

Expand all | Collapse all

REST call from ems action?

  • 1.  REST call from ems action?

    Posted 10-05-2018 04:29 AM

    We need to enrich Spectrum alarms in UIM. The data is available via Spectrum REST call - did anybody manage to code a Spectrum REST call in an ems "action"?

    If yes - could I see some samples how to do that, please?

     

    BR

    Richard



  • 2.  Re: REST call from ems action?

    Posted 10-05-2018 04:47 AM


  • 3.  Re: REST call from ems action?

    Posted 10-05-2018 04:53 AM

    Yes, similar, only I would like to add a REST call there, to retrieve some attribute values from Spectrum, which I would then put into custom_n fields.



  • 4.  Re: REST call from ems action?

    Posted 10-08-2018 05:51 AM

    I did some testing, added following code into an action rule:

    client = new RESTClient( 'http://192.168.1.139:8080/spectrum/restful' )

    I am getting syntax error - the class RESTClient cannot be resolved.

     

    Does anybody know, which classes are supported by the ems Groovy? 



  • 5.  Re: REST call from ems action?

    Posted 10-08-2018 09:04 AM


  • 6.  Re: REST call from ems action?

    Posted 10-09-2018 04:15 AM

    Hi David,

    I know the documentation, it shows all the additional classes, CA added for UIM support. REST is a "standard" Groovy class, but it has to be, in normal case "imported" to be available. It seems to me, after doing some testing, "import" is not allowed. So the question ist - which parts of the Groovy language are available at all. 

    Or is only avialable what the docu shows?

    Thanks

    Richard



  • 7.  Re: REST call from ems action?

    Posted 10-09-2018 08:29 AM

    Hi David,

     

    and if not REST, what abour SQL - could I retrieve some Device-Attributes from the UIM Database?



  • 8.  Re: REST call from ems action?

    Posted 10-09-2018 09:41 AM

    Yes, device attribute info is kept in the database.



  • 9.  Re: REST call from ems action?

    Posted 10-09-2018 09:51 AM

    I know that, but is there a SQL support in ems?



  • 10.  Re: REST call from ems action?

    Posted 10-09-2018 10:03 AM

    ems support all the alarm calls only.

    for info on a system the webservices rest can be used.

    Computer System Calls - CA Unified Infrastructure Management Probes - CA Technologies Documentation