Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Web Tools Project (WTP) » problems with web project on wtp
problems with web project on wtp [message #210979] Tue, 25 March 2008 21:44 Go to next message
Tobias F is currently offline Tobias F
Messages: 35
Registered: July 2009
Member
Hello,
I use the wtp 3.0.0.v200712121937 with eclipse 3.4M5 from the Ganymede
Discovery Site and have some problems.

1. I use JSF and Trinidad and in my jsp page I get for every bean the
warning that it cannot be resolved. Code completition is missing too. And
for the action attribute I get the warning 'The action value does not match
a navigation case outcome.'. Looks like the information from
faces-context.xml is missing, can I define the location somewhere?
faces-context is in WebRoot/WEB-INF (Eclipse standard is WebContent). Same
code with Eclipse 3.3.2 and wtp 2.0.2 works fine. Also code completition for
tags, message bundles and defined vars for a table work great in 3.4
(defined vars didn't work in 3.3.2).
I added jsf 1.2 to the project facades with serverside (don't know what it
was, but no custom libs) as I did with eclipse 3.3.2. Did I miss anything?
Don't remember more from the old setup.


2. I installed Tomcat 6 runtime and added a server. When I start the server
with the application I get following error.

INFO: Starting Servlet Engine: Apache Tomcat/6.0.14
25.03.2008 21:26:51 org.apache.catalina.core.StandardContext listenerStart
SCHWERWIEGEND: Error configuring application listener of class
mypackage.....listener.ApplicationListener
java.lang.ClassNotFoundException:
mypackage......listener.ApplicationListener
at
org.apache.catalina.loader.WebappClassLoader.loadClass(Webap pClassLoader.java:1358)
at
org.apache.catalina.loader.WebappClassLoader.loadClass(Webap pClassLoader.java:1204)
at
org.apache.catalina.core.StandardContext.listenerStart(Stand ardContext.java:3773)
at
org.apache.catalina.core.StandardContext.start(StandardConte xt.java:4337)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.j ava:1045)
at org.apache.catalina.core.StandardHost.start(StandardHost.jav a:719)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.j ava:1045)
at org.apache.catalina.core.StandardEngine.start(StandardEngine .java:443)
at org.apache.catalina.core.StandardService.start(StandardServi ce.java:516)
at org.apache.catalina.core.StandardServer.start(StandardServer .java:710)
at org.apache.catalina.startup.Catalina.start(Catalina.java:566 )
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:2 88)
at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:41 3)
25.03.2008 21:26:51 org.apache.catalina.core.StandardContext listenerStart
SCHWERWIEGEND: Skipped installing application listeners due to previous
error(s)
25.03.2008 21:26:51 org.apache.catalina.core.StandardContext start
SCHWERWIEGEND: Error listenerStart
25.03.2008 21:26:51 org.apache.catalina.core.StandardContext start
SCHWERWIEGEND: Context [/myapp] startup failed due to previous errors
25.03.2008 21:26:51 org.apache.coyote.http11.Http11Protocol start

This listener is defined in web.xml
<listener>
<listener-class>mypackage......listener.ApplicationListener </listener-class>
</listener>
and implements ServletContextListener

Server runs also fine with Eclipse 3.3.2 and wtp 2.0.2

Thanks, Tobias
Re: problems with web project on wtp [message #211097 is a reply to message #210979] Wed, 26 March 2008 15:26 Go to previous messageGo to next message
Gerry Kessler is currently offline Gerry Kessler
Messages: 125
Registered: July 2009
Senior Member
Problem 1: Support for Trinidad tags within WTP has come fairly recently.
You may wish to try a recent WTP I-Build available from
http://download.eclipse.org/webtools/downloads/ to see if your problems
are resolved.

In general when you are dealing with pre-release Eclipse software, it is
best to ensure that you are using the same pre-requisite plugins used at
the time of that build. The update sites will only be accurate for
released software.

Problem 2: Sorry, but I can't help you on this one. This question would
be better answered on the eclipse.webtools newsgroup or an Apache Tomcat
forum.

Regards,
Gerry Kessler
WTP JSF Tools Team
Re: problems with web project on wtp [message #211170 is a reply to message #211097] Wed, 26 March 2008 19:48 Go to previous messageGo to next message
Tobias F is currently offline Tobias F
Messages: 35
Registered: July 2009
Member
Hello,
thanks for your info.
Prolem 1 is solved in
http://download.eclipse.org/webtools/downloads/drops/R3.0/I- I20080321174820-20080321174820/
and the required packages.
Code completition for jsf action attribute and css is realy nice. It works
also for the var attribut in h:dataTable but not in tr:table.

Problem 2 is still open. So if everyone in eclipse.webtools knows the answer
;)

Tobias


"Gerry Kessler" <gerry.kessler@oracle.com> schrieb im Newsbeitrag
news:eba53b6f51bbf1098b1735fd073f44ef$1@www.eclipse.org...
> Problem 1: Support for Trinidad tags within WTP has come fairly recently.
> You may wish to try a recent WTP I-Build available from
> http://download.eclipse.org/webtools/downloads/ to see if your problems
> are resolved.
> In general when you are dealing with pre-release Eclipse software, it is
> best to ensure that you are using the same pre-requisite plugins used at
> the time of that build. The update sites will only be accurate for
> released software.
>
> Problem 2: Sorry, but I can't help you on this one. This question would
> be better answered on the eclipse.webtools newsgroup or an Apache Tomcat
> forum.
>
> Regards,
> Gerry Kessler
> WTP JSF Tools Team
>
Re: problems with web project on wtp [message #211209 is a reply to message #210979] Fri, 28 March 2008 00:30 Go to previous messageGo to next message
Cameron Bateman is currently offline Cameron Bateman
Messages: 480
Registered: July 2009
Senior Member
> mypackage......listener.ApplicationListener

Is the ApplicationListener class being deployed into Tomcat's classpath?
Where is it defined? In your project's source or in a jar? If it's in a
jar, you need to make sure that the jar is being deployed.

If it's source, the Tomcat publish/launch is sometimes bad at picking up
changes (although not normally with Java files). Try right clicking the
server in the Server view, stop it, clean, clean tomcat working directory
and then restart.


--Cam
Re: problems with web project on wtp [message #211337 is a reply to message #211209] Sat, 29 March 2008 18:30 Go to previous messageGo to next message
Tobias F is currently offline Tobias F
Messages: 35
Registered: July 2009
Member
The ApplicationListener is in my source code.
Clean on the Tomcat as well as clean on the code does not work. I can find
the .class file in the eclipse tomcat working directory
..metadata\.plugins\org.eclipse.wst.server.core\tmp0\wtpweba pps ... within my
package.

Tobias

"Cameron Bateman" <cameron.bateman@oracle.com> schrieb im Newsbeitrag
news:1280b0637d52bf6d82c3794e547dcf0f$1@www.eclipse.org...
>> mypackage......listener.ApplicationListener
>
> Is the ApplicationListener class being deployed into Tomcat's classpath?
> Where is it defined? In your project's source or in a jar? If it's in a
> jar, you need to make sure that the jar is being deployed.
>
> If it's source, the Tomcat publish/launch is sometimes bad at picking up
> changes (although not normally with Java files). Try right clicking the
> server in the Server view, stop it, clean, clean tomcat working directory
> and then restart.
>
>
> --Cam
>
>
Re: problems with web project on wtp [message #211367 is a reply to message #211337] Sun, 30 March 2008 19:39 Go to previous messageGo to next message
Cameron Bateman is currently offline Cameron Bateman
Messages: 480
Registered: July 2009
Senior Member
> The ApplicationListener is in my source code.
> Clean on the Tomcat as well as clean on the code does not work. I can find
> the .class file in the eclipse tomcat working directory
> ..metadata.pluginsorg.eclipse.wst.server.coretmp0wtpwebapps ... within my
> package.

Hmm, is it possible that your ApplicationListener implements, extends or
uses any classes that may not be in the classpath?


--Cam
Re: problems with web project on wtp [message #211374 is a reply to message #211367] Mon, 31 March 2008 20:16 Go to previous messageGo to next message
Tobias F is currently offline Tobias F
Messages: 35
Registered: July 2009
Member
The ApplicationListener implements javax.servlet.ServletContextListener
which is found in servlet-api.jar and this is located in $CATALINA_HOME$/lib
This tomcat is configured as runtime environment and is included under
project/java build path/libraries


Tobias

"Cameron Bateman" <cameron.bateman@oracle.com> schrieb im Newsbeitrag
news:c9ce9f5a214994e380ed44d82e609c56$1@www.eclipse.org...
>> The ApplicationListener is in my source code.
>> Clean on the Tomcat as well as clean on the code does not work. I can
>> find the .class file in the eclipse tomcat working directory
>> ..metadata.pluginsorg.eclipse.wst.server.coretmp0wtpwebapps ... within my
>> package.
>
> Hmm, is it possible that your ApplicationListener implements, extends or
> uses any classes that may not be in the classpath?
>
>
> --Cam
>
>
Re: problems with web project on wtp [message #211426 is a reply to message #211374] Tue, 01 April 2008 13:49 Go to previous messageGo to next message
Larry Isaacs is currently offline Larry Isaacs
Messages: 1305
Registered: July 2009
Senior Member
There isn't enough detail to make much more than a guess as to what is
going wrong. Given that you have abbreviated the full listener class
name, perhaps its long enough to have a hard to see typo in the intended
package or in the web.xml so they don't actually match. If you happen
to be on Windows, it may be that your workspace path, the ".metadata/.."
path, and the path of your class in the webapp combine to form a path
that is too long. I think the limit is about 256 characters. If this
is a possibility, make a copy of your listener class in a package named
"test" and see if it still fails to load. Note that with the shortened
package, it could still just be a typo.

Cheers,
Larry

Tobias wrote:
> The ApplicationListener implements javax.servlet.ServletContextListener
> which is found in servlet-api.jar and this is located in $CATALINA_HOME$/lib
> This tomcat is configured as runtime environment and is included under
> project/java build path/libraries
>
>
> Tobias
>
> "Cameron Bateman" <cameron.bateman@oracle.com> schrieb im Newsbeitrag
> news:c9ce9f5a214994e380ed44d82e609c56$1@www.eclipse.org...
>>> The ApplicationListener is in my source code.
>>> Clean on the Tomcat as well as clean on the code does not work. I can
>>> find the .class file in the eclipse tomcat working directory
>>> ..metadata.pluginsorg.eclipse.wst.server.coretmp0wtpwebapps ... within my
>>> package.
>> Hmm, is it possible that your ApplicationListener implements, extends or
>> uses any classes that may not be in the classpath?
>>
>>
>> --Cam
>>
>>
>
>
Re: problems with web project on wtp [message #211586 is a reply to message #211426] Wed, 02 April 2008 19:44 Go to previous messageGo to next message
Tobias F is currently offline Tobias F
Messages: 35
Registered: July 2009
Member
Hi Larry,
the same project works with Eclipse 3.3.2. So a typo is imposible. Its in a
different workspace because I checked it out from svn but its the same
web.xml, faces-config and so on.
The workspace for 3.4 was the standard path on Windows. Its 208 characters
long with the listener class. I copied the workspace direct on my hdd and
the path was 177 characters long. Still doesn't work.

I moved the listener with following error:
java.lang.ClassNotFoundException: de.ApplicationListener
So its not the path and not a typo.

Tobias

"Larry Isaacs" <Larry.Isaacs@sas.com> schrieb im Newsbeitrag
news:fsteh4$ua$1@build.eclipse.org...
> There isn't enough detail to make much more than a guess as to what is
> going wrong. Given that you have abbreviated the full listener class
> name, perhaps its long enough to have a hard to see typo in the intended
> package or in the web.xml so they don't actually match. If you happen to
> be on Windows, it may be that your workspace path, the ".metadata/.."
> path, and the path of your class in the webapp combine to form a path that
> is too long. I think the limit is about 256 characters. If this is a
> possibility, make a copy of your listener class in a package named "test"
> and see if it still fails to load. Note that with the shortened package,
> it could still just be a typo.
>
> Cheers,
> Larry
>
> Tobias wrote:
>> The ApplicationListener implements javax.servlet.ServletContextListener
>> which is found in servlet-api.jar and this is located in
>> $CATALINA_HOME$/lib
>> This tomcat is configured as runtime environment and is included under
>> project/java build path/libraries
>>
>>
>> Tobias
>>
>> "Cameron Bateman" <cameron.bateman@oracle.com> schrieb im Newsbeitrag
>> news:c9ce9f5a214994e380ed44d82e609c56$1@www.eclipse.org...
>>>> The ApplicationListener is in my source code.
>>>> Clean on the Tomcat as well as clean on the code does not work. I can
>>>> find the .class file in the eclipse tomcat working directory
>>>> ..metadata.pluginsorg.eclipse.wst.server.coretmp0wtpwebapps ... within
>>>> my package.
>>> Hmm, is it possible that your ApplicationListener implements, extends or
>>> uses any classes that may not be in the classpath?
>>>
>>>
>>> --Cam
>>>
>>>
>>
Re: problems with web project on wtp [message #211593 is a reply to message #211586] Wed, 02 April 2008 20:25 Go to previous message
Larry Isaacs is currently offline Larry Isaacs
Messages: 1305
Registered: July 2009
Senior Member
Hi Tobias,

Unfortunately, this may mean that something really odd is going on.
When you stated earlier that "I can find the .class file in the eclipse
tomcat working directory
..metadata\.plugins\org.eclipse.wst.server.core\tmp0\wtpweba pps ...
within my package", I assume this was under
"wtpwebapps\<context-root>\WEB-INF\classes"? If so, there isn't any
simple reason why you would get a ClassNotFoundException. I'm not aware
of any bugs in Tomcat 6 that would explain this. As long as the class
file is published where it belongs, WTP wouldn't be the cause either.
You might compare this published webapp with the one in Eclipse 3.3.2
workspace that's working to see if anything is missing or different.

Cheers,
Larry

Tobias wrote:
> Hi Larry,
> the same project works with Eclipse 3.3.2. So a typo is imposible. Its in a
> different workspace because I checked it out from svn but its the same
> web.xml, faces-config and so on.
> The workspace for 3.4 was the standard path on Windows. Its 208 characters
> long with the listener class. I copied the workspace direct on my hdd and
> the path was 177 characters long. Still doesn't work.
>
> I moved the listener with following error:
> java.lang.ClassNotFoundException: de.ApplicationListener
> So its not the path and not a typo.
>
> Tobias
>
> "Larry Isaacs" <Larry.Isaacs@sas.com> schrieb im Newsbeitrag
> news:fsteh4$ua$1@build.eclipse.org...
>> There isn't enough detail to make much more than a guess as to what is
>> going wrong. Given that you have abbreviated the full listener class
>> name, perhaps its long enough to have a hard to see typo in the intended
>> package or in the web.xml so they don't actually match. If you happen to
>> be on Windows, it may be that your workspace path, the ".metadata/.."
>> path, and the path of your class in the webapp combine to form a path that
>> is too long. I think the limit is about 256 characters. If this is a
>> possibility, make a copy of your listener class in a package named "test"
>> and see if it still fails to load. Note that with the shortened package,
>> it could still just be a typo.
>>
>> Cheers,
>> Larry
>>
>> Tobias wrote:
>>> The ApplicationListener implements javax.servlet.ServletContextListener
>>> which is found in servlet-api.jar and this is located in
>>> $CATALINA_HOME$/lib
>>> This tomcat is configured as runtime environment and is included under
>>> project/java build path/libraries
>>>
>>>
>>> Tobias
>>>
>>> "Cameron Bateman" <cameron.bateman@oracle.com> schrieb im Newsbeitrag
>>> news:c9ce9f5a214994e380ed44d82e609c56$1@www.eclipse.org...
>>>>> The ApplicationListener is in my source code.
>>>>> Clean on the Tomcat as well as clean on the code does not work. I can
>>>>> find the .class file in the eclipse tomcat working directory
>>>>> ..metadata.pluginsorg.eclipse.wst.server.coretmp0wtpwebapps ... within
>>>>> my package.
>>>> Hmm, is it possible that your ApplicationListener implements, extends or
>>>> uses any classes that may not be in the classpath?
>>>>
>>>>
>>>> --Cam
>>>>
>>>>
>
Previous Topic:Finding WebProjects
Next Topic:impossible to remove tomcat from classpath for test
Goto Forum:
  


Current Time: Thu Sep 18 03:54:25 GMT 2014

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

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