Readonlyrest settings aren't updating

hi, after saving the settings in the readonlyrest kibana plugin, and making sure the document in the elasticsearch index is in-fact updated to the new settings, the changes only appear to be applied to the node in which the kibana updated the index. When attempting to query any of the other nodes in the cluster we receive the results that were available prior to the changes.

for example:
user A had access to indices: test_A_*
change settings in kibana of Node 2 so user A has access to indices test_B_*
user A still sees indices test_A_* when querying Node 1, Node 3, etc.
user A sees indices test_B_* when querying Node2

This is using ReadOnlyRest 1.18.8 on Elasticsearch 6.8.4
Please help solve this issue

upon entering Node 1’s Kibana and pressing “Save” (without changin anything in the file) in the readonlyrest settings Node1 will reflect the changes and only display indices test_B_*

please, setup debug logs and look for logs like this:
“[CLUSTERWIDE SETTINGS] Loading ReadonlyREST config from index …”

If you don’t see it, maybe in-index settings checking is disabled. But then, at the ROR startup you should see log like this:
“[CLUSTERWIDE SETTINGS] Scheduling in-index settings check disabled”

Tried setting the logs to debug - there were indeed periodic [CLUSTERWIDE SETTINGS] with scheduling enabled - after I made a change to the configuration it has loaded that change too - after which no more [CLUSTERWIDE SETTINGS] lines have appeared. I think the problem may be that the in-index settings doesn’t schedule further checks once changes have occurred and been fetched from the index.

I finally succeed with reproducing the issue. I’ll send you tomorrow prebuild with fix to test.

1 Like

here is a prebuild for you:

1 Like