I am having an issue where I am using a hosted feature layer to create a Web Map, which in turn is being used in a Web Mapping Application on ArcGIS Online. I have a model that runs nightly to update my data which is working fine. However, the problem is that when I label the features(points) in my web map, the symbology disappears from my application. My current fix for this is to rebuild the spatial index of the hosted feature layer, which makes the symbology show up again. Is there something I can do to prevent this from happening? Has anyone experienced something like this before?
Solved! Go to Solution.
It looks like when you are updating the service the layers extent is getting set to null
"useStandardizedQueries" : true, "geometryType" : "esriGeometryPoint", "minScale" : 0, "maxScale" : 0, "extent" : null,
the layer throws an error when querying in 3.x
Rebuilding the index is probably fixing that null layer extent which the 3.x JSAPI (Map Viewer Classic, Web AppBuilder) is needing to draw the features.
Another thing I noticed
The labels also use a scale range which is not supported in WAB apps and other 3.x JSAPI apps like Map Viewer Classic and would recommend migrating to Experience Builder or Instant apps so you can take advantage of this plus additional web map enhancements we have made and WAB is on retirement roadmap.
Can you share the web map and layer when it is this state and I can take a look.
Layer - WaterServices_Prod - Overview (arcgis.com)
Map - Get The Lead Out Prod - Overview (arcgis.com)
App - Get The Lead Out App - Overview (arcgis.com)
Its currently fixed but will run again at 1am tomorrow morning and be broken again.
Thank you, It is currently in the "Broken" state
thanks taking a look
It looks like when you are updating the service the layers extent is getting set to null
"useStandardizedQueries" : true, "geometryType" : "esriGeometryPoint", "minScale" : 0, "maxScale" : 0, "extent" : null,
the layer throws an error when querying in 3.x
Rebuilding the index is probably fixing that null layer extent which the 3.x JSAPI (Map Viewer Classic, Web AppBuilder) is needing to draw the features.
Another thing I noticed
The labels also use a scale range which is not supported in WAB apps and other 3.x JSAPI apps like Map Viewer Classic and would recommend migrating to Experience Builder or Instant apps so you can take advantage of this plus additional web map enhancements we have made and WAB is on retirement roadmap.
Thank you for the quick reply, opening it in experience builder did seem to fix the issue.
Do you have any recommendation for getting it to work in WAB?
This is a public facing map that has taken a while to get exactly how my team wants it, and trying to replicate it exactly is going to be a pain.
I think you will have to see where in the model the layer extent is getting set to null which would solve the display issue.
For migrating to ExB you would use the same web map as the data source and then configure the panels/tools you need in the app to mirror what you are using in the WAB version.