Fix some bugs under MRI

* `bin/plugin install` works now
* most specs pass

The only specs that don't pass are ones that are broken under MRI due to #2024 not being fixed.

```
% USE_RUBY=1 bin/logstash rspec -f d spec | grep FAIL
    includes YYYY-MM-dd'T'HH:mm:ss.SSSZ (FAILED - 1)
    includes YYYY-MM-dd'T'HH:mm:ss.SSSSSSZ (FAILED - 2)
    includes YYYY-MM-dd'T'HH:mm:ss.SSS (FAILED - 3)
    includes YYYY-MM-dd'T'HH:mm:ss (FAILED - 4)
    includes YYYY-MM-dd'T'HH:mm:ssZ (FAILED - 5)
```

```
Finished in 1.77 seconds
182 examples, 5 failures
```