Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Virgo » Precompiled JSPs full of ${...}
Precompiled JSPs full of ${...} [message #642799] Thu, 02 December 2010 18:02 Go to next message
No real name is currently offline No real name
Messages: 15
Registered: June 2010
Junior Member
Is it possible to precompile JSPs inside a PAR and have Virgo see/use them? I'm using maven-jspc-plugin to procompile the files, but it doesn't look like Virgo is seeing/using them.

[Updated on: Fri, 10 June 2011 12:06]

Report message to a moderator

Re: Precompile JSPs inside PAR [message #643682 is a reply to message #642799] Tue, 07 December 2010 20:10 Go to previous messageGo to next message
Violeta Georgieva is currently offline Violeta Georgieva
Messages: 238
Registered: October 2010
Senior Member
Hi,

Can you give more information about the problem.
I assume that you are using the maven way for web application precompilation described on the link below which is based on ant?
http://tomcat.apache.org/tomcat-6.0-doc/jasper-howto.html#We b_Application_Compilation
Did you add the additional generated configurations to the web.xml?

Regards,
Violeta
Re: Precompile JSPs inside PAR [message #645154 is a reply to message #642799] Wed, 15 December 2010 17:36 Go to previous messageGo to next message
No real name is currently offline No real name
Messages: 15
Registered: June 2010
Junior Member
Sorry for not responding sooner - was tied up with another issue.

Actually, this is the bit from our web bundle pom.xml file:

     <plugin>
		<groupId>org.apache.sling</groupId>
		<artifactId>maven-jspc-plugin</artifactId>
		<executions>
			<execution>
				<id>compile-jsp</id>
				<goals>
					<goal>jspc</goal>
				</goals>
			</execution>
		</executions>
		<configuration>
		        <servletPackage>org.apache.jsp</servletPackage>
			<outputDirectory>${project.build.directory}/jspc-plugin-generated</outputDirectory>
		</configuration>
		</plugin>


which was based on the following: http://sling.apache.org/site/jspc.html

Changing the output directory didn't seem to have any difference.

- Paul
Re: Precompile JSPs inside PAR [message #645456 is a reply to message #645154] Fri, 17 December 2010 10:07 Go to previous messageGo to next message
Violeta Georgieva is currently offline Violeta Georgieva
Messages: 238
Registered: October 2010
Senior Member
Hi,

I have no experience with this maven plugin but from the documentation that I checked it seems that its more appropriate to be used with OSGi HTTP service. The OSGi Web Container does not need to register the JSPs as services.

My recommendation here is to use jspc-maven-plugin. This plugin will compile the JSP files and will add the needed additional configurations in the web.xml.
http://mojo.codehaus.org/jspc-maven-plugin/usage.html

Can you try it and tell us the result.

Regards
Violeta

[Updated on: Fri, 17 December 2010 10:09]

Report message to a moderator

Re: Precompile JSPs inside PAR [message #657490 is a reply to message #642799] Thu, 03 March 2011 00:58 Go to previous messageGo to next message
No real name is currently offline No real name
Messages: 15
Registered: June 2010
Junior Member
Hi,

I apologize for the long time since my last update. The project I'm working on has undergone some requirement changes which diverted my attention. I did get a chance to try the 'jspc-maven-plugin' plugin that "Violeta" specified. Similarly to the other plugin, the JSPs did get compiled and web.xml updated. I suspected that the JSP views inside the par were still being re-compiled. I confirmed this by manually deleting the JSP source files from within the WAR inside the PAR file and saw blank page when I accessed the application. We need advice on this as we are heading to production with an application an need the JSP recompile stopped for performance benefits.

Appreciate advice in advance.

- Paul
Re: Precompile JSPs inside PAR [message #657757 is a reply to message #642799] Thu, 03 March 2011 21:43 Go to previous messageGo to next message
No real name is currently offline No real name
Messages: 15
Registered: June 2010
Junior Member
Another update. I was curious if the precompiled files would correctly be used/seen if I deployed them outside of a par (in standard WAR/bundle). I split-up the PAR, and deployed the bundles individually and the precompiled files were now seen/used by Virgo. However, it now doesn't resolve any of the JSTL TLDs so the pages are full of ${...}.
Any suggestions on fixing this one?

Thanks,
Paul
Re: Precompile JSPs inside PAR [message #677822 is a reply to message #642799] Thu, 09 June 2011 13:36 Go to previous messageGo to next message
No real name is currently offline No real name
Messages: 15
Registered: June 2010
Junior Member
bump...
Re: Precompiled JSPs full of ${..} [message #682099 is a reply to message #677822] Fri, 10 June 2011 12:05 Go to previous messageGo to next message
No real name is currently offline No real name
Messages: 15
Registered: June 2010
Junior Member
Another piece of update. We believe that there may be a missing dependency issue which isn't being raised during deployment/run time. Spring tags and displaytag tags work fine and the problem seems to be isolated to JSTL tags.

[Updated on: Fri, 10 June 2011 12:05]

Report message to a moderator

Re: Precompiled JSPs full of ${..} [message #754210 is a reply to message #682099] Tue, 01 November 2011 12:39 Go to previous message
karthik elavan is currently offline karthik elavan
Messages: 70
Registered: August 2011
Location: Chennai
Member
Hi Friends,
Please help me How to create PAR project in virgo server environment. as of now i was create par file just add two project then export par file but did not run.

This is my error report:
--------------------------

[2011-11-01 17:30:10.824] TCP Connection(2)-127.0.0.1 org.eclipse.virgo.medic.eventlog.default ME0003I Dump 'serviceability/dump/2011-11-01-17-30-483' generated
[2011-11-01 17:30:10.835] TCP Connection(2)-127.0.0.1 org.eclipse.virgo.medic.eventlog.default DE0002E Installation of par 'samplemiddletier-par' version '1.0.0' failed. java.lang.UnsupportedOperationException: Cannot open an input stream for '/home/sample/server/virgo-web-server-2.1.0.RELEASE/work/org.eclipse.virgo.kernel.deployer_2.1.0.RELEASE/staging/samplemiddletier-par-1/bundle/samplemiddletier-par-1-samplemiddletierservice-dm/0.0.0/samplemiddletierservice-dm.jar/META-INF/MANIFEST.MF' as it does not exist
at org.eclipse.virgo.kernel.artifact.fs.internal.FileArtifactFSEntry.getInputStream(FileArtifactFSEntry.java:59)
at org.eclipse.virgo.kernel.install.artifact.internal.ServiceScoper.loadManifest(ServiceScoper.java:186)
at org.eclipse.virgo.kernel.install.artifact.internal.ServiceScoper.loadBundleManifests(ServiceScoper.java:175)
at org.eclipse.virgo.kernel.install.artifact.internal.ServiceScoper.doScope(ServiceScoper.java:156)
at org.eclipse.virgo.kernel.install.artifact.internal.ServiceScoper.scope(ServiceScoper.java:88)
at org.eclipse.virgo.kernel.install.artifact.internal.PlanScoper.scope(PlanScoper.java:137)
at org.eclipse.virgo.kernel.install.artifact.internal.StandardPlanInstallArtifact.scope(StandardPlanInstallArtifact.java:175)
at org.eclipse.virgo.kernel.install.pipeline.stage.transform.internal.ScopingTransformer.processScopedPlanInstallArtifact(ScopingTransformer.java:50)
at org.eclipse.virgo.kernel.install.pipeline.stage.transform.internal.ScopedPlanIdentifyingTreeVisitor.visit(ScopedPlanIdentifyingTreeVisitor.java:32)
at org.eclipse.virgo.util.common.ThreadSafeArrayListTree.visit(ThreadSafeArrayListTree.java:165)
at org.eclipse.virgo.kernel.install.pipeline.stage.transform.internal.ScopingTransformer.transform(ScopingTransformer.java:41)
at org.eclipse.virgo.kernel.install.pipeline.stage.transform.internal.TransformationStage.doProcessTree(TransformationStage.java:55)
at org.eclipse.virgo.kernel.install.pipeline.stage.AbstractPipelineStage.process(AbstractPipelineStage.java:41)
at org.eclipse.virgo.kernel.install.pipeline.internal.StandardPipeline.doProcessTree(StandardPipeline.java:62)
at org.eclipse.virgo.kernel.install.pipeline.internal.CompensatingPipeline.doProcessTree(CompensatingPipeline.java:72)
at org.eclipse.virgo.kernel.install.pipeline.stage.AbstractPipelineStage.process(AbstractPipelineStage.java:41)
at org.eclipse.virgo.kernel.install.pipeline.internal.StandardPipeline.doProcessTree(StandardPipeline.java:62)
at org.eclipse.virgo.kernel.install.pipeline.stage.AbstractPipelineStage.process(AbstractPipelineStage.java:41)
at org.eclipse.virgo.kernel.deployer.core.internal.PipelinedApplicationDeployer.driveInstallPipeline(PipelinedApplicationDeployer.java:271)
at org.eclipse.virgo.kernel.deployer.core.internal.PipelinedApplicationDeployer.doInstall(PipelinedApplicationDeployer.java:151)
at org.eclipse.virgo.kernel.deployer.core.internal.PipelinedApplicationDeployer.install(PipelinedApplicationDeployer.java:123)
at org.eclipse.virgo.kernel.deployer.core.internal.PipelinedApplicationDeployer.deploy(PipelinedApplicationDeployer.java:190)
at org.eclipse.virgo.kernel.deployer.management.StandardDeployer.deploy(StandardDeployer.java:52)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at com.sun.jmx.mbeanserver.ConvertingMethod.invokeWithOpenReturn(ConvertingMethod.java:167)
at com.sun.jmx.mbeanserver.MXBeanIntrospector.invokeM2(MXBeanIntrospector.java:96)
at com.sun.jmx.mbeanserver.MXBeanIntrospector.invokeM2(MXBeanIntrospector.java:33)
at com.sun.jmx.mbeanserver.MBeanIntrospector.invokeM(MBeanIntrospector.java:208)
at com.sun.jmx.mbeanserver.PerInterface.invoke(PerInterface.java:120)
at com.sun.jmx.mbeanserver.MBeanSupport.invoke(MBeanSupport.java:262)
at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(DefaultMBeanServerInterceptor.java:836)
at com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(JmxMBeanServer.java:761)
at javax.management.remote.rmi.RMIConnectionImpl.doOperation(RMIConnectionImpl.java:1427)
at javax.management.remote.rmi.RMIConnectionImpl.access$200(RMIConnectionImpl.java:72)
at javax.management.remote.rmi.RMIConnectionImpl$PrivilegedOperation.run(RMIConnectionImpl.java:1265)
at javax.management.remote.rmi.RMIConnectionImpl.doPrivilegedOperation(RMIConnectionImpl.java:1360)
at javax.management.remote.rmi.RMIConnectionImpl.invoke(RMIConnectionImpl.java:788)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:305)
at sun.rmi.transport.Transport$1.run(Transport.java:159)
at java.security.AccessController.doPrivileged(Native Method)
at sun.rmi.transport.Transport.serviceCall(Transport.java:155)
at sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:535)
at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run0(TCPTransport.java:790)
at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:649)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
at java.lang.Thread.run(Thread.java:619)

[2011-11-01 17:30:10.835] TCP Connection(2)-127.0.0.1 o.e.v.k.m.i.deployer.ModelInstallArtifactLifecycleListener Processing install failed event for bundle 'samplemiddletier-par-1-samplemiddletierservice-dm' version '0.0.0'
[2011-11-01 17:30:10.839] TCP Connection(2)-127.0.0.1 org.eclipse.virgo.medic.eventlog.default DE0003E Install failed for bundle 'samplemiddletier-par-1-samplemiddletierservice-dm' version '0.0.0'.
[2011-11-01 17:30:10.839] TCP Connection(2)-127.0.0.1 o.e.v.k.m.i.deployer.ModelInstallArtifactLifecycleListener Processing install failed event for bundle 'samplemiddletier-web' version '0.0.0'
[2011-11-01 17:30:10.843] TCP Connection(2)-127.0.0.1 org.eclipse.virgo.medic.eventlog.default DE0003E Install failed for bundle 'samplemiddletier-web' version '0.0.0'.
[2011-11-01 17:30:10.843] TCP Connection(2)-127.0.0.1 o.e.v.k.m.i.deployer.ModelInstallArtifactLifecycleListener Processing install failed event for par 'samplemiddletier-par' version '1.0.0'
[2011-11-01 17:30:10.847] TCP Connection(2)-127.0.0.1 org.eclipse.virgo.medic.eventlog.default DE0003E Install failed for par 'samplemiddletier-par' version '1.0.0'.
[2011-11-01 17:30:10.850] TCP Connection(2)-127.0.0.1 org.eclipse.virgo.kernel.deployer.management.StandardDeployer Exception filtered from JMX invocation java.lang.UnsupportedOperationException: Cannot open an input stream for '/home/sample/server/virgo-web

[Updated on: Tue, 01 November 2011 12:44]

Report message to a moderator

Previous Topic:Retrieving a Bundle Classpath
Next Topic:Virgo Kernel and Felix
Goto Forum:
  


Current Time: Sun Sep 21 18:10:41 GMT 2014

Powered by FUDForum. Page generated in 0.02945 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software