I'm using Primefaces4.0
, JSF 2.0
and Tomahawk2.0
I have an p:fileUpload
which actually read data call some procedures and show results after in t:dataTable
using update
I am facing a problem, If file is too large it take couple of seconds to show results (30-40 sec) which is not good practice.
I want to Populate t:dataTable
in each of the iteration of for loop which is reading values, call procedure and show result.
To update any component from ManagedBean, you can use Primefaces's update()
method on RequestContext .
RequestContext.getCurrentInstance() .update("component_ID")
But I doubt that this will solve you problem.
Because RequestContext's methods will take affect when Response is returned from ManagedBean.
And that won't happen after every iteration of loop, it happens when Action method is completed.
A preferred and better way to handle huge data population in DataTable is to use the LazyModel.