Questions tagged [maven-plugin]

Do not use this tag for the use of specific Maven plugins. Use it only for Maven plugins development related questions.

Maven Plugins, also known as Mojos, are the central feature of Maven that allow for the reuse of common build logic across multiple projects.

From the official Maven documentation

"Maven" is really just a core framework for a collection of Maven Plugins. In other words, plugins are where much of the real action is performed, plugins are used to: create jar files, create war files, compile code, unit test code, create project documentation, and on and on. Almost any action that you can think of performing on a project is implemented as a Maven plugin.


Please do not use this tag for the use of specific Maven plugins. Use it only for Maven plugins development related questions.

More information

3670 questions
1
vote
1 answer

Maven MojoExecutionException in cxf-xjc-plugin:3.3.0

This question is nearly a duplicate of MojoExecutionException when generate sources cxf-xjc-plugin:3.3.0 java11 with two exceptions: The accepted answer in that question provides a work-around without answering the question. The issue discussed in…
mbmast
  • 960
  • 11
  • 25
1
vote
3 answers

kie-maven-plugin:7.36.1.Final Plugin extension dependency error using Maven

Migrating Drools from 6.5.0.Final to Drools 7.36.1.Final , I am facing issue in resolving org.kie:kie-maven-plugin:7.36.0.Final dependency issue as below [ERROR] [ERROR] Some problems were encountered while processing the POMs: [ERROR] Unresolveable…
1
vote
1 answer

How does Maven know where input files come from and where output files go during the generate-sources phase?

I am new to Maven. I have a project which includes a grammar definition file that is read by SableCC, which is a parser generator. SableCC reads a grammar file and generates Java source code that, once compiled, creates a parser. The parser is…
mbmast
  • 960
  • 11
  • 25
1
vote
1 answer

Maven plugin configuration in the multi module project

I'm working on the multi module project. I want to run my plugin after build for one of the modules. This mojo should be only run directly from CLI and can not be attached to the phase as on some environments we dont want to run this goal. What is…
des
  • 11
  • 2
1
vote
4 answers

Unable to add maven dependency for Apache Commons-csv

Hi All i am trying to add Apache commons-csv version 1.8 dependency for my spring boot project but getting following error. Dependency 'org.apache.commons:commons-csv:1.8' not found. Also i am using Java 14.For your reference here i am also pasting…
1
vote
0 answers

Sprint Boot Stubs of spring cloud contract could not be found

I'm new to Spring Boot. I just created a project (using https://start.spring.io ). I've tried to run the application by using Maven (./mvnw install) and I got this error: Failed to execute goal …
Alexis
  • 11
  • 1
1
vote
1 answer

Does maven surfire argLine override ./mvn/jvm.config?

I have a project with the following ./mvn/jvm.config : -Xms32g -Xmx64g -XX:MaxDirectMemorySize=20g I was wondering if I configure my maven surfire plugin as follows: org.apache.maven.plugins
Mr. D
  • 657
  • 1
  • 8
  • 21
1
vote
1 answer

Maven install command with environment variables file

Is there any way to execute the environment variables file .env along with maven commands such as mvn clean install or mvn clean deploy. The main idea behind the concept that I'm looking for similar kind of solution: mvn clean install…
1
vote
1 answer

Avro maven plugin for optional fields

I am using the Avro maven plugin to process some Avro files and generate the Java classes. My goal is to tell the plugin to generate Optional getters whenever the field accepts null values, by declaring the type null. For example: { "namespace":…
AmsterdamLuis
  • 341
  • 3
  • 21
1
vote
1 answer

How to exclude module-info.java file from maven-processor-plugin?

Please, help to exclude module-info file. This is my code: org.bsc.maven maven-processor-plugin 3.3.3
Pavel_K
  • 10,748
  • 13
  • 73
  • 186
1
vote
0 answers

Could not find metadata maven-metadata.xml in remote(nexus)

I use spring-contract as contract test in my project with gradle. I want to publish the contract stubs to nexus server. But when I execute the publishing command. The error occur. build.gradle file buildscript { project.ext { bootVersion…
Xin
  • 55
  • 1
  • 6
1
vote
1 answer

Who configures all these Maven repositories in my build?

I am running mvn dependency:list-repositories in order to find out what repositories is maven actually considering and their order (I need this to troubleshoot my settings.xml configuration). For a bigger project that does not use any
Gabriel Petrovay
  • 20,476
  • 22
  • 97
  • 168
1
vote
1 answer

How to prevent build failure with custom Maven Plugin?

How do i prevent my custom maven plugin to fail the build? I do not want to the build to fail if there is an issue in the custom maven plugin. How do i implement that? Any examples would be helpful. I see but not sure how to configure that.
bigskull
  • 739
  • 2
  • 13
  • 23
1
vote
1 answer

How to use mockito with maven testing harness

The maven plugin I am developing now injects some dependencies using Google Guice with JSR-330. For unit testing I am using maven-plugin-testing-harness. The plugin works perfectly. But there is a problem with tests. I want to inject mocked…
1
vote
1 answer

Maven - Unable to set property value using profile based on property activation

I am trying to set a maven property value based on another property that is sent through the command line. desktop environment
JagadeesanV
  • 35
  • 2
  • 7