square/cube — pull request #37 by grncdr (2012-02-20 05:05:08+00:00)
Title: Handle both timestamp formats from collectd

From http://collectd.org/wiki/index.php/High_resolution_time_format

"The high resolution time format is a representation of time used internally to store the time at which a value was collected and the interval in which it is collected."

The `cube/server/collectd` module expects timestamps at this internal resolution, but this behaviour was changed in collectd about 8 months ago [here](https://github.com/collectd/collectd/commit/cf9ac771ade7c5ba75ab13d2b4f2482983994840)

This patch handles both styles of timestamps by first checking if the sent timestamp is extremely large and scaling it down appropriately.