Custom Vector Tile

636
3
Jump to solution
12-08-2020 12:52 PM
Namibian
New Contributor II

Hi,

I have have my own vector tile server that serves vector tiles to my application which I then use to create a VectorTileLayer with custom styling. This layer represents US Zip Codes.

I want to select zip codes that fall within a specified geometry from this VectorTileLayer. Is this at all possible? If not, is there a plan to provide this kind of functionality similar to what is available in mapbox-gl?

As an alternative, should I parse the .pbf data returned by the call to my tile server, create a geojson structure, and then use that to create a FeatureLayer (which I know I can query). I would hate to go down that road as it seems like a ton of work if VectorTileLayer querying is on the horizon.

Any help and insights is greatly appreciated!

 

Cheers!

0 Kudos
1 Solution

Accepted Solutions
mgeorge
Esri Contributor

Hi @Namibian!

It's definitely on our road-map, but there's still quite a lot of work we need to do on our end to support all of the querying stuff that FeatureLayers are currently capable of for VTL. Probably 4.20-4.21 is the earliest possible release we might see this, but that's not a hard date and it could come significantly later. 

Parsing the  PBF from the VTL may be problematic -- each VectorTile will return quantized data that's generalized for the LOD the tile is for ... so you would need to constantly be adding/removing features as the LOD changes. The performance for this would probably not be great, but may be OK if we are talking low feature counts. 

The "esri" way of handling this would be to use a FeatureService instead. A hosted feature service would have the best client performance because of the optimizations we do to handle this (esri FeatureTile PBF format, paged queries). We also recently added support for OGC Feature services which is another option. Fairly certain there are several open source service implementation for those. Performance there will be worse (unfortunately support for quantization/generalization/pbf is not yet standardized), but depending on your use case it could be sufficient. 

View solution in original post

3 Replies
mgeorge
Esri Contributor

Hi @Namibian!

It's definitely on our road-map, but there's still quite a lot of work we need to do on our end to support all of the querying stuff that FeatureLayers are currently capable of for VTL. Probably 4.20-4.21 is the earliest possible release we might see this, but that's not a hard date and it could come significantly later. 

Parsing the  PBF from the VTL may be problematic -- each VectorTile will return quantized data that's generalized for the LOD the tile is for ... so you would need to constantly be adding/removing features as the LOD changes. The performance for this would probably not be great, but may be OK if we are talking low feature counts. 

The "esri" way of handling this would be to use a FeatureService instead. A hosted feature service would have the best client performance because of the optimizations we do to handle this (esri FeatureTile PBF format, paged queries). We also recently added support for OGC Feature services which is another option. Fairly certain there are several open source service implementation for those. Performance there will be worse (unfortunately support for quantization/generalization/pbf is not yet standardized), but depending on your use case it could be sufficient. 

Namibian
New Contributor II
Thank you for you thorough response.

I am currently exploring the FeatureService and that does seem promising.
Is there a specific setting I need to turn on to enable caching when using
the FeatureService? Also, what is the cost ($ value) per request. I have
potentially 100k customers that will use my application and I am concerned
about the cost when they so a lot of zooming and panning of the map
0 Kudos
mgeorge
Esri Contributor

Sorry @Namibian, I'm just a rendering dev on the JSAPI so I'm probably not the best person to ask about that :grinning_face_with_sweat: Take this with a grain of salt because I'm really not sure about this, and I would definitely reach out to support for questions because they will know this stuff a lot better, but I think you need one of the paid plans (assuming commercial use, see https://developers.arcgis.com/pricing/compare-plans/) and then the credit costs are list here: https://developers.arcgis.com/pricing/credits/. 

For hosted feature services I would look at https://developers.arcgis.com/features/hosted-data/ (scroll to the bottom to see the pricing chart)

From what I understand, you pay for storage, but not for individual feature tile requests. For caching that should be turned on automatically I believe.