voyent
LazyDataModel.load() called more than once  XML
Forum Index -> General Help
Author Message
MajorPain

Joined: 31/Jan/2014 05:03:51
Messages: 3
Offline


LazyDataModel.load() called more than once.
In my case it run 4 time. It`s a bug? Or i don't understand how it works?
artzambrano

Joined: 21/Mar/2007 00:00:00
Messages: 175
Offline


This is not a bug. That's just how the ace:dataTable works in general, not only in lazy mode. The ace:dataTable component is a very complex component with a lot of features that have to be integrated with the rest. Some of these features, such as sorting or filtering, require the underlying model to be rebuilt, at certain stages during a request, in order for them to work correctly. More specifically, the getValue() method of the component has to be called multiple times during a request for different purposes, and the model can be different every time it is called, depending on the operations being performed. Typically, the model has to be rebuilt 3-6 times during a request, whether in lazy mode or not.

If this is causing a performance issue in your application, you can implement some sort of cache in your LazyDataModel implementation to return the same set of results during a lifecycle.

Art Zambrano
ICEsoft Technologies Inc.
artzambrano

Joined: 21/Mar/2007 00:00:00
Messages: 175
Offline


http://jira.icesoft.org/browse/ICE-10880 was created to investigate the possibility of optimizing data loading in lazy mode.

Art Zambrano
ICEsoft Technologies Inc.
PeterReinecke


Joined: 12/Aug/2013 02:41:40
Messages: 29
Offline


This is definitely a bug and not the desired behavior for any user.

If possible, please fix it in the open-source version if IceFaces 4.x.
 
Forum Index -> General Help
Go to:   
Powered by JForum 2.1.7ice © JForum Team