fixing datastore-statistics interaction to ensure stats are properly written to disk on exit

git-svn-id: https://gnunet.org/svn/gnunet@34769 140774ce-b5e7-0310-ab8b-a85725594a96
-doxgen, use modern client API

git-svn-id: https://gnunet.org/svn/gnunet@34770 140774ce-b5e7-0310-ab8b-a85725594a96