Triggering a scan of [dashboards.json] dir instead of auto-scanning every minute

I am using the [dashboards.json] facility in the Grafana .ini file as follows…

enabled = true
path = /path/to/my/dashboard/directory

Once per day I have cron scripts that execute, scan my infrastructure for changes (port up/down, find new routers, discover new servers, etc.) and generate all new JSON dashboard files that go in the aforementioned directory. After my dashboard generator scripts are done, this directory ends up with more than 14,000 files in it. Yes, I have more than fourteen thousand dashboards, all of which are unique. If you really want to know, 13,000 of them are small routers.

Every 60 seconds, the grafana-server process uses a bunch of CPU scanning this dir. Instead of auto scanning this dir every 60 seconds I would like to trigger a scan only after my JSON dashboard scripts are run. Is there a way to do this?

Thank you for your time and awesome product.

Currently there is not a way to do this. There is no toggle to turn off the update loop and there is no way to update the index manually.

The json_index.go class contains the logic for this. A goroutine is kicked off when Grafana starts and loops once a minute. There is no way to call updateIndex via the API and the loop time is hardcoded to 1 minute.