elastic / kibana

Your window into the Elastic Stack
https://www.elastic.co/products/kibana
Other
19.71k stars 8.12k forks source link

Vega Time Scrolling #95933

Closed dutang-a closed 3 years ago

dutang-a commented 3 years ago

Kibana version: 12.0 Elasticsearch version: 12.0 Server OS version: CentOS Browser version: Chrome Browser OS version:

Original install method (e.g. download page, yum, from source, etc.): Docker Describe the bug:

I'm not sure if I've made an error on my side but it seems as though not all vega features are compatible with tile map layering which seems pretty odd since these two features seem unrelated on face value. In my case I'm attempting to plot geo points with an external time scrolling filter. The implementation of this feature functioned in kibana 10.0 but with the same specification fails in 12.0.

This feature is working in version 10 before the fix provided by #87853.

Steps to reproduce:

{
 "$schema": "https://vega.github.io/schema/vega-lite/v2.json",
 config: {
   kibana: {
     type: map
     mapStyle: road_map
   }
 },
 "data": {
   "format": {
     "property": "aggregations.date_hist.buckets"
   },
   "values": {
     "took": 5,
     "timed_out": false,
     "_shards": {
       "total": 8,
       "successful": 8,
       "skipped": 0,
       "failed": 0
     },
     "hits": {
       "total": 12081,
       "max_score": null,
       "hits": []
     },
     "aggregations": {
       "date_hist": {
         "buckets": [
           {
             "key_as_string": "2020-10-25T04:26:40.000Z",
             "key": 1603600000000,
             "doc_count": 455,
             "centroid": {
               "location": {
                 "lat": 39.41406083338865,
                 "lon": -87.45705620088067
               },
               "count": 194
             }
           },
           {
             "key_as_string": "2020-10-26T08:13:20.000Z",
             "key": 1603700000000,
             "doc_count": 4606,
             "centroid": {
               "location": {
                 "lat": 39.41456017672054,
                 "lon": -87.45740849762754
               },
               "count": 3142
             }
           },
           {
             "key_as_string": "2020-10-27T12:00:00.000Z",
             "key": 1603800000000,
             "doc_count": 6587,
             "centroid": {
               "location": {
                 "lat": 39.414689194528215,
                 "lon": -87.45236261728247
               },
               "count": 1526
             }
           },
           {
             "key_as_string": "2020-10-28T15:46:40.000Z",
             "key": 1603900000000,
             "doc_count": 433,
             "centroid": {
               "location": {
                 "lat": 39.414511129774745,
                 "lon": -87.44176032781405
               },
               "count": 190
             }
           }
         ]
       }
     }
   }
 },
 "transform": [
   {
     "filter": {
       "selection": "Time Filter"
     }
   },
   {
     "filter": "datum.centroid.count > 0"
   }
 ],
 "selection": {
   "Time Filter": {
     "type": "single",
     "fields": [
       "key"
     ],
     "bind": {
       "input": "range",
       "min": 1603600000000,
       "max": 1603900000000,
       "step": 100000000,
       "name": "Time Filter"
     }
   }
 },
 "mark": "circle",
 "encoding": {
   "longitude": {
     "field": "centroid.location.lon",
     "type": "quantitative"
   },
   "latitude": {
     "field": "centroid.location.lat",
     "type": "quantitative"
   },
   "size": {
     "value": 200
   },
   "color": {
     "value": "steelblue"
   }
 }
}

Expected behavior:

Screenshots (if relevant): Kibana V10 -- what the plot is suppose to look like VegaMap0

Kibana V12 -- no scroller at the bottom

VegaMap1

Errors in browser console (if relevant):

Provide logs and/or server output (if relevant):

Any additional context:

elasticmachine commented 3 years ago

Pinging @elastic/kibana-app (Team:KibanaApp)

alexwizp commented 3 years ago

It looks more like a regression from #88605. Thank you for that case