elastitcyManager: Fix costs unit

Costs are tracked per hour so use that as unit for the x value
Dump costs JSON to files

Use GSON to convert the cost lists to json and write them out to temp
files.
Track and save total costs as well