Questions tagged [maven-jetty-plugin]

maven-jetty-plugin is a Maven plug-in which embeds the Jetty webserver within a Maven build. It is configured in the Maven POM file. It is extremely useful for Rapid Application Development.

You may encounter issues understanding which Jetty Maven Plugin to use due to its recent history of moves between one project owner to another (more recently from codehaus.org to eclipse.org) and its different groupIds (org.mortbay.jetty vs org.eclipse.jetty).

Depending on the version of Jetty to use, you should know that:

  • Jetty up to version 6 is no longer supported by codehaus.org;
  • Jetty from version 7 to 8 are EOL (End Of Life), see Jetty Maven plugin.
  • Jetty version 9 is currently hosted by eclipse.org, see Jetty Maven Plugin

This tag should be used for questions on versions (and group ids) mentioned above. However, it is recommended to use org.eclipse.jetty as latest groupId and well maintained version.

390 questions
8
votes
4 answers

logback logging with maven-jetty-plugin

I want to use logback logging with maven-jetty-plugin. Apparently, the system property logback.configurationFile is read after maven-jetty-plugin is started and has initialized slf4j, so the file ./src/test/resources/logback.xml isn't read by…
Jihed Amine
  • 2,059
  • 19
  • 32
8
votes
4 answers

How to filter resources when using maven jetty plugin?

I have an XML file (urlrewrite.xml) that needs a property placeholder resolved. I enable Maven filtering to achieve this. This works fine for the assembled WAR file.
les2
  • 12,537
  • 16
  • 57
  • 76
8
votes
4 answers

When using maven jetty:run - is it possible to disable the compilation step?

I'm working with Eclipse and Maven and run my application using the Maven jetty plugin. I find it mildly irritating that Maven insists on recompiling my files every time I execute jetty:run. It is sub-optimal, as the files have already been compiled…
Bryan Hunt
  • 3,265
  • 2
  • 22
  • 34
8
votes
1 answer

What is taking long on Jetty startup?

Starting Jetty there's a long delay (8s) before my web application starts loading 13:50:10 [INFO] jetty-9.4.5.v20170502 13:50:18 [INFO] Scanning elapsed time=146ms With debug logging turned on there are two interesting steps Extracting dependent…
Johan Sjöberg
  • 43,692
  • 19
  • 120
  • 139
8
votes
3 answers

Maven jetty plugin - automatic reload using a multi-module project

I am developing a Java web application, using a multi-module maven project. The project setup is the following: pom.xml Main maven project, that includes the following modules: persistence: Entity classes and DAOs business: Service definition and…
Gaste
  • 275
  • 9
  • 14
8
votes
2 answers

Why 2 versions of Jetty Maven plugins?

I set up a new webapp Maven project and wanted to test it with Jetty's Maven plugin. So I issued the console command: mvn jetty:run After defining the pluginGroup in Maven's settings file I ran once again the command. Unfortunately, it failed…
Flueras Bogdan
  • 8,411
  • 8
  • 30
  • 30
7
votes
1 answer

How do you disable jsessionid for Jetty running with the Eclipse Jetty Maven plugin?

We've been experiencing problems with jsessionid and I'm trying to figure out a way to disable this. Would anybody happen to know how you can do this using the org.mortbay.jetty:jetty-maven-plugin:7.x.x? So far, all I've come across are ways to do…
carlspring
  • 27,224
  • 23
  • 101
  • 178
7
votes
2 answers

Maven Jetty plugin daemon element not allowed here

I am trying to configure a project's pom.xml file. I want it to start Jetty server in testing phase. In order to do it I should add "daemon" element to Jetty plugin as I did below, but IntelliJ warns me with "Element daemon is not allowed here." Can…
Arda Güney
  • 135
  • 1
  • 2
  • 7
7
votes
2 answers

How to cancel start or shutdown jetty if WebAppContext fails to start

I am using Maven Jetty Plugin, is there a way to prevent the server from starting up or shutting down (for example with maven-jetty-plugin) if ANY bean fails? Here's an example: 2013-04-22 11:43:59.327:WARN:oejw.WebAppContext:main: Failed startup of…
Gonzalo
  • 1,106
  • 2
  • 12
  • 21
7
votes
2 answers

File locking in Windows with Jetty 9 and Maven plugin

There is a lot of information available on the this subject, but I can't get it to work in Jetty 9. The most recent approach I found was: Jetty Maven Plugin is ignoring custom webdefault.xml I extracted the webdefault.xml from my maven repository.…
Michiel
  • 215
  • 2
  • 10
7
votes
5 answers

jetty-env.xml with DataSource leads to failing WebAppContext on mvn jetty:run

I have a really simple webapp project with maven and jetty that has been working very well until now. But now I need to setup MySQL connection pooling with JNDI as the database connections always time out. First of all here is the relevant content…
ckuepker
  • 422
  • 1
  • 6
  • 18
6
votes
1 answer

JSF welcome file is not recognized

Accessing http://localhost:8080/basicSetup/faces/index.xhtml works, with the output of : Hello World ! Albert Kam but accessing http://localhost:8080/basicSetup shows Hello World ! #{myBean.value} meaning that the welcome file is not rendered…
Albert Gan
  • 16,262
  • 44
  • 125
  • 177
6
votes
1 answer

How to profile a Jetty application in a Netbeans Maven Web Project?

I'm trying to use Jetty in a Netbeans Maven Web Project (instead of Glassfish or Tomcat). I've managed to get running and debugging to work as follows: Add the plugin to pom.xml: org.mortbay.jetty
Gili
  • 76,473
  • 85
  • 341
  • 624
6
votes
0 answers

How to resolve JNDI conflict between Jetty and OpenEJB?

I'm running Jetty (from Maven) with OpenEJB inside. The problem is that they conflict through JNDI context. The problem was explained some time ago by Stephen Connolly with a solution. The solution looks rather outdated (it's for Jetty 6.x, while…
yegor256
  • 93,933
  • 106
  • 409
  • 558
6
votes
1 answer

How to enable CachingWebAppClassLoader in Jetty Maven Plugin?

I'm trying to improve startup performance of a Java web app in development environment. It uses jetty-maven-plugin and mvn jetty:run is used to start the app. I followed instructions at…
phanin
  • 4,987
  • 4
  • 26
  • 43
1 2
3
25 26