1 Reply Latest reply on Nov 17, 2016 4:37 AM by Tamás Járvás

    Additional Maven plugin invocation at Build & Deploy

    Tamás Járvás Newbie

      HI,

       

      I am using JBPM 6.3.

       

      I created a custom maven plugin, which runs before the compilation and generates java source files based on the available process definitions in the project. I've added this plugin to my pom file and it works fine in my local machine if I invoke a 'mvn clean install' for example. It generates/refreshes the java source files, which are compiled and packed into the result kjar.

       

      However, when I invoke the Build & Deploy function in JBPM-console (aka KIE Workbench) running on a server, it doesn't happen. No error messages, it deploys the produced kjar to the maven repository, but it doesn't contain any generated java classes. The settings.xml file is the same on the server, what I use in my local machine, so it should access my custom maven plugin from our nexus maven repository.

       

      I also tried to add another maven plugin, the 'maven-source-plugin', to generate a separate jar with the java sources. This also works locally, but the JBPM-console still uploads only one jar, no sources jar.

       

      I feel that no maven plugins are invoked at all.

       

      Is it possible to use maven plugins when using the Build & Deploy button in the JBPM-console? What exactly that button does? It works with native maven, by invoking some maven goal? Or some embedded maven implementation is used, which has limited functionality? I didn't found any maven log in the JBPM-console logs. Should I?

       

      Thanks in advance!

        • 1. Re: Additional Maven plugin invocation at Build & Deploy
          Tamás Járvás Newbie

          I think I found the answer myself. As I see, not a native maven is used, its a custom implementation called guvnor-project. Checking the source code of that project, I found that it just uses the pom.xml to parse the necessary information from it, and it builds the kjar itself, without calling any maven goal. So no plugins are running.

           

          I solved my problem by defining a job in our Jenkins, which really builds the kjar by maven and I stop using the Build & Deploy function on the UI.