RE : Common vs. Shared

2005-05-12 Thread LERBSCHER Jean-Pierre


-Message d'origine-
De : Ron Heeb [mailto:[EMAIL PROTECTED] 
Envoyé : vendredi 6 mai 2005 18:18
À : tomcat-user@jakarta.apache.org
Objet : RE: Common vs. Shared

my understanding comes from this book i got: 'common is responsible for 
classes that are used by Tomcat and publicly available to all Web 
apps'.  shared is like common, except that 'developers can place their 
own classes and JAR files into the shared class loader domain'.  


developers shouldn't put anything into common.
False. Typically if you plan to use JAASRealm and specific login module your
have to put your library in common/lib.

  this is from 
Professional Apache Tomcat 5 from Wrox.  for what it's worth...ron

-- 
Ron Heeb, Project Leader
Applications Development - Information Technology Resources
California State University, Northridge




-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: RE : Common vs. Shared

2005-05-12 Thread Nikola Milutinovic
LERBSCHER Jean-Pierre wrote:
-Message d'origine-
De : Ron Heeb [mailto:[EMAIL PROTECTED] 
Envoyé : vendredi 6 mai 2005 18:18
À : tomcat-user@jakarta.apache.org
Objet : RE: Common vs. Shared

my understanding comes from this book i got: 'common is responsible for 
classes that are used by Tomcat and publicly available to all Web 
apps'.  shared is like common, except that 'developers can place their 
own classes and JAR files into the shared class loader domain'.  
 

${CATALINA_HOME}/server/lib is picked up by TC only
${CATALINA_HOME}/shared/lib is picked by all web-apps
${CATALINA_HOME}/common/lib is picked up by both TC and all web-apps
${Context_HOME}/WEB-INF/lib is picked up by that web-app only
Nix.
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: Common vs. Shared

2005-05-12 Thread Dakota Jack
I have not read all the responses, but:



 Bootstrap
 |
  System
 |
  Common
 /  \
Catalina   Shared
   /   \
   Webapp1  Webapp2 ...

On 5/5/05, Michael Oliver [EMAIL PROTECTED] wrote:
  
  
 
 I am quite sure this has been asked and answered but I googled a bunch of
 combinations and didn't find the answer, so I am sure someone here will know
 and share. 
 
   
 
 What is the difference between the /common/ and /shared/ 
 
   
 
 I understand this is a class loader issue, and I have read the comments in
 catalina.properties. 
 
   
 
 What would go into 'common' that wouldn't go into 'shared' and vice versa? 
 
   
 
 If a jar is in /common/lib/ and a different version of that jar is in
 /shared/lib/ what will be the effect? 
 
   
 
 Similarly, if I modify catalina.properties and add something to 'common'
 that is already in 'shared', etc. 
 
   
 
 Understanding the relationship between 'common' and 'shared' and the
 intended use thereof should be of interest to more than just me. 
 
   
 
 Ollie 
 
   
 
   
  
  
  
  
 
  
 
 Loosely Coupled 
 
  
 
   
  
  
 
 Mike Oliver
  CTO 
 
 Alarius Systems LLC
  6800 E. Lake Mead Blvd
  Apt 1096
  Las Vegas, NV 89156 
  
 
 [EMAIL PROTECTED]
  [EMAIL PROTECTED]
  IM: [EMAIL PROTECTED]
  http://www.alariussystems.com/ 
  
 
 tel: 
  fax: 
  mobile: 
 
 (702)643-7425
  (702)974-0341
  (518)378-6154 
 
  
 
  
 
  
 
   
 
  
  
  
 
 Add me to your address book... 
 
 Want a signature like this? 
 
  
 
   


-- 
You can lead a horse to water but you cannot make it float on its back.
~Dakota Jack~

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Common vs. Shared

2005-05-12 Thread Gabriel Belingueres
Yes, it works this way for javax.mail.Session too. You need to put mail.jarand 
activation.jar in lib/common so as you can find the Session from JNDI.

 On 5/6/05, Michael Echerer [EMAIL PROTECTED] wrote: 
 
 Ron Heeb wrote:
  my understanding comes from this book i got: 'common is responsible for
  classes that are used by Tomcat and publicly available to all Web
  apps'. shared is like common, except that 'developers can place their
  own classes and JAR files into the shared class loader domain'.
  developers shouldn't put anything into common. this is from
  Professional Apache Tomcat 5 from Wrox. for what it's worth...ron
 
 You need common/lib e.g. for JDBC drivers. Because if you want to
 configure a JNDI Datasource and use Tomcats Jakarta Commons DBCP
 connection pool there's no other way then placing the driver.jar
 into common/lib because Tomcat itself requires the classes already, not
 only your webapps.
 
 Moreover you should make sure that the webapps don't contain the
 driver.jar in that case again.
 Otherwise you'll face lot's of funny classloading issues...
 E.g. if you work with driver specific data types you could face problems
 like instanceof returning false although using the same class because
 objects might be loaded by different classloaders (and instanceof and
 casting only works within the same classloader).
 
 Cheers,
 Michael
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 



RE: Common vs. Shared

2005-05-06 Thread Ron Heeb
my understanding comes from this book i got: 'common is responsible for 
classes that are used by Tomcat and publicly available to all Web 
apps'.  shared is like common, except that 'developers can place their 
own classes and JAR files into the shared class loader domain'.  
developers shouldn't put anything into common.  this is from 
Professional Apache Tomcat 5 from Wrox.  for what it's worth...ron

--
Ron Heeb, Project Leader
Applications Development - Information Technology Resources
California State University, Northridge

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: Common vs. Shared

2005-05-06 Thread Michael Echerer
Ron Heeb wrote:
 my understanding comes from this book i got: 'common is responsible for
 classes that are used by Tomcat and publicly available to all Web
 apps'.  shared is like common, except that 'developers can place their
 own classes and JAR files into the shared class loader domain'. 
 developers shouldn't put anything into common.  this is from
 Professional Apache Tomcat 5 from Wrox.  for what it's worth...ron
 
You need common/lib e.g. for JDBC drivers. Because if you want to
configure a JNDI Datasource and use Tomcats Jakarta Commons DBCP
connection pool there's no other way then placing the driver.jar
into common/lib because Tomcat itself requires the classes already, not
only your webapps.

Moreover you should make sure that the webapps don't contain the
driver.jar in that case again.
Otherwise you'll face lot's of funny classloading issues...
E.g. if you work with driver specific data types you could face problems
like instanceof returning false although using the same class because
objects might be loaded by different classloaders (and instanceof and
casting only works within the same classloader).

Cheers,
Michael


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Common vs. Shared

2005-05-05 Thread Michael Oliver








I am quite sure this has been asked and
answered but I googled a bunch of combinations and didnt find the
answer, so I am sure someone here will know and share.



What is the difference between the /common/
and /shared/ 



I understand this is a class loader issue, and
I have read the comments in catalina.properties.



What would go into common
that wouldnt go into shared and vice versa?



If a jar is in /common/lib/ and a different
version of that jar is in /shared/lib/ what will be the effect?



Similarly, if I modify catalina.properties
and add something to common that is already in shared,
etc.



Understanding the relationship between common
and shared and the intended use thereof should be of interest to
more than just me.



Ollie






 
  
  
   


 
  
  
   




Loosely Coupled

   
  
  
  
  
  
  
 
 
  
  
   

Mike Oliver
CTO 


Alarius Systems LLC
6800 E. Lake Mead Blvd
Apt 1096
Las Vegas, NV 89156 

   
   

[EMAIL PROTECTED]
[EMAIL PROTECTED]
IM: [EMAIL PROTECTED]
http://www.alariussystems.com/




 
  
  tel: 
  fax: 
  mobile: 
  
  
  (702)643-7425
  (702)974-0341
  (518)378-6154 
  
 



   
  
  
  
 






   
  
  
  
 
 
  
  
   

Add me to your address book...


Want a signature like
this?

   
  
  
  
 











Re: Common vs. Shared

2005-05-05 Thread Larry Meadors
Common is available globally to the server, and to all of the 
web-applications.

Shared is available globally, but only to all of the web-applications.

IMO, both are bad places to put stuff unless you *really need* to.

Larry


On 5/5/05, Michael Oliver [EMAIL PROTECTED] wrote:
 
  I am quite sure this has been asked and answered but I googled a bunch of 
 combinations and didn't find the answer, so I am sure someone here will know 
 and share.
 
  What is the difference between the /common/ and /shared/ 
 
  I understand this is a class loader issue, and I have read the comments 
 in catalina.properties.
 
  What would go into 'common' that wouldn't go into 'shared' and vice 
 versa?
 
  If a jar is in /common/lib/ and a different version of that jar is in 
 /shared/lib/ what will be the effect?
 
  Similarly, if I modify catalina.properties and add something to 'common' 
 that is already in 'shared', etc.
 
  Understanding the relationship between 'common' and 'shared' and the 
 intended use thereof should be of interest to more than just me.
 
  Ollie
 
 http://www.sourceonenet.com
  
 Loosely Coupled
   
   *Mike Oliver*
 *CTO* 
  
 *Alarius Systems LLC*
 6800 E. Lake Mead Blvd
 Apt 1096
 Las Vegas, NV 
 89156http://maps.yahoo.com/py/maps.py?Pyt=Tmapaddr=6800+E.+Lake+Mead+Blvdcsz=Las+Vegas%2C+NV+89156country=us
  
   
 [EMAIL PROTECTED]
 [EMAIL PROTECTED]
 IM: [EMAIL PROTECTED]
 http://www.alariussystems.com/ 

 tel: 
 fax: 
 mobile: 
  
 (702)643-7425
 (702)974-0341
 (518)378-6154 
   
 *Add me to your address 
 book...*https://www.plaxo.com/add_me?u=25769982367v0=355403k0=305933374
  
 *Want a signature like this?* http://www.plaxo.com/signature
   



RE: Common vs. Shared

2005-05-05 Thread Caldarale, Charles R
 From: Michael Oliver [mailto:[EMAIL PROTECTED] 
 Subject: Common vs. Shared
 
 What is the difference between the /common/ and /shared/ 
 
 I understand this is a class loader issue, and I have read 
 the comments in catalina.properties.

But have you read the actual documentation?  In particular:
http://jakarta.apache.org/tomcat/tomcat-5.5-doc/class-loader-howto.html
including this rather descriptive diagram:

  Bootstrap
  |
   System
  |
   Common
  /  \
 Catalina   Shared
 /   \
Webapp1  Webapp2 ... 

 If a jar is in /common/lib/ and a different version of that 
 jar is in /shared/lib/ what will be the effect?

Trouble, usually.  Anytime you have the same class files in multiple
places in a single path in the hierarchy, you run the risk of conflicts
and lots of NCDFE problems.  Very, very bad practice.

 - Chuck


THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY
MATERIAL and is thus for use only by the intended recipient. If you
received this in error, please contact the sender and delete the e-mail
and its attachments from all computers.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: Common vs. Shared

2005-05-05 Thread Michael Oliver
Oh I completely agree it is bad practice, but alas I must deal with
applications that are not my design and dealing with these conflicts is
a royal pain in my non-royal ass.

Michael Oliver
CTO
Alarius Systems LLC
6800 E. Lake Mead Blvd, #1096
Las Vegas, NV 89156
Phone:(702)643-7425
Fax:(702)974-0341
*Note new email changed from [EMAIL PROTECTED]
-Original Message-
From: Caldarale, Charles R [mailto:[EMAIL PROTECTED] 
Sent: Thursday, May 05, 2005 1:29 PM
To: Tomcat Users List
Subject: RE: Common vs. Shared

 From: Michael Oliver [mailto:[EMAIL PROTECTED] 
 Subject: Common vs. Shared
 
 What is the difference between the /common/ and /shared/ 
 
 I understand this is a class loader issue, and I have read 
 the comments in catalina.properties.

But have you read the actual documentation?  In particular:
http://jakarta.apache.org/tomcat/tomcat-5.5-doc/class-loader-howto.html
including this rather descriptive diagram:

  Bootstrap
  |
   System
  |
   Common
  /  \
 Catalina   Shared
 /   \
Webapp1  Webapp2 ... 

 If a jar is in /common/lib/ and a different version of that 
 jar is in /shared/lib/ what will be the effect?

Trouble, usually.  Anytime you have the same class files in multiple
places in a single path in the hierarchy, you run the risk of conflicts
and lots of NCDFE problems.  Very, very bad practice.

 - Chuck


THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY
MATERIAL and is thus for use only by the intended recipient. If you
received this in error, please contact the sender and delete the e-mail
and its attachments from all computers.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]