Add async method for getting the rrd files

Adding some async methods required to make CGP more responsive (see https://github.com/pommi/CGP/pull/37)

No modification to the existing API, I'm just adding stuff ,)
I tried to re-use as much existing code as possible, as you can see in the  "splitting" commits.

I'm not good at javascript, thus do not hesitate to make comments