cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Robin Green" <gree...@hotmail.com>
Subject Re: Cocoon 1.7.4, XSP and hasChanged
Date Tue, 11 Jul 2000 11:06:58 GMT
The hasChanged code is definitely in 1.7.3, and in the latest CVS (see 
http://xml.apache.org/websrc/cvsweb.cgi/xml-cocoon/src/org/apache/cocoon/processor/xsp/XSPProcessor.java?rev=1.22&content-type=text/vnd.viewcvs-markup

). I recognise it, because I wrote it. It used to work - I don't see why it 
shouldn't work now.

Maybe this is a stupid question, but what servlet engine are you using, 
Alex? Printing to System.out isn't a good idea - for instance, with tomcat 
on Unices, tomcat.sh spawns a child process and System.out is blackholed, so 
you have to use System.err - or better yet, servletContext.log (), which 
goes to a tomcat-specific log file. Do you get the "in treeview.xml" 
displayed on the terminal at all?


Alex Muc <alex.muc@utoronto.ca> wrote:
>No one has gotten back to me about this.  I'd be really interested in 
>knowing
>an answer to the problem as well.
>
>Is anyone out there successfully using "public boolean hasChanged (Object
>context)" in their XSP pages?  If so can you send an example (or what am I
>doing wrong in my example below).  If it is broken, can someone please 
>confirm
>(Stefano? Ricardo?  As far as I know, you guys are the main people who
>implemented XSP).
>
>Thanks.
>Alex
>
>Mark Washeim wrote:
>
> > on 5/7/00 10:20 am, Alex Muc at alex.muc@utoronto.ca wrote:
> >
> > > Hi,
> > >
> > > The changes history says that Cocoon 1.7.3 included the ability to 
>call
> > > hasChanged(Object request) on an XSP.  I'm using Cocoon 1.7.4 and it
> > > doesn't seem to work correctly.  Has this been changed back?  Being 
>able
> > > to check whether a page should be served from the cache or reprocessed
> > > is very important.
> > > For example, the following XSP page should print to Stdout every time
> > > the hasChanged method is called, but for some reason it doesn't.
> > > Can anyone tell me why this isn't working?
> > > Below is the sample page.
> > >
> >
> > Has anyone replied to this? I'm experiencing the same problem . . . with
> > 1.7.x (most of the current cvs is built, with some additions of my own) 
>...
> >
> > Alex, anyone gotten back to you (I searched my cocoon archive, no luck) 
>. .
> > .
> >
> > > Thanks
> > > Alex
> > >
> > > <?xml version="1.0"?>
> > > <?cocoon-process type="xsp"?>
> > > <?cocoon-process type="xslt"?>
> > > <?xml-stylesheet href="treeview-html.xsl" type="text/xsl"?>
> > > <xsp:page language="java"
> > > xmlns:xsp="http://www.apache.org/1999/XSP/Core"
> > > xmlns:util="http://www.apache.org/1999/XSP/Util">
> > >
> > > <xsp:structure>
> > > <xsp:include>java.util.*</xsp:include>
> > > <xsp:include>java.sql.*</xsp:include>
> > > </xsp:structure>
> > >
> > > <xsp:logic><![CDATA[
> > > public boolean hasChanged (Object context) {
> > > System.out.println("in treeview.xml hasChanged()");
> > > return false;
> > > }
> > > ]]>
> > > </xsp:logic>
> > >
> > > <page>
> > > <xsp:logic>
> > > System.out.println("in treeview.xml");
> > > </xsp:logic>
> > > <title>Category Overview
> > > </title>
> > > </page>
> > > </xsp:page>
> > >


--
Robin Green
i-tao Ltd.
4 Skyline Village
Limeharbour
London E14 9TS
United Kingdom
Phone +44 20 7537 2233  Fax +44 70 8081 5118
http://www.i-tao.com


________________________________________________________________________
Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com


Mime
View raw message