There is a fragment in which the graph is built (MPAndroidChart), the data for the graph itself comes from the service (server). When the fragment is open - everything works the chart is drawn.
The essence of the problem: how to update the graph in the fragment when it is closed, and restore them when it is open?