@aaron-nimocks thanks for your response. Here are the specs. I have reduced the number of data points to 10 so that it can be easily accommodated here. The problem still persists even with 10 data points.
{
"$schema": "https://vega.github.io/schema/vega/v4.json",
"description": "A basic scatter plot",
"padding": 5,
"data": {
"name": "source",
"format": {
"property": "hits.hits"
},
"transform": [
{
"type": "formula",
"as": "time",
"expr": "toDate(datum._source['@timestamp'])"
}
],
"url": {
"index": "alb-logs-*",
"body": {
"size": 10,
"_source": [
"@timestamp",
"elb_received_bytes"
],
"query": {
"bool": {
"must": [
{
"range": {
"@timestamp": {
"gte": "2021-02-18T00:47:15.704Z",
"lte": "2021-02-18T01:02:15.704Z",
"format": "strict_date_optional_time"
}
}
}
],
"filter": [
{
"match_all": {}
}
],
"should": [],
"must_not": []
}
}
}
},
"values": {
"took": 6,
"timed_out": false,
"_shards": {
"total": 3,
"successful": 3,
"skipped": 2,
"failed": 0
},
"hits": {
"total": 1487,
"max_score": 1,
"hits": [
{
"_index": "alb-logs-2021.02",
"_type": "_doc",
"_id": "6ViesncBHSONY29jDXEY",
"_score": 1,
"_source": {
"@timestamp": "2021-02-18T00:47:36.638Z",
"elb_received_bytes": "236"
},
"time": 1613609256638
},
{
"_index": "alb-logs-2021.02",
"_type": "_doc",
"_id": "6liesncBHSONY29jDXEY",
"_score": 1,
"_source": {
"@timestamp": "2021-02-18T00:48:04.753Z",
"elb_received_bytes": "236"
},
"time": 1613609284753
},
{
"_index": "alb-logs-2021.02",
"_type": "_doc",
"_id": "61iesncBHSONY29jDXEY",
"_score": 1,
"_source": {
"@timestamp": "2021-02-18T00:47:23.721Z",
"elb_received_bytes": "202"
},
"time": 1613609243721
},
{
"_index": "alb-logs-2021.02",
"_type": "_doc",
"_id": "7FiesncBHSONY29jDXEY",
"_score": 1,
"_source": {
"@timestamp": "2021-02-18T00:47:48.237Z",
"elb_received_bytes": "449"
},
"time": 1613609268237
},
{
"_index": "alb-logs-2021.02",
"_type": "_doc",
"_id": "7ViesncBHSONY29jDXEY",
"_score": 1,
"_source": {
"@timestamp": "2021-02-18T00:47:53.094Z",
"elb_received_bytes": "241"
},
"time": 1613609273094
},
{
"_index": "alb-logs-2021.02",
"_type": "_doc",
"_id": "7liesncBHSONY29jDXEY",
"_score": 1,
"_source": {
"@timestamp": "2021-02-18T00:47:59.482Z",
"elb_received_bytes": "69"
},
"time": 1613609279482
},
{
"_index": "alb-logs-2021.02",
"_type": "_doc",
"_id": "71iesncBHSONY29jDXEY",
"_score": 1,
"_source": {
"@timestamp": "2021-02-18T00:48:11.755Z",
"elb_received_bytes": "165"
},
"time": 1613609291755
},
{
"_index": "alb-logs-2021.02",
"_type": "_doc",
"_id": "8FiesncBHSONY29jDXEY",
"_score": 1,
"_source": {
"@timestamp": "2021-02-18T00:48:20.981Z",
"elb_received_bytes": "1373"
},
"time": 1613609300981
},
{
"_index": "alb-logs-2021.02",
"_type": "_doc",
"_id": "8ViesncBHSONY29jDXEY",
"_score": 1,
"_source": {
"@timestamp": "2021-02-18T00:48:20.258Z",
"elb_received_bytes": "161"
},
"time": 1613609300258
},
{
"_index": "alb-logs-2021.02",
"_type": "_doc",
"_id": "8liesncBHSONY29jDXEY",
"_score": 1,
"_source": {
"@timestamp": "2021-02-18T00:48:21.460Z",
"elb_received_bytes": "90"
},
"time": 1613609301460
}
]
}
}
},
"scales": [
{
"name": "x",
"type": "time",
"round": true,
"nice": true,
"zero": true,
"domain": {
"data": "source",
"field": "time"
},
"range": "width"
},
{
"name": "y",
"type": "linear",
"round": true,
"nice": true,
"zero": true,
"domain": {
"data": "source",
"field": "_source.elb_received_bytes"
},
"range": "height"
}
],
"axes": [
{
"scale": "x",
"grid": true,
"domain": false,
"orient": "bottom",
"tickCount": 5,
"title": "Time"
},
{
"scale": "y",
"grid": true,
"domain": false,
"orient": "left",
"titlePadding": 5,
"title": "Bytes"
}
],
"marks": [
{
"name": "marks",
"type": "symbol",
"from": {
"data": "source"
},
"encode": {
"update": {
"x": {
"scale": "x",
"field": "time"
},
"y": {
"scale": "y",
"field": "_source.elb_received_bytes"
},
"shape": {
"value": "circle"
},
"strokeWidth": {
"value": 2
},
"opacity": {
"value": 0.5
},
"stroke": {
"value": "#4682b4"
},
"fill": {
"value": "transparent"
}
}
}
}
],
"config": {
"range": {
"category": {
"scheme": "elastic"
}
},
"arc": {
"fill": "#54B399"
},
"area": {
"fill": "#54B399"
},
"line": {
"stroke": "#54B399"
},
"path": {
"stroke": "#54B399"
},
"rect": {
"fill": "#54B399"
},
"rule": {
"stroke": "#54B399"
},
"shape": {
"stroke": "#54B399"
},
"symbol": {
"fill": "#54B399"
},
"trail": {
"fill": "#54B399"
},
"title": {
"color": "#343741"
},
"style": {
"guide-label": {
"fill": "#69707d"
},
"guide-title": {
"fill": "#343741"
},
"group-title": {
"fill": "#343741"
},
"group-subtitle": {
"fill": "#343741"
}
},
"axis": {
"tickColor": "#eef0f3",
"domainColor": "#eef0f3",
"gridColor": "#eef0f3"
},
"background": "transparent"
},
"width": "container",
"height": "container",
"autosize": {
"type": "fit",
"contains": "padding"
}
}