Help with war file creation times

M

Marcus Leon

We're trying to diagnose why Weblogic is recompiling our already
compiled JSPs. The Weblogic JSP Precompilation Test Utility (uses
BCEL) says that the compiled JSP modified date is *prior* to the date
of the JSP but when I look at the date of the compiled JSP this doesn't
*appear* to be the case. Does anyone know why this utility says the
compiled JSP modified date is much earlier that it appears to be?

We are examining the compiled JSP modified date by looking at the date
of the file in Winzip when we open the war file. This date is the same
as when we extract the files to the filesystem with Winzip.

The dates are way off. The utility says the date is a couple seconds
prior to the JSP modification time (eg 2003) when in Winzip it
correctly lists that the compiled JSP was just created (eg: Oct 4,
2005).

The war file is created using ant. We tried using a new version of ant
to see if that made a difference.. it didn't.

Any help would be great!
 
R

Roedy Green

Does anyone know why this utility says the
compiled JSP modified date is much earlier that it appears to be?

First thing to do is make sure all clocks in your universe are
correct, including the CVS server.

For windows clocks you can sync them with
http://mindprod.com/webstarts/setclock.html

I hypothesise that Javac when it starts up grabs the system time and
uses that for stamping all classes it creates this session. With
ant, the effect is magnified since ant starts the compiling classes
only once for the entire ant script.

If that is true, then there are a number of ways you could fix it:

1. don't do any generating of new *.java files after the first compile
in an ant script. Move all the compiles to the end or even a separate
script.

2. write a BCEL or similar utility to look at the file date and insert
it as the class date.

3. explain the problem to BEA and ask them to use the file date
instead.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,770
Messages
2,569,583
Members
45,073
Latest member
DarinCeden

Latest Threads

Top