[
Date Prev][
Date Next][
Thread Prev][
Thread Next][
Date Index][
Thread Index]
[
List Home]
Re: [jetty-users] JSP using Java 1.7?
|
Look at the example contexts in the distribution.
You'll need to have the following set in your WebAppContext.
<Set name="defaultsDescriptor"><SystemProperty name="jetty.home" default="."/>/etc/webdefault.xml</Set>
--
Developer advice, services and support
from the Jetty & CometD experts.
On Wed, Jul 11, 2012 at 4:54 AM, John English
<john.foreign@xxxxxxxxx> wrote:
On 11/07/2012 03:21, Jan Bartel wrote:
John,
change webdefaults to add this initParam to the jsp servlet:
<init-param>
<param-name>compilerTargetVM</param-name>
<param-value>1.7</param-value>
</init-param>
OK, thanks. I first tried putting this in the webapp's web.xml, so I
have this:
<servlet id="jsp">
<servlet-name>jsp</servlet-name>
<servlet-class>org.apache.jasper.servlet.JspServlet</servlet-class>
<init-param>
<param-name>compilerTargetVM</param-name>
<param-value>1.7</param-value>
</init-param>
<init-param>
<param-name>fork</param-name>
<param-value>false</param-value>
</init-param>
<load-on-startup>0</load-on-startup>
</servlet>
but it didn't work. (I also tried "7" instead of "1.7" since the error
message talks about "-source 1.5" but "-source 7", not "-source 1.7".)
Is this something that can't be done on a per-webapp basis?
Don't forget that if you edit $JETTY_HOME/etc/webdefaults.xml that you
will need to ensure that your webapp is using that file, and not the
one embedded inside jetty-webapp.jar (the default).
Can you tell me how I do that please?
Many thanks,