linkedin/camus — pull request #22 by ottomata (2013-08-09 14:13:54+00:00)
Title: LatestSchemaKafkaAvroMessageDecoder : Fixing IndexOutOfBoundsException

Fixing ```IndexOutOfBoundsException``` when instantiating new String with ```byte[] payload```.

Calling ```new String(payload, 4, payload.length)``` causes Java to attempt to read
4 bytes beyond the end of payload, which throws and ```IndexOutOfBoundsException```.

I am compiling with the provided kafka 0.8 jar, so I'm pretty sure Message.MagicOffset() is 4.
In Message.scala:

```scala
/**
* The current offset and size for all the fixed-length fields
*/
val CrcOffset = 0
val CrcLength = 4
val MagicOffset = CrcOffset + CrcLength
```

Even so, I'm not sure how this ever worked. Wouldn't this always cause an exception?