i am using liferay 6.1 and jsf 2.2 and primefaces 3.3
i have two lists displayed using tree component in two different portlets and both portlets are on different pages.
and both lists are coming from the database from the same table.
when i add something to the table using third portlet it gets added to the table in the database.
so i want other two lists(Tree structure) on different portlets should get updated with the new data.
how it is possible.?
First, realize that regardless of whether a portlet is on the same page or a different page, each portlet instance is operating on its own classpath. And that therefore, they cannot share data models.
Secondly, you have the constraint that HTTP is purely a request/response cycle processor. So the only way to update any webpage at all, whether in part or in full is to send a request to the server and render from its response. Fortunately these days we have AJAX support for partial page rendering at timed intervals. Otherwise the entire portal page would have to be re-rendered. At the cost of making requests to each and every portlet on the page, irrespective of whether or not it was part of the problem set.
Thirdly, you have the problem of getting the portlet UI models up to date. Which, in turn, depends on getting their domain models up to date, if you are using an ORM. Since a change in one app's domain model does not automatically reflect in the domain models of any related apps, you'll need a mechanism to either poll for or be notified of any changes to the data domain attached to each portlet's domain model. For best performance, that means that you also should have a good cache mechanism backing the ORM.
One you have all those items covered, then you'll probably want to optimize the refreshing mechanisms to improve response and reduce overhead. But don't do that until AFTER you have the brute-force mechanisms working, or it will be murder to debug.
Customer surveys are for companies who didn't pay proper attention to begin with.