The following error occurred while loading my telegram bot written in Java (Maven).
-----> Java app detected
-----> Installing JDK 1.8... done
-----> Installing Maven 3.6.2... done
-----> Executing Maven
$ mvn -DskipTests clean dependency:list install
[INFO] Scanning for projects...
[WARNING]
[WARNING] Some problems were encountered while building the effective model for org.example:GesualdoBot:jar:1.0-SNAPSHOT
[WARNING] 'build.plugins.plugin.version' for org.apache.maven.plugins:maven-compiler-plugin is missing. # line 12, column 21
[WARNING]
[WARNING] It is highly recommended to fix these problems because they threaten the stability of your build.
[WARNING]
[WARNING] For this reason, future Maven versions might no longer support building such malformed projects.
[WARNING]
[INFO]
[INFO] ----------------------< org.example:GesualdoBot >-----------------------
[INFO] Building GesualdoBot 1.0-SNAPSHOT
[INFO] --------------------------------[ jar ]---------------------------------
[INFO]
[INFO] --- maven-clean-plugin:2.5:clean (default-clean) # GesualdoBot ---
[INFO] Deleting /tmp/build_86eafd8379099658ed8301a1e005ecb8/target
[INFO]
[INFO] --- maven-dependency-plugin:2.8:list (default-cli) # GesualdoBot ---
[INFO]
[INFO] --- maven-resources-plugin:2.6:resources (default-resources) # GesualdoBot ---
[WARNING] Using platform encoding (UTF-8 actually) to copy filtered resources, i.e. build is platform dependent!
[INFO] skip non existing resourceDirectory /tmp/build_86eafd8379099658ed8301a1e005ecb8/src/main/resources
[INFO]
[INFO] --- maven-compiler-plugin:3.1:compile (default-compile) # GesualdoBot ---
[INFO] Changes detected - recompiling the module!
[WARNING] File encoding has not been set, using platform encoding UTF-8, i.e. build is platform dependent!
[INFO] Compiling 4 source files to /tmp/build_86eafd8379099658ed8301a1e005ecb8/target/classes
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 2.370 s
[INFO] Finished at: 2020-05-27T18:45:46Z
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.1:compile (default-compile) on project GesualdoBot: Compilation failure -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException
! ERROR: Failed to build app with Maven
We're sorry this build is failing! If you can't find the issue in application code,
please submit a ticket so we can help: https://help.heroku.com/
! Push rejected, failed to compile Java app.
! Push failed
Can anyone tell me how to solve the problem? I think the first warning is detected because in my pom.xml file I have not specified a version for maven-compiler-plugin; does anyone know how do i see the current version i am using?
Related
--- maven-clean-plugin:3.1.0:clean (default-clean) # Homework5 ---
[INFO]
[INFO] --- maven-resources-plugin:3.0.2:resources (default-resources) # Homework5 ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] skip non existing resourceDirectory /Users/vintage/eclipse-workspace/Homework5/src/main/resources
[INFO]
[INFO] --- maven-compiler-plugin:3.8.0:compile (default-compile) # Homework5 ---
[INFO] Changes detected - recompiling the module!
[INFO] Compiling 3 source files to /Users/vintage/eclipse-workspace/Homework5/target/classes
[INFO] -------------------------------------------------------------
[ERROR] COMPILATION ERROR :
[INFO] -------------------------------------------------------------
[ERROR] No compiler is provided in this environment. Perhaps you are running on a JRE rather than a JDK?
[INFO] 1 error
[INFO] -------------------------------------------------------------
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 2.281 s
[INFO] Finished at: 2022-03-19T00:14:48-04:00
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.8.0:compile (default-compile) on project Homework5: Compilation failure
[ERROR] No compiler is provided in this environment. Perhaps you are running on a JRE rather than a JDK?
[ERROR] -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException
Unable to run my code for a homework assignment. It says that " No compiler is provided in this environment. Perhaps you are running on a JRE rather than a JDK" but I'm unsure on how to fix that issue.
Running Mac OSX Monterey 12.2
Eclipse IDE 2022-03
Tomcat Apache 9
I switched from windows to MacBook Air which is having M1 chip. I installed java and added the environment variables in .zprofile as follows
export JAVA_HOME=$(/usr/libexec/java_home)
export ANDROID_HOME=${HOME}/Library/Android/sdk
export PATH="${JAVA_HOME}/bin:${ANDROID_HOME}/tools:${ANDROID_HOME}/platform-tools:${PATH}"
But when I run echo $JAVA_HOME, I see the output as /Library/Internet Plug-Ins/JavaAppletPlugin.plugin/Contents/Home instead of /Library/Java/JavaVirtualMachines/jdk1.8.0_311.jdk/Contents/Home. I am not able to check if variable is set to JDK or JRE.
From Intellij, when I run mvn test clean, error is shown as,
[INFO] Scanning for projects...
[INFO]
[INFO] ---------------------< org.example:SampleProject >----------------------
[INFO] Building SampleProject 1.0-SNAPSHOT
[INFO] --------------------------------[ jar ]---------------------------------
[INFO]
[INFO] --- maven-resources-plugin:2.6:resources (default-resources) # SampleProject ---
[WARNING] Using platform encoding (US-ASCII actually) to copy filtered resources, i.e. build is platform dependent!
[INFO] Copying 0 resource
[INFO]
[INFO] --- maven-compiler-plugin:3.1:compile (default-compile) # SampleProject ---
[INFO] Nothing to compile - all classes are up to date
[INFO]
[INFO] --- maven-resources-plugin:2.6:testResources (default-testResources) # SampleProject ---
[WARNING] Using platform encoding (US-ASCII actually) to copy filtered resources, i.e. build is platform dependent!
[INFO] skip non existing resourceDirectory /Users/moengage/IdeaProjects/SampleProject/src/test/resources
[INFO]
[INFO] --- maven-compiler-plugin:3.1:testCompile (default-testCompile) # SampleProject ---
[INFO] Changes detected - recompiling the module!
[WARNING] File encoding has not been set, using platform encoding US-ASCII, i.e. build is platform dependent!
[INFO] Compiling 1 source file to /Users/moengage/IdeaProjects/SampleProject/target/test-classes
[INFO] -------------------------------------------------------------
[ERROR] COMPILATION ERROR :
[INFO] -------------------------------------------------------------
[ERROR] No compiler is provided in this environment. Perhaps you are running on a JRE rather than a JDK?
[INFO] 1 error
[INFO] -------------------------------------------------------------
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 1.392 s
[INFO] Finished at: 2021-11-18T13:20:33+05:30
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.1:testCompile (default-testCompile) on project SampleProject: Compilation failure
[ERROR] No compiler is provided in this environment. Perhaps you are running on a JRE rather than a JDK?
[ERROR]
[ERROR] -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
Note: I checked others' questions as well and none of them were helpful. Can someone please help me in resolving this.
I am trying to execute the maven project from java main
Please refer the code below.
public static void main(String args[]) throws MavenInvocationException
{
InvocationRequest request = new DefaultInvocationRequest();
request.setPomFile( new File( "C:\\Users\\DPKA764\\git\\be.axa.testautomation.phoenixiard\\pom.xml" ) );
request.setGoals( Arrays.asList( "clean", "install" ) );
Invoker invoker = new DefaultInvoker();
invoker.setMavenHome(new File("C:\\J\\apache-maven-3.5.3"));
System.out.println(""+invoker.getMavenHome());
invoker.execute( request );
System.out.println("suites are completed");
}
and when i execute the code as 'Java Application' it is throwing the following error.
[WARN] Maven will be executed in interactive mode, but no input stream has been configured for this MavenInvoker instance.
[INFO] Scanning for projects...
[INFO]
[INFO] -------------------< be.axa.PhoenixIARD:PhoenixIARD >-------------------
[INFO] Building git-training 1.0-SNAPSHOT
[INFO] --------------------------------[ jar ]---------------------------------
[INFO]
[INFO] --- maven-clean-plugin:2.6.1:clean (default-clean) # PhoenixIARD ---
[INFO] Deleting C:\Users\DPKA764\git\be.axa.testautomation.phoenixiard\target
[INFO]
[INFO] --- properties-maven-plugin:1.0.0:read-project-properties (default) # PhoenixIARD ---
[INFO]
[INFO] --- maven-resources-plugin:2.6:resources (default-resources) # PhoenixIARD ---
[WARNING] Using platform encoding (Cp1252 actually) to copy filtered resources, i.e. build is platform dependent!
[INFO] skip non existing resourceDirectory C:\Users\DPKA764\git\be.axa.testautomation.phoenixiard\src\main\resources
[INFO]
[INFO] --- maven-compiler-plugin:2.3.2:compile (default-compile) # PhoenixIARD ---
[INFO] Compiling 57 source files to C:\Users\DPKA764\git\be.axa.testautomation.phoenixiard\target\classes
[INFO] -------------------------------------------------------------
[ERROR] COMPILATION ERROR :
[INFO] -------------------------------------------------------------
[ERROR] Unable to locate the Javac Compiler in:
C:\Program Files\Java\jre7\..\lib\tools.jar
Please ensure you are using JDK 1.4 or above and
not a JRE (the com.sun.tools.javac.Main class is required).
In most cases you can change the location of your Java
installation by setting the JAVA_HOME environment variable.
[INFO] 1 error
[INFO] -------------------------------------------------------------
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 7.885 s
[INFO] Finished at: 2020-02-03T18:24:34+05:30
[INFO] ------------------------------------------------------------------------
[WARNING] The requested profile "metadata" could not be activated because it does not exist.
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:2.3.2:compile (default-compile) on project PhoenixIARD: Compilation failure
[ERROR] Unable to locate the Javac Compiler in:
[ERROR] C:\Program Files\Java\jre7\..\lib\tools.jar
[ERROR] Please ensure you are using JDK 1.4 or above and
[ERROR] not a JRE (the com.sun.tools.javac.Main class is required).
[ERROR] In most cases you can change the location of your Java
[ERROR] installation by setting the JAVA_HOME environment variable.
[ERROR]
[ERROR] -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException
but when i execute the project directly as Maven Test It will run fine.Please suggest any changes i have to do
I am trying to build the Californium repository https://github.com/eclipse/californium using maven. Typing "mvn clean install" gives the following output:
[INFO] Scanning for projects...
[WARNING]
[WARNING] Some problems were encountered while building the effective model for org.eclipse.californium:californium-core:jar:1.0.0-SNAPSHOT
[WARNING] 'build.plugins.plugin.version' for org.apache.maven.plugins:maven-surefire-plugin is missing. # line 29, column 18
[WARNING]
[WARNING] It is highly recommended to fix these problems because they threaten the stability of your build.
[WARNING]
[WARNING] For this reason, future Maven versions might no longer support building such malformed projects.
[WARNING]
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Build Order:
[INFO]
[INFO] Californium (Cf) Root
[INFO] Californium (Cf) Core
[INFO] Californium (Cf) Proxy
[INFO] Californium (Cf) OSGi Bundle
[INFO] Cf-PlugtestClient
[INFO] Cf-PlugtestChecker
[INFO] Cf-PlugtestServer
[INFO] Cf-HelloWorldClient
[INFO] Cf-HelloWorldServer
[INFO] Cf-SecureServer
[INFO] Cf-ExampleCrossProxy
[INFO] Cf Benchmark Server
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building Californium (Cf) Root 1.0.0-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[WARNING] The POM for org.eclipse.californium:element-connector:jar:1.0-SNAPSHOT is missing, no dependency information available
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Summary:
[INFO]
[INFO] Californium (Cf) Root ............................. FAILURE [0.097s]
[INFO] Californium (Cf) Core ............................. SKIPPED
[INFO] Californium (Cf) Proxy ............................ SKIPPED
[INFO] Californium (Cf) OSGi Bundle ...................... SKIPPED
[INFO] Cf-PlugtestClient ................................. SKIPPED
[INFO] Cf-PlugtestChecker ................................ SKIPPED
[INFO] Cf-PlugtestServer ................................. SKIPPED
[INFO] Cf-HelloWorldClient ............................... SKIPPED
[INFO] Cf-HelloWorldServer ............................... SKIPPED
[INFO] Cf-SecureServer ................................... SKIPPED
[INFO] Cf-ExampleCrossProxy .............................. SKIPPED
[INFO] Cf Benchmark Server ............................... SKIPPED
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 0.894s
[INFO] Finished at: Thu Jun 26 18:29:52 CEST 2014
[INFO] Final Memory: 6M/109M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal on project root: Could not resolve dependencies for project org.eclipse.californium:root:pom:1.0.0-SNAPSHOT: Could not find artifact org.eclipse.californium:element-connector:jar:1.0-SNAPSHOT -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/DependencyResolutionException
I tried different things but still Idon't know how to fix this errors and go on with my work. Can anyone help me?
MORE INFO:
Downloding and installing (mvn clean install) Californium Element Connector https://github.com/eclipse/californium.element-connector.git brings the build of Californium a little farther, but there are still some dependencies missing. I think that one of these is californium Scandium, but after I downloaded it, I found out that it also has some building problems...
Actually, all I want to use is the repo caled californium.tools (https://github.com/eclipse/californium.tools), which is based on Californium. I checked the pom.xml of californium.tools, and it already includes the required dependencies. However,when I build, I get the following errors:
[INFO] Scanning for projects...
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Build Order:
[INFO]
[INFO] Californium (Cf) Tools
[INFO] Cf-ConsoleClient
[INFO] Cf-GUIClient
[INFO] Cf-CoAPBench
[INFO] Cf-ExampleServer
[INFO] Cf-ResourceDirectory
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building Californium (Cf) Tools 1.0.0-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO] --- maven-clean-plugin:2.3:clean (default-clean) # tools ---
[INFO] Deleting file set: /home/ceccog/californium.tools/target (included: [**], excluded: [])
[INFO]
[INFO] --- maven-jar-plugin:2.4:test-jar (default) # tools ---
[WARNING] JAR will be empty - no content was marked for inclusion!
[INFO] Building jar: /home/ceccog/californium.tools/target/tools-1.0.0-SNAPSHOT-tests.jar
[INFO]
[INFO] >>> maven-source-plugin:2.2.1:jar (attach-sources) # tools >>>
[INFO]
[INFO] <<< maven-source-plugin:2.2.1:jar (attach-sources) # tools <<<
[INFO]
[INFO] --- maven-source-plugin:2.2.1:jar (attach-sources) # tools ---
[INFO]
[INFO] --- maven-install-plugin:2.3:install (default-install) # tools ---
[INFO] Installing /home/ceccog/californium.tools/pom.xml to /home/ceccog/.m2/repository/org/eclipse/californium/tools/1.0.0-SNAPSHOT/tools-1.0.0-SNAPSHOT.pom
[INFO] Installing /home/ceccog/californium.tools/target/tools-1.0.0-SNAPSHOT-tests.jar to /home/ceccog/.m2/repository/org/eclipse/californium/tools/1.0.0-SNAPSHOT/tools-1.0.0-SNAPSHOT-tests.jar
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building Cf-ConsoleClient 1.0.0-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[WARNING] The POM for org.eclipse.californium:scandium:jar:1.0.0-SNAPSHOT is missing, no dependency information available
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Summary:
[INFO]
[INFO] Californium (Cf) Tools ............................ SUCCESS [0.886s]
[INFO] Cf-ConsoleClient .................................. FAILURE [0.078s]
[INFO] Cf-GUIClient ...................................... SKIPPED
[INFO] Cf-CoAPBench ...................................... SKIPPED
[INFO] Cf-ExampleServer .................................. SKIPPED
[INFO] Cf-ResourceDirectory .............................. SKIPPED
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 1.161s
[INFO] Finished at: Wed Jul 02 11:42:57 CEST 2014
[INFO] Final Memory: 7M/111M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal on project cf-client: Could not resolve dependencies for project org.eclipse.californium:cf-client:jar:1.0.0-SNAPSHOT: Could not find artifact org.eclipse.californium:scandium:jar:1.0.0-SNAPSHOT -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/DependencyResolutionException
[ERROR]
[ERROR] After correcting the problems, you can resume the build with the command
[ERROR] mvn <goals> -rf :cf-client
EDIT: it looks like the maven repositories are online now and the bug in cf-secure has been fixed. So only step 4 is required to install the californium tools.
The repositories mentioned in README.md do not seem to be online yet. Therefore maven can not resolve the dependencies automatically. The trick is to build and install the maven artifacts directly from source in the appropriate order.
So in order to get californium.tools working:
install org.eclipse.californium:element-connector
git clone https://github.com/eclipse/californium.element-connector.git
cd californium.element-connector
mvn clean install
install org.eclipse.californium:scandium
git clone https://github.com/eclipse/californium.scandium.git
cd californium.scandium
mvn clean install
install org.eclipse.californium:californium-core
git clone https://github.com/eclipse/californium.git
cd californium
mvn -pl :californium-core -am clean install
Note that we are only building the californium-core submodule (with the -pl :californium-core -am flag), since there is a bug in cf-secure which causes the build to fail.
build the Californium tools
git clone https://github.com/eclipse/californium.tools.git
cd californium.tools
mvn -pl :cf-browser,:cf-coapbench,:cf-rd,:cf-server -am clean install
We need to exclude cf-client since it has a bug which makes the build fail.
To run any of the tools, just cd californium.tools/run and java -jar ... the appropriate jar.
Sorry, the project was recently created at eclipse.
Hudson is populating the maven repository now.
I'm trying to deploy a simple JSF app onto a Tomcat 8 server on my local machine. When I run mvn tomcat:deploy, I get the following feedback:
C:\_workspace\portfolio>mvn tomcat:deploy
[INFO] Scanning for projects...
[WARNING]
[WARNING] Some problems were encountered while building the effective model for com.italic:portfolio:war:0.0.1-SNAPSHOT
[WARNING] 'build.plugins.plugin.version' for org.codehaus.mojo:tomcat-maven-plugin is missing. # line 38, column 12
[WARNING]
[WARNING] It is highly recommended to fix these problems because they threaten the stability of your build.
[WARNING]
[WARNING] For this reason, future Maven versions might no longer support building such malformed projects.
[WARNING]
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building Portfolio 0.0.1-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO] >>> tomcat-maven-plugin:1.1:deploy (default-cli) # portfolio >>>
[INFO]
[INFO] --- maven-resources-plugin:2.6:resources (default-resources) # portfolio ---
[WARNING] Using platform encoding (Cp1252 actually) to copy filtered resources, i.e. build is platform dependent!
[INFO] Copying 1 resource
[INFO]
[INFO] --- maven-compiler-plugin:3.1:compile (default-compile) # portfolio ---
[INFO] Nothing to compile - all classes are up to date
[INFO]
[INFO] --- maven-resources-plugin:2.6:testResources (default-testResources) # portfolio ---
[WARNING] Using platform encoding (Cp1252 actually) to copy filtered resources, i.e. build is platform dependent!
[INFO] Copying 0 resource
[INFO]
[INFO] --- maven-compiler-plugin:3.1:testCompile (default-testCompile) # portfolio ---
[INFO] Nothing to compile - all classes are up to date
[INFO]
[INFO] --- maven-surefire-plugin:2.12.4:test (default-test) # portfolio ---
[INFO]
[INFO] --- maven-war-plugin:2.2:war (default-war) # portfolio ---
[INFO] Packaging webapp
[INFO] Assembling webapp [portfolio] in [C:\_workspace\portfolio\target\portfolio-0.0.1-SNAPSHOT]
[INFO] Processing war project
[INFO] Copying webapp resources [C:\_workspace\portfolio\src\main\webapp]
[INFO] Webapp assembled in [184 msecs]
[INFO] Building war: C:\_workspace\portfolio\target\portfolio-0.0.1-SNAPSHOT.war
[INFO] WEB-INF\web.xml already added, skipping
[INFO]
[INFO] <<< tomcat-maven-plugin:1.1:deploy (default-cli) # portfolio <<<
[INFO]
[INFO] --- tomcat-maven-plugin:1.1:deploy (default-cli) # portfolio ---
[INFO] Deploying war to http://localhost:8080/portfolio
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 3.499s
[INFO] Finished at: Sat Feb 08 19:10:27 PST 2014
[INFO] Final Memory: 21M/180M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.codehaus.mojo:tomcat-maven-plugin:1.1:deploy (default-cli) on project portfolio: Cannot invoke Tomcat manager: Server returne
d HTTP response code: 405 for URL: http://localhost:8080/manager/text/deploy?path=%2Fportfolio&war= -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException
C:\_workspace\portfolio>
Apparently Maven is finding the server, but is unable to deploy onto it. I looked around the interwebs and found that this could be due to maven trying to use a "PUT" command. However, after looking at the following answer, I added this code to my tomcat web.xml in the default servlet:
<init-param>
<param-name>readonly</param-name>
<param-value>false</param-value>
</init-param>
However, it doesn't appear to have had any effect. Do you have any further advice on what I can do to get this working?
I'm using Maven 3.1.1 and Tomcat 8.0.1.
It turns out that this was a silly mistake- the user that I had maven using had "manager-gui" privileges instead of "manager-script." Resolving this issue fixed my problem.