the default behavior is for a session to be temporary? that doesnt make
sense.

this maybe another reason. i have my login code (basically everything you've
seen) in an abstract BasePage class. I then call Index which extends
BasePage. would that have anything to do with anything?

thanks,

verbal

On 6/13/07, Eelco Hillenius <[EMAIL PROTECTED]> wrote:

> Speaking of logging, I want to use log4j, but i cant because it doesnt
> implement serializable.

Either make the log instance it a static variable (statics don't get
serialized) or get it on the fly (every time you need it but don't
keep a reference).

> secondly,  session.get().info("message"); doesnt
> seem to print anything. i have to resort to System.out's. I made the
logger
> transient so that "solved" that problem, but it doesnt print anything to
the
> screen.

Session#info and Component#info (and #error etc) are for a different
purpose. We call those things feedback messages, and they are intended
for communicating with end-users, for instance reporting validation
errors on a form submit. If you put a FeedbackPanel in your page, you
will see those messages.

> i have turned on debugging for wicket.Session in log4j, but all it
prints is
> information about pages being dirty or not.
>
> any other debugging i can use or turn on?

Not anything that will help you. Component#isVisible can indeed be
called more than once in a request; not only when it renders, but also
for instance when behaviors query it. I guess the documentation can
use some improvement (I added a warning).

It is possible that your page is stateless and your session is
temporary (meaning that it isn't bound to e.g. the HttpSession yet,
and that you'll get a new volatile instance every request). You can
query that by calling session#isTemporary. If it is, and you want to
explicitly make the session persistent, you can call session#bind. See
the JavaDocs for details.

Maybe we shouldn't automagically mark pages as stateless... but I'll
post about that in another thread.

Eelco

-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user

-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user

Reply via email to