-
Notifications
You must be signed in to change notification settings - Fork 8.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Maps] Add 3rd party vector tile support #62084
[Maps] Add 3rd party vector tile support #62084
Conversation
Pinging @elastic/kibana-gis (Team:Geo) |
This is a lot of fun!! Tested locally, I couldn't use EMS tiles on my set up, but worked smoothly with another tile provider. You have already captured all small UI things I also noticed (reusing the source, tooltips, style-driven rendering). For what is worth, I used this snippet to get the names of the layers using vt2geojson: $ vt2geojson https://url.tile.provider/0/0/0.mvt | jq -c ".features[].properties.vt_layer" | uniq
"water"
"landcover"
"boundary"
"water_name"
"place" Note that layers change depending on the zoom level. |
thanks @jsanz for checking out! This PR is a little too rough around the edges for detailed reviewed, but we should certainly discuss scope on this. I'm looking to dial in additional functionality in small steps, but we probably want to avoid getting in a situation where we merged something in master/7.x that isn't feature complete enough to be useful. An interim option, in absence of clearly defined boundaries, might to hide the vector-tile layer-type behind a feature-flag in the 7.x branch (could keep this enabled by default in master) ? |
+1 on keeping this behind a feature flag, maybe some folks will benefit from it if they really know their trade, but for most of our users, this would be confusing at this moment. |
x-pack/legacy/plugins/maps/public/connected_components/layer_panel/layer_settings/index.js
Outdated
Show resolved
Hide resolved
.../maps/public/layers/sources/mvt_single_layer_vector_source/mvt_single_layer_vector_source.ts
Outdated
Show resolved
Hide resolved
.../maps/public/layers/sources/mvt_single_layer_vector_source/mvt_single_layer_vector_source.ts
Show resolved
Hide resolved
...blic/layers/sources/mvt_single_layer_vector_source/mvt_single_layer_vector_source_editor.tsx
Outdated
Show resolved
Hide resolved
...blic/layers/sources/mvt_single_layer_vector_source/mvt_single_layer_vector_source_editor.tsx
Outdated
Show resolved
Hide resolved
...blic/layers/sources/mvt_single_layer_vector_source/mvt_single_layer_vector_source_editor.tsx
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
App Arch code changes LGTM
return new TiledVectorLayer(vectorLayerArguments); | ||
} | ||
|
||
getGeoJsonWithMeta( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can this be deleted? This no longer implements VectorSource so no need for the method
...blic/layers/sources/mvt_single_layer_vector_source/mvt_single_layer_vector_source_editor.tsx
Outdated
Show resolved
Hide resolved
...blic/layers/sources/mvt_single_layer_vector_source/mvt_single_layer_vector_source_editor.tsx
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm with green CI
code review, tested in chrome
💚 Build SucceededHistory
To update your PR or re-run it, just comment with: |
Adds support for adding an external vector tile service to Maps. This is experimental functionality. To enable, add `xpack.maps.enableVectorTiles: true` to the `kibana.yml`configuration file.
* master: (40 commits) [APM]Upgrade apm-rum agent to latest version to fix full page reload (elastic#63723) add deprecation warning for legacy 3rd party plugins (elastic#62401) Migrate timelion vis (elastic#62819) Replacebad scope link with actual values (elastic#63444) Index pattern management UI -> TypeScript and New Platform Ready (create_index_pattern_wizard) (elastic#63111) [SIEM] Threat hunting enhancements: Filter for/out value, Show top field, Copy to Clipboard, Draggable chart legends (elastic#61207) [Maps] fix term join agg key collision (elastic#63324) [Ingest] Fix agent config key sorting (elastic#63488) [Monitoring] Fixed server response errors (elastic#63181) update elastic charts to 18.3.0 (elastic#63732) Start services (elastic#63720) [APM] Encode spaces when creating ML job (elastic#63683) Uptime 7.7 docs (elastic#62228) [DOCS] Updates remote cluster and ccr docs (elastic#63517) [Maps] Add 3rd party vector tile support (elastic#62084) [Endpoint][EPM] Retrieve Index Pattern from Ingest Manager (elastic#63016) [Endpoint] Host Details Policy Response Panel (elastic#63518) [Uptime] Certificate expiration threshold settings (elastic#63682) Refactor saved object types to use `namespaceType` (elastic#63217) [SIEM][CASE] Create comments sequentially (elastic#63692) ...
Looks like this PR has a backport PR but it still hasn't been merged. Please merge it ASAP to keep the branches relatively in sync. |
Adds support for adding an external vector tile service to Maps. This is experimental functionality. To enable, add `xpack.maps.enableVectorTiles: true` to the `kibana.yml`configuration file. Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
@kmartastic yes, do you have a preference? |
This adds the core boilerplate to Maps to display vector-tiles as first-class layer.
Introduces:
TiledVectorLayer
): the layer that is added to the layer-listITiledSingleLayerVectorSource
): a source which models a url-template and layer-name. It is restricted to a single source-layer.The scope is limited to keep this PR small. Below features should be added in other PRs.
Note that the endgoal is primarly to support tiling from Elasticsearch data, which also informs some of the limitations discussed above (ie. single source-layer, no TileJson support)
Reviewer notes:
this PR is stuck in the TS-swamp for a moment, please disregard compilation errors. Will aim to address this some of the larger TS-issues in other PRs. (cf. [Maps] Cleanup sources #63175)To test:
kibana[.dev].yml
.xpack.maps.enableVectorTiles: true