Uploaded image for project: 'Camel'
  1. Camel
  2. CAMEL-15043

MojoFailureException after creating a new component using archetype then build it straight away

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 3.2.0
    • Fix Version/s: 3.4.0
    • Component/s: tooling
    • Environment:

      OS -> Mac OS 10.15.4

      Maven -> 3.6.3

      Java -> 1.8.0_241

    • Estimated Complexity:
      Novice

      Description

       

      Intention: To create my own Camel component.

       

      Steps:

      1. Run `mvn archetype:generate -DarchetypeGroupId=org.apache.camel.archetypes -DarchetypeArtifactId=camel-archetype-component -DarchetypeVersion=3.2.0 -DgroupId=org.apache.camel -DartifactId=camel-mycomponent -Dname=MyComponent -Dscheme=mycomponent -Dpackage=org.apache.camel.component.mycomponent` and it'll create `camel-mycomponent` directory. Then open the `pom.xml` and delete the `OSGi` part because I don't need it.
      2. Under `camel-mycomponent` run `mvn clean install`

       

      Result:

      Got error

      [ERROR] Failed to execute goal org.apache.camel:camel-package-maven-plugin:3.2.0:generate-component (generate) on project camel-mycomponent: Error generating data org.apache.maven.plugin.MojoFailureException: Unable to create mojo: Could not find component java type -> [Help 1] 

       

      Expected: Build successfully with a jar output.

        Attachments

          Activity

            People

            • Assignee:
              acosentino Andrea Cosentino
              Reporter:
              alvinma Alvin Ma
            • Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: