JSON payload key sorting

The purpose of this branch is to make sure we sort JSON payloads before deriving a SHA from them. This will prevent `Billy` from getting fooled into thinking it needs to create a new cache file when it might already have one for the given payload. For instance,

```ruby
{a: '1', b: '2'}.to_json != {b: '2', a: '1'}.to_json
```

In the process, I refactored a lot of the logic out of `Cache#key`, as it was getting pretty unwieldy.