I’m new on Maven and I am trying to run through command prompt. Command mvn build successfully clean command. but it failed to build compile and test command. this is my cmd screen Please suggest me what should I do? Answer Add two properties to specify the version of Java you want to target. Currently, it’s defaulting to 5 (which
Tag: maven
Spring Boot @Mapper Bean creation issue : Application Failed to start. Error : Consider defining a bean of Type
I am new to spring, when i try to do the mvn clean install of my project this problem appears: Error The problem is that in the MainController there is the import of “UserService”: It is probably a trivial thing but I can not bypass the problem, below I insert “UserService” and the MainStart UserService.java UPDATE : I insert the
Java Spring app can’t run after deploy on Tomcat7
I just deployed (first time ever) my Java app based on Spring. On localhost everything worked fine, but after deploy I can’t send any request. Applications just not running on the server. Logs: Any sugestions what’s wrong? I’ll be more than grateful for any help. EDIT: If it helps – I’ve downloaded sample web project which I just deployed on
How to read a file from maven resources folder in GCP Cloud Function?
My project uses Maven with the default folder structure and when my Google Cloud Function is trying to read a JSON file from the resources directory (src/main/resources), it fails with: File Not Found Exception Below is my code which is standard to read from the classpath resources folder. Any hints what could be wrong? Answer I use a FileReader with
Add maven project as dependency in maven project
I have two Maven projects, both created from the default Maven structure in Eclipse. Project A is dependant on Project B. In order to utilise classes from A in B, I can add B to A’s build path. How can I achieve the same effect using Maven? Currently, I have both of the projects on my file system, but I
ClassNotFoundException for HibernatePersistenceProvider
I have a JSF project which builds perfectly with java 7, but when I try to deploy the WAR in Jboss Application Server, I’m getting the bellow error. The persistance.xml looks like bellow The bellow dependencies are included in the pom The JBoss version is 7.1.1 Final What am I doing wrong here? Answer The issue here was the conflict
Application source bundle doesn’t work when uploaded to AWS Elastic Beanstalk
I’m trying to upload a Java/Spring Boot app that runs in a Linux 2 Coretto 11 environment. Everything worked fine when I uploaded the standalone JAR files, but I started creating an application bundle instead so I could configure the environment, specifically client_max_body_size. It looks like the app is starting but then some error happens with not much info (logs).
405 Method Not Allowed when deploying artifact to Nexus
I am deploying an artifact to a Nexus snapshot repository that allows redeployment, using the maven command: but I have this error: Answer I have never seen a mvn deploy:deploy-file to a nexus/repo/browse URL: browse should not be used for deploying files, only for… browsing them. A typical call would be (Replace repos-snapshots by the name you gave to the
Not able to install Maven in Mac OS
Facing some issue while installing Maven. I have set the path in my Bash profile. Still “mvn -version” command doesn’t work. Downloaded latest version of maven: Added it to my Bash profile: …
Unable to set mvn JAVA_HOME setting
I’ve also tried setting JAVA_HOME manually with: export JAVA_HOME=/Library/Java/JavaVirtualMachines/jdk1.8.0_261.jdk/Contents/Home for some reason mvn insists on using jdk 11. Do you know where it might be overridden? My pom.xml: Answer Your JAVA_HOME exporting command is incorrect. Your bash message also saying the same thing. You used back tick you need to use single quote or double quote Correct statement would be