Customer Portal

Specify alternate plugins directory for designer

Comments 5

  • Avatar
    jurban
    0
    Comment actions Permalink
    Hi,

    the "use alternate plugins location" method will not work - it switches the location where CloverETL Engine looks for all its plugins, even the "core" ones. Currently it's not possible to add just an engine plugin that would be located outside of the plugins location.

    Just to be sure - are you creating only an engine plugin? Because I can see that you're using the Designer - are you not creating a Designer plugin which would internally bundle the engine plugin? The Designer plugin would add GUI support for your components (e.g. they would appear in the palette).

    Best regards,
    Jaro
  • Avatar
    jonjlee
    0
    Comment actions Permalink
    I am writing an engine plugin -- it does not have a GUI.

    What you said makes sense. However, I have also tried to copy .../Eclipse/plugins/com.cloveretl.gui_3.0.2/lib/plugins to a different location and the designer is still unable to find my custom plugin. I set the "Plugins location" option to /path/to/my/lib/plugins/, and /path/to/my/lib/plugins contains:


    /path/to/my/lib/plugins/
    + com.myplugin.namespace/
    + plugin.xml
    + myplugin.jar
    + org.jetel.bulkloader
    + cloveretl.bulkloader.jar
    + lib/
    + plugin.xml
    + org.jetel.component
    + ...
    + org.jetel.connection
    + ...
    + ...


    When this same directory structure exists in the Eclipse directory, the Designer finds my custom plugin. Is it possible to accomplish what I'm trying to do?

    Thanks,
    Jonathan
  • Avatar
    jurban
    0
    Comment actions Permalink
    Hi Jonathan,

    I've just tried the scenario with CloverETL 3.0.2, and it seems to work. I've copied the plugins directory from Designer to an outside location, similarly to what you did. Then I've added my custom engine plugin there and changed the plugins location. Then I created a simple graph with the component and saw that it was recognized.

    I'm attaching a ZIP with the engine plugin and a graph that uses it. When you run the graph, it will fail with the error "Can't create object of type DIVIDER with reason: Missing a required attribute!" - this is OK, as the error is thrown from inside the component's code (the fromXML() method) so it means the component was recognized.

    Hopefully this helps. If you'll still have issues - please attach the graph log (console output).

    Regards,
    Jaro
  • Avatar
    jonjlee
    0
    Comment actions Permalink
    I am able to run the graph that you provided, and I see the expected exception, so clover correctly located the component. However, the Designer doesn't recognize it. In my Problems window, I see:


    ENGINE: Error during graph initialization (java.lang.RuntimeException: Unknown component: DIVIDER class: DIVIDER).


    If I unpack the plugin into .../Eclipse/plugins/com.cloveretl.gui_3.0.2/lib/plugins/ and restart Eclipse, then the error disappears. Is there a way to have the Designer recognize plugins from an alternate location?

    Thanks!
    Jonathan

    Graph output:

    INFO [main] - *** CloverETL framework/transformation graph, (c) 2002-2011 Javlin a.s, released under GNU Lesser General Public License ***
    INFO [main] - Running with CloverETL library version 3.0.2 build#31 compiled 29/03/2011 11:23:07
    INFO [main] - Running on 2 CPU(s), OS Mac OS X, architecture x86_64, Java version 1.6.0_29, max available memory for JVM 126912 KB
    INFO [main] - Loading default properties from: defaultProperties
    INFO [main] - Graph definition file: graph/generate_test.grf
    ERROR [main] - Can't create object of type DIVIDER with reason: Missing a required attribute!
    Exception in thread "main" java.lang.RuntimeException: Can't create object of type DIVIDER with reason: Missing a required attribute!
    at org.jetel.component.ComponentFactory.createComponent(ComponentFactory.java:151)
    at org.jetel.graph.TransformationGraphXMLReaderWriter.instantiateNodes(TransformationGraphXMLReaderWriter.java:496)
    ...
  • Avatar
    jurban
    0
    Comment actions Permalink
    Hi Jonathan,

    the problem you're seeing is cause by the checkconfig in Designer (it creates an instance of the graph and asks it for configuration problems). Unfortunately checkconfig does not support the alternate location of engine plugins. I've reported an issue in our bugtracker: https://bug.javlin.eu/browse/CLD-3184.

    You might be able to work around this outside Designer - for example by creating a symbolic link if you're using a Unix-like system. However that's quite clunky...

    Regards,
    Jaro

Please sign in to leave a comment.