Added a ping function

This function is meant to be used in cron to act as a keepalive.
Will likely change this architecture, since cron runs at a minute
resolution, and that is not sufficient.

Moved the ttl time into a config option, and added defaults to the
config class (yeah, I know... bad me, should have been a separate
feature).