Clarity

Expand all | Collapse all

How to call process using GEL script from command prompt?

  • 1.  How to call process using GEL script from command prompt?

    Posted Apr 14, 2015 07:17 AM

    I need to call a process which is in Clarity Server using a Gel script from Outside Clarity.

    Anyone please help me out here.



  • 2.  Re: How to call process using GEL script from command prompt?

    Posted Apr 14, 2015 07:49 AM


  • 3.  Re: How to call process using GEL script from command prompt?

    Posted Apr 14, 2015 07:57 AM

    The thread that NJ has linked to is discussing running the GEL (outside of the process) from the command line (i.e. you would copy the GEL script from the process to somewhere else and run it).

     

    If you really need to run the process itself, from outside of the application, you can do this over the application's web-services ; by calling the InvokeAction web-service.



  • 4.  Re: How to call process using GEL script from command prompt?

    Posted Apr 14, 2015 08:52 AM

    Thank you David, but I don't know how to do it. Will you plz post an example or a link where I can refer it.



  • 5.  Re: How to call process using GEL script from command prompt?

    Posted Apr 14, 2015 10:13 AM

    Search in this community for "InvokeAction" and you will find threads discussing it.

     

    (I don't have a quick-guide to this at all)



  • 6.  Re: How to call process using GEL script from command prompt?
    Best Answer

    Posted Apr 15, 2015 05:25 AM

    Also I recall that there was a presentation (PP501LN) at CAWorld a few years ago that discussed this ; the presentation material is uploaded to the community here ;

     

    CA World 2010 - web services integrations within CA ClarityTM



  • 7.  Re: How to call process using GEL script from command prompt?

    Posted Apr 17, 2015 08:32 AM

    Thanks David for sharing. It was really helpful.

    It worked for me.



  • 8.  Re: How to call process using GEL script from command prompt?

    Posted Jul 23, 2015 05:19 AM

    HI,

     

    I am also looking for something similar.

     

    1. I have jdk 7 at path  D:\Java\jdk1.7.0_79

    2. XOG at path C:\CA\Clarity\CA Clarity PPM XOG

     

    3. I am putting a basic script test.xml inside bin folder

     

    <gel:script xmlns:core="jelly:core"

      xmlns:gel="jelly:com.niku.union.gel.GELTagLibrary">

       

          <gel:out>Hello World</gel:out>

       

    </gel:script>

     

    4. JAVA_HOME is set as D:\Java\jdk1.7.0_79

     

    but it is throwing error

     

    Caused by: com.niku.union.config.ConfigurationException: Error unmarshalling con

    fig file: properties.xml

            at com.niku.union.config.ConfigurationManager.fetchConfigFileObject(Conf

    igurationManager.java:4562)

            at com.niku.union.config.ConfigurationManager.fetchConfigObject(Configur

    ationManager.java:3964)

            at com.niku.union.config.ConfigurationManager.getProperties(Configuratio

    nManager.java:657)

            at com.niku.union.config.ConfigurationManager.getRawProperties(Configura

    tionManager.java:635)

            at com.niku.union.config.ConfigurationManager.isSingleTenantMode(Configu

    rationManager.java:791)

            at com.niku.union.utility.UtilityThreadLocal.init(UtilityThreadLocal.jav

    a:108)

            at com.niku.union.gel.GELClient.invoke(GELClient.java:83)

            at com.niku.union.gel.GELClient.main(GELClient.java:57)

            ... 6 more

    Caused by: java.io.IOException: The system cannot find the path specified

            at java.io.WinNTFileSystem.createFileExclusively(Native Method)

            at java.io.File.createNewFile(Unknown Source)

            at com.niku.union.config.ConfigurationManager.getConfigFileProperties(Co

    nfigurationManager.java:4370)

            at com.niku.union.config.ConfigurationManager.fetchConfigFileObject(Conf

    igurationManager.java:4419)

            ... 13 more

     

     

    What am I missing?



  • 9.  Re: How to call process using GEL script from command prompt?

    Posted Jul 23, 2015 05:33 AM


  • 10.  Re: How to call process using GEL script from command prompt?

    Posted Jul 23, 2015 05:35 AM


  • 11.  Re: How to call process using GEL script from command prompt?

    Posted Jul 23, 2015 05:38 AM

    which documents David is referring to?



  • 12.  Re: How to call process using GEL script from command prompt?

    Posted Jul 23, 2015 05:44 AM

    Got that!!



  • 13.  Re: How to call process using GEL script from command prompt?

    Posted Jul 23, 2015 05:45 AM

    The "Error unmarshalling config file: properties.xml" is to do with the setup of the environment that you are running XOG from.

     

    ( How to setup the environment is covered in one of the documents in the Gel.zip file attached to the FAQ thread ; CA Clarity General Discussion - FAQs  )



  • 14.  Re: How to call process using GEL script from command prompt?

    Posted Jul 27, 2015 05:20 AM

    Hi,

     

    I read the document; set JAVA_HOME as suggested. I am trying to run simple hello world program (as mentioned in doc); but still getting the same error. Why properties.xml coming into picture, its a simple program?



  • 15.  Re: How to call process using GEL script from command prompt?

    Posted Jul 27, 2015 05:29 AM

    What I was referring to is that you must have a copy of properties.xml in a path in your local filesystem in order to run GEL "locally" (i.e. outside of the Clarity environment).

     

    I think the detail is in the "Why Hello World is Useful" document?



  • 16.  Re: How to call process using GEL script from command prompt?

    Posted Jul 27, 2015 05:37 AM

    Could you please share the link or doc "Why Hello World is Useful"



  • 17.  Re: How to call process using GEL script from command prompt?

    Posted Jul 27, 2015 05:40 AM

    Uruj wrote:

     

    Could you please share the link or doc "Why Hello World is Useful"

    I thought it was in that zip file attached to the FAQ thread?   "GEL - Why helloworld is useful.docx"



  • 18.  Re: How to call process using GEL script from command prompt?

    Posted Oct 07, 2015 09:32 AM
      |   view attached

    Hi All,

     

    I have a question if somebody ever met with situation that this error "Error unmarshalling config file: properties.xml"

    was NOT solved with all staff mentioned in Gel.zip file (guides) or threads on this forum. Because I've tried everything (see notes) and still getting this error.

     

    I have to say that some scripts I could run (hello world, read from database, etc.) but I'm trying to execute one script when parsing file and that's the problem.

    Script itself should be OK because my colleague is running it well.

     

    Notes: Clarity is ver 13.3.0.286, xogclient downloaded from Clarity as usual

               Java on my machine installed is ver 1.8.0

               Properties.xml file located in as recommended

              Java_Home, Path and other variables set correctly (using also another programs)

     

    In case of interest I've attached the script. Thanks

    properties.JPG

     

    error-properties.JPG

     

    Thanks

     

    Matej

    Attachment(s)



  • 19.  Re: How to call process using GEL script from command prompt?

    Posted Oct 07, 2015 10:55 AM


  • 20.  Re: How to call process using GEL script from command prompt?

    Posted Oct 08, 2015 01:54 AM

    Hi Navzjoshi,

     

    Yes of course, as I've mentioned above. Those ideas didn't help me.

     

    Matej



  • 21.  Re: How to call process using GEL script from command prompt?

    Posted Oct 08, 2015 05:17 AM

    Hi All,

     

    As I just knew from this thread https://communities.ca.com/message/241696144#241696144

    It should be some bug for xogclient ver. 13.3. When I've just downloaded Xogclient ver 13.1, it's working perfectly.

     

    Matej