Customer Portal

How To install and Create executable Graph in linux??

Comments 8

  • Avatar
    avackova
    0
    Comment actions Permalink
    Hello,
    in cloverETL/bin you can find scripts for graph execution: clover.bat for Windows and clover for linux. Set the permission to the scripts to executable and you can run the graph, e.g:
    /home/user/cloverETL/bin/clover graph/my_graph.grf
  • Avatar
    megreddy
    0
    Comment actions Permalink
    If I'm understanding this correctly, there is a way to execute a graph from command line (so without launching Clover)? If so, could you provide further clarification on how to do this in Windows?

    I'm looking for a way to either (1) package a .grf as an .exe, or (2) write a script that periodically runs the graph logic. In my case, the graph is a simple "Read->Format->Aggregate/Analysis->Write" process.

    Thanks in advance for the help!
  • Avatar
    avackova
    0
    Comment actions Permalink
    You can add a task to Windows Scheduler, that executes clover.bat script.
  • Avatar
    megreddy
    0
    Comment actions Permalink
    Thanks for the response! Are you referring to the clover.bat script located (on Windows) in [C:\Program Files\CloverETL\plugins\com.cloveretl.gui_3.0.0\lib\bin]?

    If so, I tried moving clover.bat (and the companion commonlib.bat) into the local directory of my .grf and entered

    cd [local directory]
    clover.bat test_graph.grf

    This sets CLOVER_CMD_LINE_ARGS = test_graph.grf. But it terminates in an error

    Exception in thread "main" java.lang.UnsupportedClassVersionError: Bad version number in .class file
    at java.lang.ClassLoader.defineClass1(Native Method)
    at ...

    Do you know where my error is?
  • Avatar
    avackova
    0
    Comment actions Permalink
    CloverETL 3.0 requires java 1.6 or higher and I suppose you try to run the graph with lower java version. This is probably the reason of the error.

    But to run successfully the graph you need complete CloverETL (all jar files from CloverETL/lib directory and all from CloverETL/plugins directory).

    This is the simplest instruction how to run the graph from command line:

    • set system variable CLOVER_HOME to point to CloverETL (set CLOVER_HOME="C:\Program Files\CloverETL")

    • go to the project folder

    • call the clover.bat script ("C:\Program Files\CloverETL\bin\clover.bat" graph/my.grf)
  • Avatar
    megreddy
    0
    Comment actions Permalink
    It was in fact a simple matter of updating Java and setting CLOVER_HOME. Thanks for your help Agata!
  • Avatar
    megreddy
    0
    Comment actions Permalink
    As a follow-up to your instructions, I was wondering how to set the CLOVER_HOME and CLOVER_CMD_LINE_ARGS values within the .bat. That is, I want to simply set up a Windows Schedule to execute clover.bat, rather than type the command line:
    "C:\Program Files\...\clover.bat" graph\myGraph.grf


    Thanks for the help!
  • Avatar
    smrckoval
    0
    Comment actions Permalink
    Set the CLOVER_HOME system variable. Pretty nice Task Sheduler tutorial can be found here.

    Just create an action Start a program, put the complete clover.bat URL into Program/script field and the complete graph URL as the optional argument.

Please sign in to leave a comment.