Refactored stats services after testing exposed some design issues

Also added beginnings of remote service test