Elasticsearch version:
7.9.3 + sg plugin 47.0.0
Server OS version:
Centos 7
Kibana version
Kibana 7.8.1 + kibana sg plugin 43.0.0
Hi,
I would like to add dls filter into sg role.
I tried a few different queries but without succes.
Here what i tried:
{"query": { "bool": {"must": [ {"range": { "@timestamp": { "gte": "now-90d/d" } }} ]} } }
{ "query": { "bool": {"must": [ {"match_all":{}},{"range": { "@timestamp": { "gte": "now-90d/d" } }} ]} }}
{ "bool": {"must": [ {"match_all":{}},{"range": { "@timestamp": { "gte": "now-90d/d" } }} ]} }
{ "bool": {"must": [ {"match_all":{}},{"range": { "@timestamp": { "gte": "now-90d/d", "lte": "now/d" } }} ]} }
I added role without dls filter, afterthat i added index-pattern of that index. When i modifed role and added dls filter, in Discover i have this info:
{
"took": 4498,
"timed_out": false,
"_shards": {
"total": 1014,
"successful": 991,
"skipped": 991,
"failed": 23,
"failures": [
{
"shard": 0,
"index": "network-devices-dd-2021.06.03-000037",
"node": "MKPoUHwvRGOLUDbQ2A8XdQ",
"reason": {
"type": "query_shard_exception",
"reason": "failed to create query: could not read the current timestamp",
"index_uuid": "q63yv0ORRWWs9Rpo0BPQhw",
"index": "network-devices-dd-2021.06.03-000037",
"caused_by": {
"type": "parse_exception",
"reason": "could not read the current timestamp",
"caused_by": {
"type": "illegal_argument_exception",
"reason": "'now' is not allowed in DLS queries"
}
}
}
},
...
Would you be so kind and help with that query?