Bug 62366 - Enable use of tomcat 9 for precompiling jsp files (jspc-compiler-tomcat8)
Summary: Enable use of tomcat 9 for precompiling jsp files (jspc-compiler-tomcat8)
Status: RESOLVED FIXED
Alias: None
Product: Tomcat 9
Classification: Unclassified
Component: Jasper (show other bugs)
Version: 9.0.8
Hardware: All All
: P2 enhancement (vote)
Target Milestone: -----
Assignee: Tomcat Developers Mailing List
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-05-10 09:35 UTC by Pavel Cibulka
Modified: 2018-05-14 15:05 UTC (History)
0 users



Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Pavel Cibulka 2018-05-10 09:35:51 UTC
In 45931 function setTrimSpaces(boolean trimSpaces) has been replaced with setTrimSpaces(TrimSpacesOption trimSpaces). This breaks org.jasig.mojo.jspc jspc-compiler-tomcat8 maven plugin. This plugin is used for precompiling jsp files. It would be nice, if this plugin would work with Tomcat 9.

It can be fixed be returning this function:

    public void setTrimSpaces(boolean trimSpaces) {
        if (trimSpaces) {
            setTrimSpaces(TrimSpacesOption.TRUE);
        } else {
            setTrimSpaces(TrimSpacesOption.FALSE);
        }
    }
Comment 1 Pavel Cibulka 2018-05-10 09:37:33 UTC
Function should be in org.apache.jasper.JspC.
Comment 2 Mark Thomas 2018-05-14 15:04:56 UTC
Since TrimSpaces is the only API change between 8.5.x and 9.0.x (and the old  version isn't deprectaed in 8.5.x) I can see the merit in this proposal.

Patch applied as suggested to 9.0.x for 9.0.9 onwards.

Many thanks.