----------------------------------------------------------------
BEFORE YOU POST, search the faq at <http://java.apache.org/faq/>
WHEN YOU POST, include all relevant version numbers, log files,
and configuration files.  Don't make us guess your problem!!!
----------------------------------------------------------------

I just made that change in our dev area.  It seems to slow things down a
lot.   Is that because the classloader must check every .class file?
 

-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, January 19, 2000 12:13 PM
To: [EMAIL PROTECTED]
Subject: RE: own custom classes in servlet?



This is similar to how we do it in production as well. 

In development, we have all our classes un-jarred under the path for the
servlet zone (obviously 3rd party classes are not un-jarred), so that the
development JServ picks up our changes automagically.  We do not ever need
to stop or start our development apache or JServ (with obvious exceptions,
which are relatively rare for us).  Since development code can be fairly
dynamic at times, this works well for us (small development team).

Then for production, we jar everything up, including the servlets.  In
production, we do not have any individual class files under our path for the
servlet zone.  We do this to squeak out any performance gain, however
minimal, by avoiding any unnecessary checking for file changes by JServ
(even though you can turn this off).  I guess one might question if this
even helps (does somebody know for sure either way?).  I also like it
because it feels "cleaner" to me for a production environment (i.e. deal
with one jar file instead of multiple class files).  In any case, changes to
production code necessitate replacing a jar file, which means restarting
JServ (through apache).  One should never have to reboot for something as
trivial as that.  I wonder what platform the original poster is on?  We are
on Linux.  Shouldn't make a difference, eh?

In both development and production, all servlets are aliased, which allows
us to use mostly the same configuration files between dev and prod, with
obvious exceptions.

- Greg 

> -----Original Message----- 
> From: Kevin Macclay [ mailto:[EMAIL PROTECTED]
<mailto:[EMAIL PROTECTED]> ] 
> Sent: Wednesday, January 19, 2000 12:18 PM 
> To: Java Apache Users 
> Subject: Re: own custom classes in servlet? 
> 
> 
> ---------------------------------------------------------------- 
> BEFORE YOU POST, search the faq at < http://java.apache.org/faq/
<http://java.apache.org/faq/> > 
> WHEN YOU POST, include all relevant version numbers, log files, 
> and configuration files.  Don't make us guess your problem!!! 
> ---------------------------------------------------------------- 
> 
> We also use a custom package in our servlets.  The way we are 
> both doing it, 
> the custom package classes are loaded into memory via the 
> bootstrap class 
> loader and so they can not be reloaded.  You can just restart Apache 
> (apachectl restart) which will restart JServ and the Java 
> Virtual Machine, 
> blowing away the custom package classes that were loaded.  So 
> it will then 
> load in the new classes next time you load a servlet that 
> uses it.  It's not 
> necessary to reboot your machine each time to blow away the JVM. 
> 
> Hope that helps, 
> Kevin 



--
--------------------------------------------------------------
Please read the FAQ! <http://java.apache.org/faq/>
To subscribe:        [EMAIL PROTECTED]
To unsubscribe:      [EMAIL PROTECTED]
Archives and Other:  <http://java.apache.org/main/mail.html>
Problems?:           [EMAIL PROTECTED]

Reply via email to