When, in a Data Frame Properties General tab, you check the box "Allow assignement of unique numeric IDs for map service publishing", the software could assign unique numbers to any layer that doesn't already have one, rather than assigning a -1 to everything. It requires a lot of manual tedium to go in and assign those numbers to every layer and group sublayer. This is even more cumbersom when annotation layers are involved, and ArcMap treats every annotation value as its own layer!!
Since these numbers now don't have to change in the REST endpoint whenever the layer order is changed, or a new layer inserted, who cares what the numbers actually are, so long as they are unique. (Think object.id's for feature classes.)
What version of ArcGIS are you running on?
ArcMap 10.5.1 actualy does automatic numbering of 'Layer ID' in Layer Properties - General tab (there is nowhere -1 value). But for a complex services, wit a lot of layers, it would be great to have a tool to set 'Layer ID' for every layer in one place (I care what the numbers actually are).
We found the automatic numbering works well except for when you have group layers. There is a bug where it will assign the same ID twice to an outer layer and inner group layer. This only happens when converting and already established MXD to "Custom Static Specified IDs" since if that is the setting from the start when ArcMap seems to know how to roll.
I'm wondering if this idea was actually a bug at the time that has since been resolved. See https://support.esri.com/en/bugs/nimbus/QlVHLTAwMDA5MjUwNA==
Though it sounds like there could be some cases where annotation and group layers are involved that may not work optimally. If you're seeing specific issue in ArcMap 10.8.1 or ArcGIS Pro 2.8 could you please comment below? Thanks
Looks like this is still an issue in Pro 2.9.8. We just published services that had feature classes, tables, and annotation group layers. If there is a conflict of id's between annotation layers with the same layer type or different, it does not seem to give any warnings during publish but you see that the id's get changed after publishing. It took a while to figure this out why this is happening.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.