Uploaded image for project: 'Red Hat CodeReady Studio (devstudio)'
  1. Red Hat CodeReady Studio (devstudio)
  2. JBDS-4745

Drools maven archetype or quickstart using kjar packaging doesn't build

    XMLWordPrintable

Details

    • Bug
    • Resolution: Won't Do
    • Minor
    • 12.x
    • 12.9.0.GA
    • build
    • None
    • 8
    • Hide

      Go to new project > maven project > in the catalog type kie-drools-archetype

      Project will not build with this error here
      An internal error occurred during: "Updating Maven Project".
      Missing parameter for pluginExecutionFilter. groupId, artifactId, versionRange and goals must be specificed, but found: groupId = 'org.kie'
      artifactId = 'kie-maven-plugin'
      versionRange = '7.13.0.Final'
      goals = '[]'

      After that you can add the versionRange like this

      <pluginManagement>
      <plugins>
      <!--This plugin's configuration is used to store Eclipse m2e settings
      only. It has no influence on the Maven build itself. -->
      <plugin>
      <groupId>org.eclipse.m2e</groupId>
      <artifactId>lifecycle-mapping</artifactId>
      <version>1.0.0</version>
      <configuration>
      <lifecycleMappingMetadata>
      <pluginExecutions>
      <pluginExecution>
      <pluginExecutionFilter>
      <groupId>org.kie</groupId>
      <artifactId>kie-maven-plugin</artifactId>
      <versionRange>${drools-version}</versionRange>
      <goals>
      <goal>compile</goal>
      <goal>package</goal>
      <goal>build</goal>
      </goals>
      </pluginExecutionFilter>
      <action>
      <ignore />
      </action>
      </pluginExecution>
      </pluginExecutions>
      </lifecycleMappingMetadata>
      </configuration>
      </plugin>
      </plugins>
      </pluginManagement>

      However, this will still throwing the error you will be able to build from the command line with the versionRange or not.

      You can try to build in the command line which will work, after that if you try to refresh in RH Developer Studio still getting the same error and the project will not build.

      Show
      Go to new project > maven project > in the catalog type kie-drools-archetype Project will not build with this error here An internal error occurred during: "Updating Maven Project". Missing parameter for pluginExecutionFilter. groupId, artifactId, versionRange and goals must be specificed, but found: groupId = 'org.kie' artifactId = 'kie-maven-plugin' versionRange = '7.13.0.Final' goals = '[]' After that you can add the versionRange like this <pluginManagement> <plugins> <!--This plugin's configuration is used to store Eclipse m2e settings only. It has no influence on the Maven build itself. --> <plugin> <groupId>org.eclipse.m2e</groupId> <artifactId>lifecycle-mapping</artifactId> <version>1.0.0</version> <configuration> <lifecycleMappingMetadata> <pluginExecutions> <pluginExecution> <pluginExecutionFilter> <groupId>org.kie</groupId> <artifactId>kie-maven-plugin</artifactId> <versionRange>${drools-version}</versionRange> <goals> <goal>compile</goal> <goal>package</goal> <goal>build</goal> </goals> </pluginExecutionFilter> <action> <ignore /> </action> </pluginExecution> </pluginExecutions> </lifecycleMappingMetadata> </configuration> </plugin> </plugins> </pluginManagement> However, this will still throwing the error you will be able to build from the command line with the versionRange or not. You can try to build in the command line which will work, after that if you try to refresh in RH Developer Studio still getting the same error and the project will not build.
    • NEW

    Description

      Any drools project which needs to use kie-maven-plugin to packing kjar maven project it's falling to build with the following error:

      An internal error occurred during: "Updating Maven Project".
      Missing parameter for pluginExecutionFilter. groupId, artifactId, versionRange and goals must be specificed, but found: groupId = 'org.kie'
      artifactId = 'kie-maven-plugin'
      versionRange = '7.13.0.Final'
      goals = '[]'

      You can create a maven project from the catalog archetype kie-drools-archetype, which will come with
      ...
      <packaging>kjar</packaging>
      ...

      ...
      <plugin>
      <groupId>org.kie</groupId>
      <artifactId>kie-maven-plugin</artifactId>
      <version>${drools-version}</version>
      <extensions>true</extensions>
      </plugin>

      I also added this part here in the pom file
      <pluginManagement>
      <plugins>
      <!--This plugin's configuration is used to store Eclipse m2e settings
      only. It has no influence on the Maven build itself. -->
      <plugin>
      <groupId>org.eclipse.m2e</groupId>
      <artifactId>lifecycle-mapping</artifactId>
      <version>1.0.0</version>
      <configuration>
      <lifecycleMappingMetadata>
      <pluginExecutions>
      <pluginExecution>
      <pluginExecutionFilter>
      <groupId>org.kie</groupId>
      <artifactId>kie-maven-plugin</artifactId>
      <versionRange>${drools-version}</versionRange>
      <goals>
      <goal>compile</goal>
      <goal>package</goal>
      <goal>build</goal>
      </goals>
      </pluginExecutionFilter>
      <action>
      <ignore />
      </action>
      </pluginExecution>
      </pluginExecutions>
      </lifecycleMappingMetadata>
      </configuration>
      </plugin>
      </plugins>
      </pluginManagement>

      Which was a workaround in previous drools version.

      However this didn't work either.

      I can build from the command line with or without the pluginManagement and I can build this archetype without issues in other IDE like IntelliJ

      Attachments

        1. pom.xml
          5 kB
        2. pom.xml
          4 kB

        Issue Links

          Activity

            People

              jmaury@redhat.com Jeff MAURY
              rhn-gps-pamenon Paulo Menon (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: