Questions tagged [maven]

Apache Maven is a build automation and project management tool used primarily for Java projects. This tag is for questions that don't relate to a specific Maven version. Use the gradle tag instead for questions relating to Gradle.

Filter by
Sorted by
Tagged with
0
votes
0answers
5 views

Can't release project due to non-released dependencies in Pipeline

I am building a project in a pipeline. I am getting Build Failure Error: Can't release the project due to non-released dependencies. Multi-module java project using Maven as the Build tool and Nexus ...
0
votes
0answers
30 views

Spring boot Keep getting “required a single bean, but 10 were found” although I declared only one service

Whenever I run my spring boot application I keeb getting the following message: *************************** APPLICATION FAILED TO START *************************** Description: Field patchService ...
0
votes
0answers
12 views

ClassNotFoundException: org.testng.ITestListener with TestNG

I have a problem with run jar file created from maven. I need to create a jar file to run automation tests. This is my configuration of the plugin <plugin> <groupId>org....
0
votes
0answers
15 views

Can running a Maven command (in Git Bash) affect a process already running in Intellij IDE?

I am developing a Spring application. I am able to run my app in DEV mode from Intellij without any issues. Then, if I try to deploy my app (backend & frontend) using Git Bash, my Spring backend (...
0
votes
0answers
15 views

Lombok annotations: compilation failure after merging

We have a rather large project, using maven, spring boot, querydsl, lombok. I had 2 branches, both versions compiling successfully. (mvn clean compile) However, after merging, build fails, every of ...
1
vote
0answers
23 views

Unsupported Gauge Version: This version of Gauge Intellij plugin only works with Gauge version >= 0.9.0

I've a gauge project that I've been using since January 2019 and out of nowhere I started getting this unsupported gauge version error. I thought it was due to an update, either in gauge, intellij or ...
0
votes
0answers
12 views

missing method org.springframework.util.Assert.notNull in springboot aspect test

I'm trying to write a simple integration test for an aspect in order to check its wiring and logging (with slf4j). It looks something like this: @SpringBootTest @RunWith(SpringRunner.class) @...
0
votes
0answers
13 views

How can i force update of maven dependencies sources?

I know that i can get maven source dependencies using mvn dependency:sources But i get a lot of corrupted source code jars and i want to redownload them ? how can i do that ? Regards
0
votes
0answers
23 views

Docker COPY only copies one sub-directory, not whole build context

I have create a dummy project with Quarkus' Maven archetype in Java. I want to copy the whole build context into my Docker container. When I perform ls -al in the current directory I get this result: ...
0
votes
0answers
23 views

Can't start google chrome by selenium in Ubuntu

I am trying to run an automatic test using selenium + jetkins on Ubuntu. But when I run the mvn test command, I get the following error: org.openqa.selenium.WebDriverException: unknown error: ...
0
votes
0answers
25 views

Maven download a dependency that is not in the pom.xml nore a library dependency

I have a question. I'm working on a project generated using jhipster. I'm using maven as dependency management system. I have added bouncycastle for jdk 1.4. Now I want to switch to bouncycastle ...
1
vote
0answers
9 views

maven-version-rules.xml - how to process only some artifacts?

Maven versions plugin can use maven-version-rules.xml file to filter out unwanted versions of specific artifacts. So it works more like a blacklist. I would like to process only artifacts with their ...
1
vote
1answer
27 views

Maven could not resolve dependencies when using mvn test version number

Hello I have two spring boot modules, a mediator class and a mockserver class. The mediator class has the parent pom and the mockserver class has the child pom. They both have two spring boot apps on ...
0
votes
1answer
18 views

Maven Failure on Jenkins server, trying to get java-websocket 1.3.0 from apache snapshots for some reason?

I'm getting a failure on my jenkins build of an application that has worked for quite awhile. It is failing on: 08:47:42 [ERROR] Failed to execute goal on project DataAdapterFB1: Could not resolve ...
0
votes
0answers
14 views

Add Property File from Another Jar (Maven)

I am trying to do a maven build (lets say A.jar), where the property file resides in one of the dependencies (lets say, B.jar) that I am adding. Is there any way to add the properties from B.jar to A....
0
votes
0answers
15 views

Error starting javafx application with maven [duplicate]

When I try to run the application in NetBeans I get an exception saying Exception in Application start method java.lang.reflect.InvocationTargetException I know this is a problem that is asked a lot ...
0
votes
0answers
18 views

Sonarqube Scan only scans maven pom.xml file instead of src folder

I am currently setting up a CI-Pipeline with Jenkins/Sonarqube/Maven/OWASP, but im stuck in a Sonarqube problem. The Sonarqube-Scan only scans 1 file or every xml-File (which is only the pom.xml in ...
0
votes
0answers
6 views

SEVERE: Unable to process Jar entry from Jar [jakarta/ws/rs/jakarta.ws.rs-api/2.1.5/jakarta.ws.rs-api-2.1.5.jar!/] for annotations

I am trying to create a simple web-app implementing CRUD operations using Jax-rs. I have a resource class and a service class along with a model class. I need to create a war and then run it using ...
0
votes
0answers
34 views

Unable to compile spring boot project with java and scala using maven

I am trying to set up application using java,scala and spring boot. I have set up pom.xml. The code is running fine in intellij and I am able to run application successfully. But when i use mvn clean ...
-1
votes
2answers
23 views

Create EAR with Maven and Eclipse

I have a web-application(TestWeb) and multiple java dependency projects(TestCommon,TestModule). I was able to build all 3 projects using maven.It has created war file and jar file out of it. I need ...
1
vote
1answer
34 views

No main manifest attribute, in executable jar

while running my jar I receive the below error No main manifest attribute, in jar I have followed some of the solutions provided here but it did not solve the problem, I have tried to delete ...
0
votes
0answers
17 views

Modify Maven dependency download process

I have written a small server that allows downloading a diff between two versions of a Maven dependency and thus download fraction of the size and still have the whole file at the end. Currently, I ...
2
votes
0answers
18 views

OWASP dependency-check maven vs command line not same results

On a maven project, i am running both the OWASP dependency-check-maven plugin as also the OWASP command line tool in order to generate a report with dependencies having vulnerabilities. What i ...
-3
votes
0answers
16 views

Could not find artifact net.sourceforge.cpdetectora

https://mvnrepository.com/artifact/net.sourceforge.cpdetector/cpdetector/1.0.7 This is the maven dependency url, but i couldn't download it from my pom.xml
0
votes
1answer
27 views

Starting main and test app before Integration tests

I have two spring boot apps one in src/test and the other in src/main. They have their separate app.properties and separate ports. I want to make an integration test and before it runs I want it to ...
0
votes
2answers
39 views

.jar File Deployment - No Main Method

I am trying to create an executable .jar file for an application, but when I run "java -jar myapp.jar" I get the error: Error: Could not find or load main class com.vaadin.app.MainView I have ...
0
votes
0answers
13 views

Switching Maven Profile at runtime (via., actuator endpoint endpoint)

Is there a way to switch the spring profiles of an application run-time via., the actuator endpoint. Its fine if the application reloads/context refreshes. Appreciate your support.
0
votes
0answers
11 views

How to fix? ERROR StatusLogger No Log4j 2 configuration file found

I already have my log4j2.xml file in my resources package but when i run my mvn test it say No log4j 2 config file found. I also added this to my POM.xml file <dependency> <...
0
votes
1answer
18 views

Maven project inheritance: Cannot resolve imports from parent project

I set up two (maven) projects, the first contains simple Java-Classes. The first project should act as a master/parent project over (yet only one) many project. I need that the second project, should ...
0
votes
0answers
34 views

Java - java.lang.NoClassDefFoundError when trying to load resource

I am writing a application for my computer and it required a config file, I put my file into my resources folder and fetch it using URL configUrl = getClass().getResource(configURL) and then read it ...
0
votes
0answers
18 views

Can not find the tag library descriptor for http //java.sun.com/jsp/jstl/core after deleting .m2 file

I have a problem with some Maven dependencies. I deleted .m folder and after that I've cleaned all the projects, and after that I still have errors in some projects. For example I have this errors in ...
0
votes
0answers
16 views

org.springframework.boot.builder.SpringApplicationBuilder.<init>([Ljava/lang/Object;)V

When I start a microservice,throw this error:org.springframework.boot.builder.SpringApplicationBuilder.<init>([Ljava/lang/Object;)V. This is the log detail : 18:37:48.050 [background-preinit] ...
0
votes
0answers
24 views

(Spring Boot, Maven) Why do I get 404 error when I submit the form?

Using Spring Boot, when I submit a form, it returns 404 error. And it doesn't give me any hint what is missing. Could you tell me what's wrong? This is the HTML code: <!DOCTYPE html> <html ...
0
votes
1answer
19 views

When Intellij Idea show tips “add lib XXXXXX to classpath”

I already add library to pom.xml,but when I press alt + enter the Intellij Idea give tips: add library to classpath. The question is what may trigger this situation and how to avoid this in Intellij ...
0
votes
1answer
19 views

can maven generate jar including source code

I try 2 things which were taught by some tutorials : 1. In maven-source-plugin: <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-...
0
votes
1answer
52 views

java - How to have a resource file

(I am new to java, please be understanding) I am writting a application in java that needs a config file, the config file is a json file, I neeed to open it and read it's contents but no matter how I ...
0
votes
0answers
12 views

Xmlbeans extends generated class

I'm maintaining an ancient project who uses xmlbeans. Previously the XSD classes was generated with ant and now im moving the project to maven. The only problem remaining are the .xsdconfig which ...
-1
votes
1answer
39 views

export Java EE Web Application as JAR

This might be a weird question but I am curious about this: I want to create a Java EE Web Project, that I can package into a JAR file (<packaging>jar</packaging> instead of <packaging&...
-1
votes
1answer
19 views

pom.xml error in maven project using eclipse

I am making a maven project in eclipse for CRUD operations and whenever I am adding jstl dependency version 1.2 the pom.xml is showing error even though the jstl dependency get downloaded and also the ...
0
votes
0answers
17 views

Execution default-resources of goal org.apache.maven.plugins:maven-resources-plugin:2.6:resources failed

I am trying to set up a Dicord-Bot with eclipse and Maven. The Problem is, that I get 2 Errors everytime and nothing seemes to work. I tried everything from this post: Maven:Failed to execute goal ...
0
votes
1answer
19 views

Unresolved dependency hamcrest-core in SBT build

I'm trying to build the Scala hello world example for the Play framework: https://example.lightbend.com/v1/download/play-samples-play-scala-hello-world-tutorial I'm getting this unresolved dependency:...
0
votes
1answer
15 views

Converting one module to standalone Maven project, including a minimal working POM

I would like to distribute the main artifact sources (main Java and tests) of a multi module project as a simple - standalone - Maven project. The easy parts of this can be implemented using the ...
0
votes
2answers
35 views

Spring Boot application with a jar dependency does not run after maven build

I am writing a spring boot application and it needs to fetch records from a ibm notes database. For that I have to use a jar library which is not available as a maven dependency. So I placed the jar ...
0
votes
0answers
11 views

Cannot resolve project dependencies in JBoss Tools projects

I checked out https://github.com/jbosstools/jbosstools-openshift, and issued mvn clean verify, as the guide suggests, and after it downloads things for a while, it fails with this: [INFO] Resolving ...
0
votes
0answers
18 views

How to read pom.xml via Maven API [duplicate]

I would like to parse a Maven pom.xml via a Java app to support an automation project. I want to be able to see the aggregated dependencies from any parent poms and to see the dependencies defined in ...
0
votes
1answer
7 views

com.spotify/dockerfile-maven-plugin: tag failed: path is 'null'

For a multimodule maven project build using com.spotify:dockerfile-maven-plugin on a CI runner, building the docker image with dockerfile:build dockerfile:tag in a previous step, and running mvn clean ...
0
votes
0answers
10 views

Soap client with jaxws-maven-plugin

I can't use the jaxws-maven-plugin life cycle I created a soap client with the jaxws-maven-plugin from org.codehaus.mojo. It is with basic authentication. My question is how do I continue, since ...
0
votes
0answers
17 views

Is there a way to interpolate test resource files with spring?

I have a use case where a 3rd party library reads a property file, secrets.properties. Within secrets.properties the value of the properties are file paths. test.keystore.binary.path = my/local/...
2
votes
1answer
29 views

Maven cannot resolve Jacob dependency using eclipse

I have many maven dependencies in my maven springboot project but the jacob 1.10 dependency is not getting resolved. I have to manually add the jacob.jar file at C:\Users\username.m2\repository\com\...
0
votes
0answers
20 views

NoClassDefFoundError and NoSuchMethodError in Maven Project

I am getting both of these issue in my maven project, the first error I got was this: "java.lang.NoClassDefFoundError: org/apache/commons/logging/LogFactory" I then solved this issue by commenting ...