For information, I think that the PersistentFieldManager is told of a modification only when you do a 'new'. In your exemple, the Form is changing the properties of an existing bean.
The 'new' is called before the page is attached to the user request. The 'new' must be called after 'PageAttached' phase (in activation phase, in a getter method...) -----Message d'origine----- De : Ciaran Wood [mailto:[EMAIL PROTECTED] Envoyé : jeudi 12 juin 2008 16:42 À : Tapestry users Objet : Re: Question about T5's page lifecycle - instance variables NOT being purged Here's the code: public class Register { @Component private Form registerForm; @Persist("session") private Member member; @PageLoaded void pageLoaded(){ log.debug("member created"); member = new Member(); member.setCurrency("GBP"); } } And in the tml: <t:form t:id="registerForm" > <t:errors /> <p> <t:label for="userName" /><br /> <t:textfield t:id="userName" t:value="member.credentials.userName" t:validate="required,minLength=4,maxLength=16,regexp" /> </p> <p> <t:label for="password" /><br /> <t:passwordfield t:id="password" t:value="member.credentials.password" t:validate="required,minLength=6,maxLength=16,regexp"/> </p> </t:form> Ciaran On 12/06/2008 3:20pm, "Cordenier Christophe" <[EMAIL PROTECTED]> wrote: > Actually, at the end of the request, each variable instance is set to its > default value before giving the page instance back to the pool. Do you > initialize the member at declaration time ? > > Can you us more code ? > > > -----Message d'origine----- > De : Ciaran Wood [mailto:[EMAIL PROTECTED] > Envoyé : jeudi 12 juin 2008 16:03 > À : Tapestry users > Objet : Question about T5's page lifecycle - instance variables NOT being > purged > > I¹ve noticed on a tapestry app that we are building, that if two users on > separate machines go to the same page, the second user can see the first > users submitted details on the form. We¹re just using a Form component, a > model Object in the page class and declaring each of the properties as > Œeditor¹ components (Textfield, Checkbox etc) like so: > > <t:textfield t:id="userName" t:value="member.credentials.userName" > t:validate="required,minLength=4,maxLength=16,regexp²/> > > We¹re not using a beanEditForm since the Member object has nested objects > such as Credentials, Contact etc. I¹ve checked that the two users are > getting different JSESSIONIDs, so no session sharing is present. There is a > @Persist(session) annotation on the Member model object inside the page. Is > this a bug in Tapestry? I thought that Tapestry was meant to clear all > instance variables once the page returns to the pool? > > Cheers for any help, I¹m completely stumped! > > Ciaran Wood > > > Ce message et les pièces jointes sont confidentiels et réservés à l'usage > exclusif de ses destinataires. Il peut également être protégé par le secret > professionnel. Si vous recevez ce message par erreur, merci d'en avertir > immédiatement l'expéditeur et de le détruire. L'intégrité du message ne > pouvant être assurée sur Internet, la responsabilité du groupe Atos Origin ne > pourra être recherchée quant au contenu de ce message. Bien que les meilleurs > efforts soient faits pour maintenir cette transmission exempte de tout virus, > l'expéditeur ne donne aucune garantie à cet égard et sa responsabilité ne > saurait être recherchée pour tout dommage résultant d'un virus transmis. > > This e-mail and the documents attached are confidential and intended solely > for the addressee; it may also be privileged. If you receive this e-mail in > error, please notify the sender immediately and destroy it. As its integrity > cannot be secured on the Internet, the Atos Origin group liability cannot be > triggered for the message content. Although the sender endeavours to maintain > a computer virus-free network, the sender does not warrant that this > transmission is virus-free and will not be liable for any damages resulting > from any virus transmitted. > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Ce message et les pièces jointes sont confidentiels et réservés à l'usage exclusif de ses destinataires. Il peut également être protégé par le secret professionnel. Si vous recevez ce message par erreur, merci d'en avertir immédiatement l'expéditeur et de le détruire. L'intégrité du message ne pouvant être assurée sur Internet, la responsabilité du groupe Atos Origin ne pourra être recherchée quant au contenu de ce message. Bien que les meilleurs efforts soient faits pour maintenir cette transmission exempte de tout virus, l'expéditeur ne donne aucune garantie à cet égard et sa responsabilité ne saurait être recherchée pour tout dommage résultant d'un virus transmis. This e-mail and the documents attached are confidential and intended solely for the addressee; it may also be privileged. If you receive this e-mail in error, please notify the sender immediately and destroy it. As its integrity cannot be secured on the Internet, the Atos Origin group liability cannot be triggered for the message content. Although the sender endeavours to maintain a computer virus-free network, the sender does not warrant that this transmission is virus-free and will not be liable for any damages resulting from any virus transmitted.