The thing to remember here is the main goal of WAR packaging: 
portability.  The idea is that everything a web application needs should 
be inside the WAR file.  The web container should not have to try to 
find things like classes outside of the WAR file for any given web app. 
  **Exception:** The only things it should look for outside of itself 
are made available via JNDI references - references to EJBs, etc.  One 
might ask, "What if my web app needs to write to disk?"  In that case, 
if all you have is a web container, then okay.  However, if you've got a 
full J2EE stack, in a perfect world I would suggest that you put those 
kind of functions in EJBs, that way the functionality (in the EJBs) 
could be shared by GUI clients, etc.

--

Keith Kee wrote:

> According to the JBOSS manual, I can specify a "common" classpath in the
> Class-Path directive of the MANIFEST file. This should cause the libraries
> listed by the directive to be loaded by the application classloader as such
> these classes would be visible to the jsps. However, it does not seem to
> pass this classpath information to the jspC when it tries to compile the
> jsps in the war file.
> 
> Thanks
> keith
> 
> 
> 
> 
>> Keith,
>> 
>> What do you mean by the "common" classpath?  Hopefully you're not
>> talking about what is traditionally in the $CLASSPATH env variable.  If
>> your JSP needs some of your own defined classes to work, they should be
>> put in your WAR file in the WEB-INF/classes directory.  These will be
>> automatically loaded by Tomcat so they are available to your web app.
>> All this is in the servlet2.2 spec.
>> 
>> Of course, maybe you mean something completely different and I'm just
>> being ignorant (it's been known to happen).  ;)
>> 
>> Hope this helps,
>> David
>> 
>> -->
>> 
>> Keith Kee wrote:
>> 
>> Hi:
>>    I'm a newbie trying to get my jsps to run on JBoss 2.2.1 and embedded
>> tomcat 3.2.1. It seems like the jspc cannot find the classes on the common
>> path (using the Class-Path directive) which my jsp is trying to import. I
>> searched in the mailing list archive and found that a lot of the people
> 
> had
> 
>> the same problem.
>>    I was wondering if this problem will be fixed, or it is a limitation of
>> tomcat?
>> 
>> Thanks
>> keith
>> 
>> 
> 
> 
> 
> _______________________________________________
> JBoss-user mailing list
> [EMAIL PROTECTED]
> http://lists.sourceforge.net/lists/listinfo/jboss-user


-- 

-----------------------------------------------------------------------
David Ward                                        [EMAIL PROTECTED]
Senior Software Engineer                          http://www.dotech.com
Distributed Object Technologies, Inc.             716-381-8320 (phone)
500 Linden Oaks, Rochester, NY 14625              716-381-0598 (fax)


_______________________________________________
JBoss-user mailing list
[EMAIL PROTECTED]
http://lists.sourceforge.net/lists/listinfo/jboss-user

Reply via email to