Here is an example of something we are trying to do:
<s:url id="regionList" action="json/workUnitType"
method="regions" />
<sj:select href="%{regionList}" name="regionId" list="regions"
headerKey="-1" headerValue="Please Select" listKey="value"
listValue="label"
onSuccessTopics="regionChanged"
onChangeTopics="regionChanged" />
<s:url id="workUnitTypeList" action="json/workUnitType"
method="workUnitTypesByRegion" />
<sj:select href="%{workUnitTypeList}" name="workUnitTypeId"
list="workUnitTypes"
headerKey="-1" headerValue="Please Select" listKey="value"
listValue="label"
reloadTopics="regionChanged"
onSuccessTopics="workUnitTypeChanged"
onChangeTopics="workUnitTypeChanged" />
<s:url id="targetDateField" action="loadFields"
method="targetDate" />
<sj:div href="%{targetDateField}" formIds="loadOneForm"
reloadTopics="workUnitTypeChanged" />
Firebug then shows the following requests when the page loads:
/json/workUnitType!regions.action
/json/workUnitType!workUnitTypesByRegion.action
/loadFields!targetDate.action
/json/workUnitType!workUnitTypesByRegion.action
/loadFields!targetDate.action
/loadFields!targetDate.action
There are one request for the first select, two requests for the
second select, and three requests for the div. However, if they all
were aware of their inter-dependencies and loaded in the correct
order, only one request for each should really be necessary. Now the
real page actually has several divs driven by the second select box,
so there are actually several more requests - but they each load three
times. This is what I imagine "deferredLoading" would resolve.