Closed allisonmuise closed 5 years ago
Note: Sajit's testing showed that the app appeared to be pulling in cached values on load. A browser refresh did not reliably pull in updated content.
I was getting the same result with my browser debugger open and browser caching turned off.
Started branch support-faster-changing-data
with a commit containing a cache-breaker for the main list query.
@MikeTschudi Could you take a look at this for 7.1? Please install into the develop branch and devtopia when ready. Code freeze is Feb 14.
@CTLocalGovTeam Would you be able to take a look at this issue for 7.1? I've merged in Mike's branch with the cache-breaker. The remaining work is to ensure that updated data is retrieved when browsing the app.
Per Mike: 1) Update the home page graphics with whatever is retrieved from the high-detail query. 2) Maybe hook into a feature layer's update or refresh-tick events to update layer contents.
The use case that prompted this was one where the app was being used to display election results. The data source was updated periodically, but the details available for each feature reflected what was available at app load, not the data values at the time the details view was accessed for a feature/the list of features was opened/revisited.
If this work is not possible for this release (need PR by Feb 11), please let me know.
@allisonmuise
Here is our understanding from the above comments :
Please let us know if anything else is to be incorporated apart from the above mentioned functionalities.
@ashishchoure This sounds right to me!
@allisonmuise @MikeTschudi
We have analyzed this ticket and here is our approach to implement the same.
Feature Selection :
Layer's refresh interval :
Please let us know if this approach looks good.
@MikeTschudi Does this approach follow the work you understood to be necessary?
@ashishchoure, why, please, do you suggest delaying handling the refresh-tick event when the user is on the item details screen? If a user is viewing the details and new comments come in from the refresh-tick event, they are relevant. Only if the user is actively entering his/her own comment does it seem like new comments should be delayed.
Feature selection approach sounds good. (I wish that you didn't have to work around the JSAPI swallowing the feature update!)
@MikeTschudi @allisonmuise
@ashishchoure, thanks for the explanation; it all sounds good!
@aparveen @LindsayThomas Want to test this with the elections data?
@allisonmuise I will test it.
@allisonmuise Can you please confirm this repro scenario? (I am aware of the issue but I don't know the technical details)
Create an application using hosted feature layer for crowdsource polling In the web map - set the refresh interval to 0.1 on each layer configure the application with these layers, and a field that you will update Bring up the application
In another browser, bring up the webmap item, go to the data tab and update the field that you have configured in the application.
You should see the field that you are updating, updating the application side panel
(You can use any data to test this)
@LindsayThomas I'm not sure.
@MikeTschudi or @ashishchoure can you confirm that this is a valid repro scenario.
@allisonmuise @LindsayThomas
The above scenario sounds correct.
Here are the list of scenarios which we have considered while testing :
Verified in devext.
Hi Allison,
CP updates in this order:
If the user chooses to go back to the main list, CP queries all features for the main list display of items again.
CP does not do dynamic updates. We could enhance the app by hooking into the automatic refresh cycle that the map is using.
There is something that I think that we should change to support faster-changing data sets, however: The app should update the item details using the results of the higher-res graphics query. And the item details display should wait for these results before displaying the details to avoid a confusing flash of potentially obsolete values. This is less than a day’s work, but I think that it’s important: The longer the time gap between displaying the main panel and jumping to any one of its items, the more the item details will be out of date.
Mike