Yes, session expiration is one possible reason to close the Hibernate session.
Completing a use case or conversation (i.e. finished booking process) is
another.
Sven
>
>And how do you make sure that the hibernate connection is ever closed?
>You can't count on another http request, since it may
thats something i agree on.
It is a bit confusing now.
Maybe we should refactor this in 1.2
So then we can have a onBeginRequest() (or a bit other name so it
doesn't conflict) which is called when the page is get from the page
map.
and onBeginRender() when the page is started to get rendered (like
Yes, you're absolutely correct with the three phases of a page.
Initially I assumed that Component#onBeginRequest() would serve my needs. But
this methods is called on start of rendering of the page only. That's too late,
as the request is already applied to the page.
Perhaps this method would
And how do you make sure that the hibernate connection is ever closed?
You can't count on another http request, since it may never come. Will
you put a hook on session expiration?
-Matej
[EMAIL PROTECTED] wrote:
just curious what does this mean:
"All I need is to be able to disconnect the
>just curious what does this mean:
>
>>"All I need is to be able to disconnect the hibernate session after
>>arequest (that's easy) but more importantly reconnect the
>>*according*hibernate session before my code is triggered in one of my
>>components"
>
>what is a disconnected hibernate session? A
just curious what does this mean:
"All I need is to be able to disconnect the hibernate session after a
request (that's easy) but more importantly reconnect the *according*
hibernate session before my code is triggered in one of my components"
what is a disconnected hibernate session? And to what
The problem is that Wicket doesn't manage it's pages that way. The
pagefactory is only used in certain cases, like page links and for
bookmarkable pages. Good thing about not managing them is that it
gives you greater flexibility and allows for an easier programming
model (no need for abstract page