I can't reproduce the problem here. And I still can't figure out why it
would need to recompile the PSP file unless the PSP file changed on disk.
The key chunk of code in PSPServletFactory.py is lines 162-165:
if self._cacheClassFiles and os.path.exists(cachedfilename)
and os.stat(cachedfilename)[6] > 0:
if os.path.getmtime(cachedfilename) > mtime:
instance =
self.createInstanceFromFile(trans,cachedfilename,classname,mtime,0)
return instance
Which is basically saying, "if we're supposed to cache class files, the
cached class file exists and has non-zero size, and the cached class file is
newer than the original PSP file, then create a Servlet instance from the
cached class file".
This should always happen after the PSP is initially compiled.
So I would recommend instrumenting this code (with print statements) to find
out why these two if statements aren't always succeeding.
- Geoff
> -----Original Message-----
> From: Lars Rustemeier [mailto:[EMAIL PROTECTED]]
> Sent: Monday, June 24, 2002 1:32 PM
> To: Geoffrey Talvola
> Subject: Re: [Webware-discuss] performance problem?
>
>
> thanks for the quick reply,
>
> On Mon, Jun 24, 2002 at 12:49:30PM -0400, Geoffrey Talvola wrote:
> > I just glanced at the PSP code (from CVS) and it looks like
> it should
> > _never_ have to recompile the PSP page once it has been
> compiled, unless you
> > restart the appserver or the modification time of the PSP
> file changes.
> >
> > Are you seeing these errors when the app server first
> starts or later on?
> > Are you modifying the PSP file while the appserver is running?
>
> the appserver was not restarted.
>
> we simply started the server and started pounding it with requests.
>
> i just tried the same procedure on another psp page getting the same
> result.
>
> Traceback (most recent call last):
> File "./WebKit/Application.py", line 388, in dispatchRequest
> File "./WebKit/Application.py", line 534, in handleGoodURL
> File "./WebKit/Application.py", line 989, in
> createServletInTransaction
> File "./WebKit/Application.py", line 916, in getServlet
> File "./PSP/PSPServletFactory.py", line 177, in
> servletForTransaction
> File "./PSP/PSPCompiler.py", line 60, in compile
> File "/home/webkit/webware/PSP/ServletWriter.py", line 79, in close
> os.remove(self._pyfilename)
> OSError: [Errno 2] No such file or directory:
> '/home/webkit/nbwsite/Cache/PSP/_home_webkit_nbwsite_NBWContex
> t_playcom_data_sessions_psp.py'
>
>
> this time only one browser was used, reloading the page for about 30
> seconds at the approx speed of standard key repeat.
>
> regards
>
> /largo
>
>
-------------------------------------------------------
Sponsored by:
ThinkGeek at http://www.ThinkGeek.com/
_______________________________________________
Webware-discuss mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/webware-discuss