You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Tim Cronin <ti...@13-colonies.com> on 2002/05/08 20:48:37 UTC

choosing where to deploy class files

I've created a Custom Realm since my DB user structure cannot be changed to
match the JDBCRealm. 

placing my classes at $CATALINA_HOME/classes I get: 
ClassNotFoundException <my realm implementation class>

placing my classes at $CATALINA_HOME/common/classes
it finds my Realm but I get:
NoClassDefFoundError org/apache/catalina/realm/RealmBase

to work I have to put $CATALINA_HOME/server/classes

the problem is the Realm class uses a common package that accessed the
database. This package does all our connection pooling and statement
execution. this package is also used by our servlets/jsp's

packages put in $CATALINA_HOME/server/classes are not available to
the web applications...

is there a place to place my classes that is available for both web apps
and tomcat?

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: choosing where to deploy class files

Posted by Umberto Nicoletti <un...@arpa.veneto.it>.
Tim Cronin wrote:
> 
> I've created a Custom Realm since my DB user structure cannot be changed to
> match the JDBCRealm.

Tim,
could you please tell me where you found info on doing this?

Did you just subclass JDBCRealm or do you need to do something else?

Thanks,
umebrto

> 
> placing my classes at $CATALINA_HOME/classes I get:
> ClassNotFoundException <my realm implementation class>
> 
> placing my classes at $CATALINA_HOME/common/classes
> it finds my Realm but I get:
> NoClassDefFoundError org/apache/catalina/realm/RealmBase
> 
> to work I have to put $CATALINA_HOME/server/classes
> 
> the problem is the Realm class uses a common package that accessed the
> database. This package does all our connection pooling and statement
> execution. this package is also used by our servlets/jsp's
> 
> packages put in $CATALINA_HOME/server/classes are not available to
> the web applications...
> 
> is there a place to place my classes that is available for both web apps
> and tomcat?
> 
> --
> To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
> For additional commands, e-mail: <ma...@jakarta.apache.org>

-- 
Umberto Nicoletti - unicoletti@arpa.veneto.it | sysmaster@arpa.veneto.it
Tel. 049-8239380 (assistenza)

"We'll try to make different mistakes this time." - Larry Wall

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: choosing where to deploy class files

Posted by "Craig R. McClanahan" <cr...@apache.org>.

On Wed, 8 May 2002, Tim Cronin wrote:

> Date: Wed, 8 May 2002 13:48:37 -0500
> From: Tim Cronin <ti...@13-colonies.com>
> Reply-To: Tomcat Users List <to...@jakarta.apache.org>
> To: 'Tomcat Users List' <to...@jakarta.apache.org>
> Subject: choosing where to deploy class files
>
> I've created a Custom Realm since my DB user structure cannot be changed to
> match the JDBCRealm.
>
> placing my classes at $CATALINA_HOME/classes I get:
> ClassNotFoundException <my realm implementation class>
>
> placing my classes at $CATALINA_HOME/common/classes
> it finds my Realm but I get:
> NoClassDefFoundError org/apache/catalina/realm/RealmBase
>
> to work I have to put $CATALINA_HOME/server/classes
>
> the problem is the Realm class uses a common package that accessed the
> database. This package does all our connection pooling and statement
> execution. this package is also used by our servlets/jsp's
>
> packages put in $CATALINA_HOME/server/classes are not available to
> the web applications...
>
> is there a place to place my classes that is available for both web apps
> and tomcat?
>

Put JAR files in common/lib, and unpacked classes in common/classes -- see
the Tomcat docs for more information:

  http://localhost:8080/tomcat-docs/class-loader-howto.html

Craig


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>