Do both Person and Credentials (and everything else Person holds on to)
implement Serializable?

Watch the logs to see if there are serialization errors.  It's a problem of
the page not being in the session - which means it either didn't make it
there or the session is somehow gone.

--
Jeremy Thomerson
http://www.wickettraining.com



On Sat, Nov 14, 2009 at 7:26 AM, Николай Кучумов <kuchum...@gmail.com>wrote:

> Hello.
> I have a "Person" class, describing a person, which has a member
> "credentials" of type "Credentials" (username/password).
> I tried to make a registration page in this way:
>
> Page
> {
>    super();
>
>    Person person = [create a person with empty credentials];
>
>    Form form = new Form("form", new CompoundPropertyModel(person));
>
>    add(form);
>
>    form.add(new TextField("familyName"));
>    form.add(new TextField("givenName"));
>
>    form.add(new TextField("credentials.userName"));
>    form.add(new TextField("credentials.passWord"));
>
>    // also add a submit button
> }
>
> And now when I push the "Submit" button, it outputs this error:
>
> org.apache.wicket.protocol.http.PageExpiredException: Cannot find the
> rendered page in session [pagemap=null,componentPath=0,versionNumber=0]
>
> I like the idea of compound object model, and I wouldn't like to deprive
> myself from using it just because of this strange error...
> Can you give me a hint on what have I done wrong in the code above?
>

Reply via email to