Fix sidebar and legend tracking of graph labels

- watch server going offline, reset database meta-information when it come back online
- revise graph visualization legend to only display labels displayed in graph