You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Trying to delete data using the /query 1.x compatibility API, fails with an incorrect error "default retention policy not set for: my_db"
environment
OS: Debian: GNU/Linux 12 (bookworm)
influx version: Influx CLI dev (git: a79a2a1) build_date: 2024-04-16T14:34:32Z
retention periods for the bucket in question:
SHOW RETENTION POLICIES ON my_db (queried also using the 1.x compatibility API)
name,tags,name,duration,shardGroupDuration,replicaN,default
,,autogen,0s,168h0m0s,replicaN,true
--> Is this also a bug? when executed in the v1 shell, the query returns:
SHOW RETENTION POLICIES ON my_db
name,duration,shardGroupDuration,replicaN,default
autogen,0s,168h0m0s,1,true
steps to reproduce
execute a DELETE query using the /query 1.x compatibility API:
if the token has only read permission on my_db, the error message is correct: "error":"insufficient permissions"
if the token has only write permission on my_db, the error message is incorrect (this bug): "error":"default retention policy not set for: my_db"
if the token has read and write permission on my_db, the query is executed successfully (data is deleted).
So when deleting data via a query, you need read permission. This should be documented, because it is not intuitive and the error message is misleading
Trying to delete data using the /query 1.x compatibility API, fails with an incorrect error "default retention policy not set for: my_db"
environment
--> Is this also a bug? when executed in the v1 shell, the query returns:
steps to reproduce
expected result
data with the indicated timestamp is deleted
actual result
the API returns:
{"results":[{"statement_id":0,"error":"default retention policy not set for: my_db"}]}
The text was updated successfully, but these errors were encountered: