You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by prophecy <tr...@gmail.com> on 2006/04/06 10:36:01 UTC

Tomcat 5.5 Upgrade Problems

I've been getting this error after upgrading from Tomcat 5.0 to Tomcat 5.5:

Generated servlet error:
Only a type can be imported. com.x.MyClass resolves to a package

An error occurred at line: 16 in the jsp file: /index.jsp
Generated servlet error:
MyClass cannot be resolved to a type 

And the only solution, that I found after hours of banging my head on the
keyboard, is to put the jsp files in the root context directory.  For
instance, if the jsp files are at /index.jsp, it works fine.  If it's at
/somedir/index.jsp , it can't find the classes in the WEB-INF/classes dir. 
This is very strange behaviour, am I the only one that has seen this?  I
kept the configuration pretty much the same as what it was in Tomcat 5.0.


--
View this message in context: http://www.nabble.com/Tomcat-5.5-Upgrade-Problems-t1404562.html#a3780356
Sent from the Tomcat - User forum at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: Tomcat 5.5 Upgrade Problems

Posted by mslinn <ms...@mslinn.com>.
I have found exactly the same problem, and it's bad news.  The web
application has LOTS of JSPs, and I really don't want to jam them in the
root directory.  Is there a solution?
--
View this message in context: http://www.nabble.com/Tomcat-5.5-Upgrade-Problems-t1404562.html#a4379330
Sent from the Tomcat - User forum at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: Tomcat 5.5 Upgrade Problems

Posted by Hassan Schroeder <ha...@gmail.com>.
On 4/6/06, prophecy <tr...@gmail.com> wrote:
>
> I've been getting this error after upgrading from Tomcat 5.0 to Tomcat 5.5:
>
> Only a type can be imported. com.x.MyClass resolves to a package

> And the only solution, that I found after hours of banging my head on the
> keyboard, is to put the jsp files in the root context directory.  For
> instance, if the jsp files are at /index.jsp, it works fine.  If it's at
> /somedir/index.jsp , it can't find the classes in the WEB-INF/classes dir.
> This is very strange behaviour, am I the only one that has seen this?

I have multiple instances of Tomcat (5.5.9 - 5.5.17) running on
various platforms, and haven't seen this anywhere.

And I just did a quick test of moving a page with imports deeper
into the directory structure, with no effect.

So there's something else going on; without more specific info
it's hard to say what. Can you make a simple WAR of a test case?

-- 
Hassan Schroeder ------------------------ hassan.schroeder@gmail.com

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org