Select to view content in your preferred language

Vector Tile Rebuilding Cache Issues

272
3
10-04-2024 01:41 PM
Labels (1)
HaleyBrueckman1
Emerging Contributor

I have a hosted feature layer and in ArcGIS Online and I created a vector tile service using this existing hosted feature layer. I then created a copy of the vector tile layer and adjusted the symbology to how I needed it. Everything was looking great and working, so I tried the last step which was to edit the hosted feature layer, then rebuild the cache to make sure the edits would be seen in the vector tile layer. As soon as I edited the hosted feature layer the vector tile layer symbology disappeared. I figured it must be because the cache needs to be rebuilt, so I rebuilt it, but still the vector tile does not display anything. I tried both the copy vector tile and the actual hosted vector tile and they both do not display anything now. I figured it could be some unknown issue so I deleted the vector tiles and did the entire process again, and as soon as I edited the hosted feature layer the vector tile failed. I am not sure why this would happen and how to fix it.

0 Kudos
3 Replies
ZaraMatheson
Esri Contributor

Hello! Sorry to hear about this issue. Could you provide some more information on the steps such as how you published the FL, where the symbology was defined, and what kind of edits you made?  If you are able to share any of the data, that would also help. Alternatively, you could open a case with support and work with them to get a reproduction case going. 

0 Kudos
HaleyBrueckman1
Emerging Contributor

Hi, thank you for your help. Here are more detailed steps I followed. First I had a hosted feature layer in AGO that is a line layer for pavement markings on roads. The issue was that I needed the symbology to have enabled scale sizing. So I made a copy of this HFL and updated the symbology in Pro so that it mimicked real world pavement markings and had set sizes for different scales. I then over wrote the HFL so that the published version had the right symbology. It is my understanding that to have enabled scale sizing in AGO it needs to be a vector tile. So in AGO I clicked 'create new' and selected my HFL that I wanted to make the vector tile layer from and I set the tiling schema as ArcGIS Online Basemaps. The symbology I created (see screen shot below) can consist of two lines next to each to mimic highway pavement markings. This appeared to be lost in the vector tile, but I realized the lines were just on top of each other. So in the Vector tile editor I adjusted the symbology so it looked correct. I then saved this as a copy vector tile. Here is the updated symbology code:

{
  "version": 8,
  "sprite": "https://www.arcgis.com/sharing/rest/content/items/22776575ca7c4e3dade11eb380188c10/resources/sprites/sprite-1728072282313",
  "glyphs": "https://vectortileservices3.arcgis.com/AJvcFEp5R1KIH88N/arcgis/rest/services/Pavement_Markings_Feature_Layer_Auth_vectortile/VectorTileServer/resources/fonts/{fontstack}/{range}.pbf",
  "sources": {
    "Pavement_Markings_Feature_Layer_Auth_vectortile": {
      "type": "vector",
      "bounds": [-90.4443, 40.7286, -89.9849, 41.152],
      "minzoom": 0,
      "maxzoom": 23,
      "scheme": "xyz",
      "url": "https://vectortileservices3.arcgis.com/AJvcFEp5R1KIH88N/arcgis/rest/services/Pavement_Markings_Feature_Layer_Auth_vectortile/VectorTileServer",
      "tiles": [
        "https://vectortileservices3.arcgis.com/AJvcFEp5R1KIH88N/arcgis/rest/services/Pavement_Markings_Feature_Layer_Auth_vectortile/VectorTileServer/tile/{z}/{y}/{x}.pbf"
      ]
    }
  },
  "layers": [
    {
      "id": "Pavement_Markings_VectorTile/No Passing Both Directions/1",
      "type": "line",
      "source": "Pavement_Markings_Feature_Layer_Auth_vectortile",
      "source-layer": "Pavement_Markings_VectorTile",
      "filter": [
        "==",
        "_symbol",
        0],
      "layout": {
        "line-join": "round"
      },
      "paint": {
        "line-color": "#FFFF00",
        "line-width": {
          "stops": [
            [14.8524, 1.33333],
            [15.8524, 2.66667],
            [18.1744, 4]
          ]
        },
        "line-offset": -1.33333,
        "line-translate": [4, 4]
      },
      "minzoom": 15
    },
    {
      "id": "Pavement_Markings_VectorTile/No Passing Both Directions/0",
      "type": "line",
      "source": "Pavement_Markings_Feature_Layer_Auth_vectortile",
      "source-layer": "Pavement_Markings_VectorTile",
      "filter": [
        "==",
        "_symbol",
        0],
      "layout": {
        "line-cap": "round",
        "line-join": "round"
      },
      "paint": {
        "line-color": "#FFFF00",
        "line-width": {
          "stops": [
            [14.8524, 1.33333],
            [15.8524, 2.66667],
            [18.1744, 4]
          ]
        },
        "line-offset": -1.33333,
        "line-translate": [-4, -4]
      },
      "minzoom": 15
    },
    {
      "id": "Pavement_Markings_VectorTile/Skip Dash",
      "type": "line",
      "source": "Pavement_Markings_Feature_Layer_Auth_vectortile",
      "source-layer": "Pavement_Markings_VectorTile",
      "filter": [
        "==",
        "_symbol",
        1],
      "layout": {
        "line-join": "round"
      },
      "paint": {
        "line-color": "#FFFF00",
        "line-width": {
          "stops": [
            [12.5305, 1.33333],
            [14.8524, 2.66667],
            [15.8524, 4],
            [18.1744, 5.33333]
          ]
        },
        "line-dasharray": [3, 2]
      },
      "minzoom": 15
    },
    {
      "id": "Pavement_Markings_VectorTile/No Passing EB/1",
      "type": "line",
      "source": "Pavement_Markings_Feature_Layer_Auth_vectortile",
      "source-layer": "Pavement_Markings_VectorTile",
      "filter": [
        "==",
        "_symbol",
        2],
      "layout": {
        "visibility": "visible",
        "line-miter-limit": 2,
        "line-round-limit": 1.05,
        "line-cap": "butt",
        "line-join": "round"
      },
      "paint": {
        "line-opacity": 1,
        "line-color": "#FFFF00",
        "line-width": {
          "stops": [
            [14.8524, 1.33333],
            [15.8524, 2.66667],
            [18.1744, 5.33333]
          ]
        },
        "line-gap-width": 0,
        "line-blur": 0,
        "line-dasharray": [2.5, 2.5],
        "line-translate-anchor": "map",
        "line-offset": -1.33333,
        "line-translate": [-4, -4]
      },
      "minzoom": 15
    },
    {
      "id": "Pavement_Markings_VectorTile/No Passing EB/0",
      "type": "line",
      "source": "Pavement_Markings_Feature_Layer_Auth_vectortile",
      "source-layer": "Pavement_Markings_VectorTile",
      "filter": [
        "==",
        "_symbol",
        2],
      "layout": {
        "visibility": "visible",
        "line-miter-limit": 2,
        "line-round-limit": 1.05,
        "line-cap": "round",
        "line-join": "round"
      },
      "paint": {
        "line-opacity": 1,
        "line-color": "#FFFF00",
        "line-width": {
          "stops": [
            [14.8524, 1.33333],
            [15.8524, 2.66667],
            [18.1744, 5.33333]
          ]
        },
        "line-gap-width": 0,
        "line-blur": 0,
        "line-translate-anchor": "map",
        "line-offset": -1.33333,
        "line-translate": [4, 4]
      },
      "minzoom": 15
    },
    {
      "id": "Pavement_Markings_VectorTile/No Passing NB/1",
      "type": "line",
      "source": "Pavement_Markings_Feature_Layer_Auth_vectortile",
      "source-layer": "Pavement_Markings_VectorTile",
      "filter": [
        "==",
        "_symbol",
        3],
      "layout": {
        "line-join": "round"
      },
      "paint": {
        "line-color": "#FFFF00",
        "line-width": {
          "stops": [
            [14.8524, 2.66667],
            [15.8524, 2.66667],
            [18.1744, 5.33333]
          ]
        },
        "line-offset": -1.33333,
        "line-translate": [4, 4]
      },
      "minzoom": 15
    },
    {
      "id": "Pavement_Markings_VectorTile/No Passing NB/0",
      "type": "line",
      "source": "Pavement_Markings_Feature_Layer_Auth_vectortile",
      "source-layer": "Pavement_Markings_VectorTile",
      "filter": [
        "==",
        "_symbol",
        3],
      "layout": {
        "line-cap": "square",
        "line-join": "round"
      },
      "paint": {
        "line-color": "#FFFF73",
        "line-width": {
          "stops": [
            [14.8524, 2.66667],
            [15.8524, 2.66667],
            [18.1744, 5.33333]
          ]
        },
        "line-dasharray": [2.5, 2.5],
        "line-offset": -1.33333,
        "line-translate": [-4, -4]
      },
      "minzoom": 15
    },
    {
      "id": "Pavement_Markings_VectorTile/No Passing SB/1",
      "type": "line",
      "source": "Pavement_Markings_Feature_Layer_Auth_vectortile",
      "source-layer": "Pavement_Markings_VectorTile",
      "filter": [
        "==",
        "_symbol",
        4],
      "layout": {
        "line-join": "round"
      },
      "paint": {
        "line-color": "#FFFF00",
        "line-width": {
          "stops": [
            [14.8524, 1.33333],
            [15.8524, 2.66667],
            [18.1744, 5.33333]
          ]
        },
        "line-dasharray": [2.5, 2.5],
        "line-offset": -1.33333,
        "line-translate": [4, 4]
      },
      "minzoom": 15
    },
    {
      "id": "Pavement_Markings_VectorTile/No Passing SB/0",
      "type": "line",
      "source": "Pavement_Markings_Feature_Layer_Auth_vectortile",
      "source-layer": "Pavement_Markings_VectorTile",
      "filter": [
        "==",
        "_symbol",
        4],
      "layout": {
        "line-cap": "round",
        "line-join": "round"
      },
      "paint": {
        "line-color": "#FFFF00",
        "line-width": {
          "stops": [
            [14.8524, 1.33333],
            [15.8524, 2.66667],
            [18.1744, 5.33333]
          ]
        },
        "line-offset": -1.33333,
        "line-translate": [-4, -4]
      },
      "minzoom": 15
    },
    {
      "id": "Pavement_Markings_VectorTile/No Passing WB/1",
      "type": "line",
      "source": "Pavement_Markings_Feature_Layer_Auth_vectortile",
      "source-layer": "Pavement_Markings_VectorTile",
      "filter": [
        "==",
        "_symbol",
        5],
      "layout": {
        "visibility": "visible",
        "line-miter-limit": 2,
        "line-round-limit": 1.05,
        "line-cap": "butt",
        "line-join": "round"
      },
      "paint": {
        "line-opacity": 1,
        "line-color": "#FFFF00",
        "line-width": {
          "stops": [
            [14.8524, 1.33333],
            [15.8524, 2.66667],
            [18.1744, 5.33333]
          ]
        },
        "line-gap-width": 0,
        "line-blur": 0,
        "line-translate-anchor": "map",
        "line-offset": -1.33333,
        "line-translate": [-4, -4]
      },
      "minzoom": 15
    },
    {
      "id": "Pavement_Markings_VectorTile/No Passing WB/0",
      "type": "line",
      "source": "Pavement_Markings_Feature_Layer_Auth_vectortile",
      "source-layer": "Pavement_Markings_VectorTile",
      "filter": [
        "==",
        "_symbol",
        5],
      "layout": {
        "visibility": "visible",
        "line-miter-limit": 2,
        "line-round-limit": 1.05,
        "line-cap": "square",
        "line-join": "round"
      },
      "paint": {
        "line-opacity": 1,
        "line-color": "#FFFF73",
        "line-width": {
          "stops": [
            [14.8524, 1.33333],
            [15.8524, 2.66667],
            [18.1744, 5.33333]
          ]
        },
        "line-gap-width": 0,
        "line-blur": 0,
        "line-dasharray": [2.5, 2.5],
        "line-translate-anchor": "map",
        "line-offset": -1.33333,
        "line-translate": [4, 4]
      },
      "minzoom": 15
    },
    {
      "id": "Pavement_Markings_VectorTile",
      "type": "line",
      "source": "Pavement_Markings_Feature_Layer_Auth_vectortile",
      "source-layer": "Pavement_Markings_VectorTile",
      "filter": [
        "==",
        "_symbol",
        6],
      "layout": {
        "line-join": "round"
      },
      "paint": {
        "line-color": "#828282",
        "line-width": 1.33333
      }
    }
  ],
  "metadata": {
    "arcgisStyleUrl": "https://www.arcgis.com/sharing/rest/content/items/22776575ca7c4e3dade11eb380188c10/resources/styles/root.json",
    "arcgisOriginalItemTitle": "Pavement Markings_Feature Layer_Auth_Correct",
    "arcgisQuickEditorWarning": true,
    "arcgisEditorExtents": [
      {
        "spatialReference": {
          "latestWkid": 3857,
          "wkid": 102100
        },
        "xmin": -10052498.3763335,
        "ymin": 4980283.67826083,
        "xmax": -10051016.214582,
        "ymax": 4981436.20532785
      },
      {
        "spatialReference": {
          "wkid": 4326
        },
        "xmin": -90.4443266597069,
        "ymin": 40.7286323587117,
        "xmax": -89.9849006526396,
        "ymax": 41.1520359389015
      },
      {
        "spatialReference": {
          "wkid": 4326
        },
        "xmin": -90.4443266597069,
        "ymin": 40.7286323587117,
        "xmax": -89.9849006526396,
        "ymax": 41.1520359389015
      },
      {
        "spatialReference": {
          "wkid": 4326
        },
        "xmin": -90.4443266597069,
        "ymin": 40.7286323587117,
        "xmax": -89.9849006526396,
        "ymax": 41.1520359389015
      }
    ],
    "arcgisActiveBasemap": "10df2279f9684e4a9f6a7f08febac2a9",
    "arcgisMinimapVisibility": false
  }
}


Now everything looked correct in the web map and the vector tile was working. So I decided to test it by making an edit. The edit was to create a line feature and save it. I saved my edits and then rebuilt the vector tile cache. From the time I saved the edits to now, the vector tile shows no data in the maps anymore.

My guess is that it has something to do with the coordinate systems? My HFL is in NAD 1983 (2011) StatePlane Illinois West FIPS 1202 (US Feet), while my vector tile is in AGO basemaps tiling schema. I am not sure if that matters, but its my only guess at the moment as to why the vector tile data would disappear after edits are made to the associated HFL.

0 Kudos
ZaraMatheson
Esri Contributor

Hello! Thanks for this, I was able to reproduce the issue from this description and we are looking into a fix. It seems to be a combination of the scale based symbology & the mismatch of the coordinate systems. If I get rid of the scale based symbology, everything is ok or if I publish the FL in web mercator, everything is ok. Not sure if one of those options will work for you in the meantime?

0 Kudos