Return-Path: X-Original-To: apmail-kafka-users-archive@www.apache.org Delivered-To: apmail-kafka-users-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id D44C610962 for ; Mon, 14 Oct 2013 19:05:42 +0000 (UTC) Received: (qmail 6434 invoked by uid 500); 14 Oct 2013 19:05:42 -0000 Delivered-To: apmail-kafka-users-archive@kafka.apache.org Received: (qmail 6350 invoked by uid 500); 14 Oct 2013 19:05:38 -0000 Mailing-List: contact users-help@kafka.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: users@kafka.apache.org Delivered-To: mailing list users@kafka.apache.org Received: (qmail 6329 invoked by uid 99); 14 Oct 2013 19:05:36 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 14 Oct 2013 19:05:36 +0000 X-ASF-Spam-Status: No, hits=1.7 required=5.0 tests=FREEMAIL_ENVFROM_END_DIGIT,HTML_MESSAGE,RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of hsy541@gmail.com designates 209.85.214.173 as permitted sender) Received: from [209.85.214.173] (HELO mail-ob0-f173.google.com) (209.85.214.173) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 14 Oct 2013 19:05:31 +0000 Received: by mail-ob0-f173.google.com with SMTP id wo20so5048506obc.4 for ; Mon, 14 Oct 2013 12:05:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:date:message-id:subject:from:to:content-type; bh=6H03QylfOY/pCdzQNzNHucN30DPmwbwPYaKFrFiiSfM=; b=KNZrma1OthnrgiE1ndZIgYcQCAjO3s4i/LHhv5f/fgAEjhAITX0etOv2DlWWf/11pk Mwd2BnPbbTGoP0sDcbqBjPJ1WHddaovfFPJAj43TMoEL1z0++RKoGCwOgO6h7Dz55JpK /NQa0rp611GAzUJADS3Dsjrh4jrg1URHDOMBB0Zzd66sArHfZaYMfa5rYoeIYPzt2Ibc 5Nu4ucy0qQaY24VGPCbtvi4N94j0az4ZyQQdg+4ZzjfiuEUa9Tf5/v/1hsB3EMZhTDLL YCWq7GjeSZyBXKXnlZdMu+zwHWN2g64365SwJa148+4oYqVs3FbAW9JPXj628Y4LW+6j EVng== MIME-Version: 1.0 X-Received: by 10.60.138.136 with SMTP id qq8mr1678501oeb.59.1381777510380; Mon, 14 Oct 2013 12:05:10 -0700 (PDT) Received: by 10.76.113.208 with HTTP; Mon, 14 Oct 2013 12:05:10 -0700 (PDT) Date: Mon, 14 Oct 2013 12:05:10 -0700 Message-ID: Subject: KafkaStream bug? From: "hsy541@gmail.com" To: users@kafka.apache.org Content-Type: multipart/alternative; boundary=047d7b41ccf8aa3c3104e8b825c9 X-Virus-Checked: Checked by ClamAV on apache.org --047d7b41ccf8aa3c3104e8b825c9 Content-Type: text/plain; charset=ISO-8859-1 I found some weird behavior, I follow the exact code example for HighlevelConsumer https://cwiki.apache.org/confluence/display/KAFKA/Consumer+Group+Example# but add one debug line here " public void run() { ConsumerIterator it = m_stream.iterator(); while (it.hasNext()){ * ////////////////////////////////////////////my line here//////////////////////////////////////////////////* * System.out.println("from the stream" + m_stream); \\This line will be blocked. KafkaStream.toString() is a blocking method?????* * /////////////////////////////////////////// end of my line ///////////////////////////////////////////////////////* * * System.out.println("Thread " + m_threadNumber + ": " + new String(it.next().message())); } System.out.println("Shutting down Thread: " + m_threadNumber); } " --047d7b41ccf8aa3c3104e8b825c9--