Al Maw-2 wrote:
> 
> Icy wrote:
>> *** What is the "best practise" to not instanciate "page aggregating
>> panels"
>> all the time? ***
> 
> This isn't really a Wicket question.
> 
> Your page is slow because doing database/remote operations is slow. It 
> has nothing to do with creating Panels, but everything to do with the 
> database access you're doing in the constructor of those Panels.
> 
> You need to break those operations out into a service layer that can 
> cache the results, then use that service layer in your constructor.
> 
> Regards,
> 
> Al
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 
> 

Heyho again, Al, and all,

as with Spring it's not that easy to do what I wanted, because singleton
beans are instanciated only once for ALL users, and prototype beans are
instanciated on every request, which is too often, the natural target for
storing sinlgeton references to objects for a user is the SESSION again...
so I tried this.

First question: I just wanted to put a wicket stuff GMap2 instance into the
session, and got a java.lang.StackOverflowError. Is it possible to increase
the stack size?

Second question: Even if this works to construct GMap, etc. only once when
the session is created, and add these components to a Panel on request, then
still I have a common problem understanding the following:

The special cool thing about Wicket is that components keep their state. If
I have to instanciate all Panels again each time a page is requested, they
for sure always loose their state - they are new. If I put everything in the
session, to keep the state manually, then it will probably work, but that's
old fashioned Web programming ;) Doesn't Wicket offer me the possibility to
e.g. let a user scroll around in the Google Map Panel, and the scrolling
position always remains the same on each page request? What about the cool
Wicket Model approach, the Desktop App programming experience? What do I
have to do to maintain Panels state?

Please, explain this to me, it's a very very basic question for me, to
understand the "magic" of the Wicket approach.

Kind regards,
Icy

 

-- 
View this message in context: 
http://www.nabble.com/How-to-instanciate-panels-best--tf4855189.html#a13899931
Sent from the Wicket - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to