You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@kafka.apache.org by "Brian J. Vanecek" <bj...@up.com> on 2015/12/14 16:37:26 UTC

Reading from __consumer_offsets in 0.9

All,

I'm running into a bit of a road-block consuming the offsets topic in 0.9. 
In 0.8, I was able to use kafka.server.OffsetManager.readMessageKey(..) 
and readMessageValue(..) to deserialize the offset messages. In 0.9, the 
equivalent methods in kafka.coordinator.GroupMetadataManager are private. 
The OffsetsMessageFormatter is available, but I would rather not have to 
decode it to a String and then turn around and parse it back into an 
object. What is the recommended way to do this? Or am I just out of luck?

As a little background, I'm working on an application similar to Burrow ( 
https://github.com/linkedin/Burrow ), which is why I want to consume the 
offsets topic.


- Brian Vanecek
 bjvanece@up.com 

**

This email and any attachments may contain information that is confidential and/or privileged for the sole use of the intended recipient.  Any use, review, disclosure, copying, distribution or reliance by others, and any forwarding of this email or its contents, without the express permission of the sender is strictly prohibited by law.  If you are not the intended recipient, please contact the sender immediately, delete the e-mail and destroy all copies.
**

Re: Reading from __consumer_offsets in 0.9

Posted by Jason Gustafson <ja...@confluent.io>.
Hey Brian,

I think we've made these methods public again in trunk, but that won't help
you with 0.9. Another option would be to write a parser yourself since the
format is fairly straightforward. This would let you remove a dependence on
Kafka internals which probably doesn't have strong compatibility guarantees
between releases. The only downside is that you'll have to keep your parser
up-to-date with any format changes, but these should be rare anyway.

-Jason

On Mon, Dec 14, 2015 at 7:37 AM, Brian J. Vanecek <bj...@up.com> wrote:

> All,
>
> I'm running into a bit of a road-block consuming the offsets topic in 0.9.
> In 0.8, I was able to use kafka.server.OffsetManager.readMessageKey(..)
> and readMessageValue(..) to deserialize the offset messages. In 0.9, the
> equivalent methods in kafka.coordinator.GroupMetadataManager are private.
> The OffsetsMessageFormatter is available, but I would rather not have to
> decode it to a String and then turn around and parse it back into an
> object. What is the recommended way to do this? Or am I just out of luck?
>
> As a little background, I'm working on an application similar to Burrow (
> https://github.com/linkedin/Burrow ), which is why I want to consume the
> offsets topic.
>
>
> - Brian Vanecek
>  bjvanece@up.com
>
> **
>
> This email and any attachments may contain information that is
> confidential and/or privileged for the sole use of the intended recipient.
> Any use, review, disclosure, copying, distribution or reliance by others,
> and any forwarding of this email or its contents, without the express
> permission of the sender is strictly prohibited by law.  If you are not the
> intended recipient, please contact the sender immediately, delete the
> e-mail and destroy all copies.
> **
>