Re: getOffsetsBefore(...) => kafka.common.UnknownException

2014-10-29 Thread Magnus Vojbacke
Hi, sorry for the extremely late follow up: No, there is nothing logged on the broker, Using default log4j.properties. I also tried to activate trace logging for the network processor component (log4j.logger.kafka.network.Processor=TRACE, requestAppender), without seeing anything that seemed r

Re: getOffsetsBefore(...) => kafka.common.UnknownException

2014-10-19 Thread Jun Rao
Do you see any WARN for the offset request on the broker? Thanks, Jun On Fri, Oct 17, 2014 at 4:44 AM, Magnus Vojbacke < magnus.vojba...@digitalroute.com> wrote: > Yes, I used TopicMetaDataRequest to determine the lead broker for the > partition. > > I’ve also compared the broker selected by my

Re: getOffsetsBefore(...) => kafka.common.UnknownException

2014-10-17 Thread Magnus Vojbacke
Hi, I’m not sure if I’m confusing the concepts here, because I don’t understand your answer? I thought that the reason for making a PartitionOffsetRequest was to determine which offset to use when fetching messages? Also, how is message.max.bytes related? I’m using the simple consumer api, a

Re: getOffsetsBefore(...) => kafka.common.UnknownException

2014-10-17 Thread Magnus Vojbacke
Yes, I used TopicMetaDataRequest to determine the lead broker for the partition. I’ve also compared the broker selected by my code with the output from "bin/kafka-topics.sh --describe[...]" and as far as I can tell, it’s using the broker which is described as leader for the topic. /Magnus On

Re: getOffsetsBefore(...) => kafka.common.UnknownException

2014-10-16 Thread Jun Rao
The OffsetRequest can only be answered by the leader of the partition. Did you connect the SimpleConsumer to the leader broker? If not, you need to use TopicMetadataRequest to find out the leader broker first. Thanks, Jun On Thu, Oct 16, 2014 at 3:56 AM, Magnus Vojbacke < magnus.vojba...@digital

Re: getOffsetsBefore(...) => kafka.common.UnknownException

2014-10-16 Thread Neha Narkhede
Do you see any errors on the broker? Are you sure that the consumer's fetch offset is set higher than the largest message in your topic? It should be higher than message.max.bytes on the broker (which defaults to 1MB). On Thu, Oct 16, 2014 at 3:56 AM, Magnus Vojbacke < magnus.vojba...@digitalroute

getOffsetsBefore(...) => kafka.common.UnknownException

2014-10-16 Thread Magnus Vojbacke
Hi, I’m trying to make a request for offset information from my broker, and I get a kafka.common.UnknownException as the result. I’m trying to use the Simple Consumer API val topicAndPartition = new TopicAndPartition(“topic3”, 0) val requestInfo = new java.util.HashMap[TopicAn