-
Notifications
You must be signed in to change notification settings - Fork 19
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add plugin goals back to the generated site.
- Loading branch information
Showing
5 changed files
with
157 additions
and
33 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,101 @@ | ||
# How to use | ||
|
||
Add the plugin to the build as shown below: | ||
|
||
```xml | ||
<build> | ||
... | ||
<plugin> | ||
<groupId>io.leonard.maven.plugins</groupId> | ||
<artifactId>jspc-maven-plugin</artifactId> | ||
<version>${ENTER_VERSION_HERE}</version> | ||
<executions> | ||
<execution> | ||
<id>jspc</id> | ||
<goals> | ||
<goal>compile</goal> | ||
</goals> | ||
<configuration> | ||
</configuration> | ||
</execution> | ||
</executions> | ||
</plugin> | ||
... | ||
</build> | ||
``` | ||
|
||
## Overriding Jasper | ||
|
||
To override the Jasper plugin used to compile the JSP files configure the plugin as shown below: | ||
|
||
```xml | ||
<build> | ||
.... | ||
<plugin> | ||
<groupId>io.leonard.maven.plugins</groupId> | ||
<artifactId>jspc-maven-plugin</artifactId> | ||
<version>${ENTER_VERSION_HERE}</version> | ||
<executions> | ||
<execution> | ||
<id>jspc</id> | ||
<goals> | ||
<goal>compile</goal> | ||
</goals> | ||
<configuration /> | ||
</execution> | ||
</executions> | ||
<dependencies> | ||
<dependency> | ||
<groupId>org.apache.tomcat</groupId> | ||
<artifactId>tomcat-jasper</artifactId> | ||
<version>${ENTER_JASPER_VERSION_HERE}</version> | ||
</dependency> | ||
</dependencies> | ||
</plugin> | ||
... | ||
</build> | ||
``` | ||
|
||
## Overriding ECJ | ||
|
||
To override the Eclipse compiler for Java used to compile the Java files that Jasper generates configure the plugin as shown below. | ||
Newer versions of ECJ typically support newer JVMs and bytecode versions. | ||
|
||
```xml | ||
<build> | ||
.... | ||
<plugin> | ||
<groupId>io.leonard.maven.plugins</groupId> | ||
<artifactId>jspc-maven-plugin</artifactId> | ||
<version>${ENTER_VERSION_HERE}</version> | ||
<executions> | ||
<execution> | ||
<id>jspc</id> | ||
<goals> | ||
<goal>compile</goal> | ||
</goals> | ||
<configuration /> | ||
</execution> | ||
</executions> | ||
<dependencies> | ||
<dependency> | ||
<groupId>org.apache.tomcat</groupId> | ||
<artifactId>tomcat-jasper</artifactId> | ||
<version>${ENTER_JASPER_VERSION_HERE}</version> | ||
<exclusions> | ||
<exclusion> | ||
<groupId>org.eclipse.jdt</groupId> | ||
<artifactId>ecj</artifactId> | ||
</exclusion> | ||
</exclusions> | ||
</dependency> | ||
<dependency> | ||
<groupId>org.eclipse.jdt</groupId> | ||
<artifactId>ecj</artifactId> | ||
<version>3.36.0</version> | ||
</dependency> | ||
</dependencies> | ||
</plugin> | ||
... | ||
</build> | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
# jspc-maven-plugin | ||
|
||
This plugin precompiles JSPs. | ||
|
||
It has the following improvements compared to jetty-jspc-maven-plugin: | ||
|
||
* Faster: can be configured to run multi-threaded. For a speed comparison read the blog post below. | ||
* More descriptive error messages: Under Maven 3 this plugin shows a clear indication of what caused the error and which file it is in. | ||
* Not stop at the first error (depends on plugin configuration). | ||
|
||
The compiler used by default in this plugin is Apache Jasper 10, but it can be swapped. | ||
|
||
## Compatibility Matrix | ||
|
||
* 4.X version of jspc-maven-plugin : needs Java >= 11, Jasper only 10.X | ||
* 3.X version of jspc-maven-plugin : needs Java >= 1.8, Jasper only 9.X | ||
* 2.X version of jspc-maven-plugin : needs Java >= 1.7, Jasper only 8.X | ||
* 1.X version of jspc-maven-plugin : needs Java >= 1.5, Jasper only 6.X, 7.X | ||
|
||
## Comparison of precompiler plugins | ||
|
||
[https://tcollignon.github.io/2016/12/04/How-to-compile-JSP-with-Tomcat-and-Maven-faster.html](https://tcollignon.github.io/2016/12/04/How-to-compile-JSP-with-Tomcat-and-Maven-faster.html) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,31 @@ | ||
<project name="jspc maven plugin"> | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<site xmlns="http://maven.apache.org/SITE/2.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | ||
xsi:schemaLocation="http://maven.apache.org/SITE/2.0.0 https://maven.apache.org/xsd/site-2.0.0.xsd" | ||
name="JSPC Maven Plugin"> | ||
|
||
<skin> | ||
<groupId>org.apache.maven.skins</groupId> | ||
<artifactId>maven-fluido-skin</artifactId> | ||
<version>1.6</version> | ||
<version>2.0.0-M8</version> | ||
</skin> | ||
|
||
<body> | ||
<menu ref="reports" /> | ||
<menu name="Overview"> | ||
<item name="Introduction" href="index.html"/> | ||
<item name="How to" href="howto.html"/> | ||
<item name="Goals" href="plugin-info.html"/> | ||
</menu> | ||
<menu ref="reports"/> | ||
</body> | ||
|
||
</project> | ||
<custom> | ||
<fluidoSkin> | ||
<gitHub> | ||
<projectId>leonardehrenfried/jspc-maven-plugin</projectId> | ||
<ribbonOrientation>right</ribbonOrientation> | ||
<ribbonColor>gray</ribbonColor> | ||
</gitHub> | ||
</fluidoSkin> | ||
</custom> | ||
|
||
</site> |