Hi all,
I would like to know from Grafana 10.3.0 if it is mandatory to add a data source to the panel plugin in the edit mode to get timerange value in the panel component timerange/data prop? I have built a panel plugin which does a cyclic replay of the timerange selected from Grafana dashboard default time picker. My panel plugin contains a play and pause button and a custom slider which acts the same as a video player slider where you can skip forward or come backwards to a specific time within the selected timerange and of course, the play starts the cyclic playback and pause means pausing the play. And my cyclic playback involves changing the timerange of grafana dashboard itself using onChangeTimeRange method Grafana provides. So I am dependent on timerange value from the dashboard in my panel component. As this plugin is not dependent on any data except timerange, I don’t have any datasource configured with it and this was working on grafana versions 10.2.0 and below. But from 10.3.0 and above, my panel component timerange prop doesn’t even get triggered on the first render unless I add a datasource to it.
The idea was to do a cyclic playback of whatever time range is selected and that is it. But now I have to add a datasource and if there is no data present for that selected time then there is no metrics value to be used as a query. I have to manually run a query like - ‘timestamp’ if there is no data to make it work again.
I am pretty new to Grafana and its environment. I am learning and getting to know it day by day. I would like to know if this is a default behaviour set from 10.3.0+ versions. Is there any way I can still use the cyclic playback plugin without a datasource and still get the timerange updated value in my panel component?
Thank you.