Return-Path: X-Original-To: apmail-flink-user-archive@minotaur.apache.org Delivered-To: apmail-flink-user-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 2255F18276 for ; Wed, 21 Oct 2015 14:40:17 +0000 (UTC) Received: (qmail 62785 invoked by uid 500); 21 Oct 2015 14:40:06 -0000 Delivered-To: apmail-flink-user-archive@flink.apache.org Received: (qmail 62703 invoked by uid 500); 21 Oct 2015 14:40:05 -0000 Mailing-List: contact user-help@flink.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@flink.apache.org Delivered-To: mailing list user@flink.apache.org Received: (qmail 62693 invoked by uid 99); 21 Oct 2015 14:40:05 -0000 Received: from Unknown (HELO spamd3-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 21 Oct 2015 14:40:05 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd3-us-west.apache.org (ASF Mail Server at spamd3-us-west.apache.org) with ESMTP id B1DB61809BC for ; Wed, 21 Oct 2015 14:40:04 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd3-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: 1.193 X-Spam-Level: * X-Spam-Status: No, score=1.193 tagged_above=-999 required=6.31 tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01, SPF_PASS=-0.001, URIBL_BLOCKED=0.001, URI_HEX=1.313] autolearn=disabled Authentication-Results: spamd3-us-west.apache.org (amavisd-new); dkim=pass (2048-bit key) header.d=gmail.com Received: from mx1-us-west.apache.org ([10.40.0.8]) by localhost (spamd3-us-west.apache.org [10.40.0.10]) (amavisd-new, port 10024) with ESMTP id f6QayqOMlLiM for ; Wed, 21 Oct 2015 14:39:57 +0000 (UTC) Received: from mail-wi0-f178.google.com (mail-wi0-f178.google.com [209.85.212.178]) by mx1-us-west.apache.org (ASF Mail Server at mx1-us-west.apache.org) with ESMTPS id 9C2342118F for ; Wed, 21 Oct 2015 14:39:56 +0000 (UTC) Received: by wicll6 with SMTP id ll6so94275201wic.0 for ; Wed, 21 Oct 2015 07:39:55 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=content-type:mime-version:subject:from:in-reply-to:date :content-transfer-encoding:message-id:references:to; bh=8XzptAsB072h3L065pwj5HKlvzuO2zWVEr+0fLQILKM=; b=ldkAXQCKixkT+r51O1y+z4h3oSHIsVhrQo6v/m95ooBxWQSca9W4KQgSi16FiAC8gi wF3vLibjelMEwJLq/lxC5b/1LDuxT8zkhpnPGy6LuT5yUNZBFmSBa+h3u9r8YnGIL7rj KVpq8bdJZomaYW/AaEtzN6FZtSethh6auN9ExrpBQiaysMyjYod0KTWjhONP7CqcprdV jSQXcbxHi+q9M7oO/H+xX6IeOixLX5gzhhQuB3bdx7lu9mGQQiPj3u7ckj3Kob/WLPz2 ry7cZXYLd6O78RoSWlNhkxs/jLE/J2Vds/zNCsY4/TiB0stpuG5PcJs3qHyL2cH5GbQw QIow== X-Received: by 10.180.72.113 with SMTP id c17mr11257729wiv.6.1445438395344; Wed, 21 Oct 2015 07:39:55 -0700 (PDT) Received: from macbook-pro-2.fritz.box (ip5b40315a.dynamic.kabel-deutschland.de. [91.64.49.90]) by smtp.gmail.com with ESMTPSA id cv1sm24039741wib.18.2015.10.21.07.39.54 for (version=TLS1 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Wed, 21 Oct 2015 07:39:54 -0700 (PDT) Content-Type: text/plain; charset=us-ascii Mime-Version: 1.0 (Mac OS X Mail 9.0 \(3094\)) Subject: Re: Flink Data Stream Union From: Aljoscha Krettek In-Reply-To: Date: Wed, 21 Oct 2015 16:39:53 +0200 Content-Transfer-Encoding: quoted-printable Message-Id: References: <1445269349187-3169.post@n4.nabble.com> <1445432540789-3196.post@n4.nabble.com> <76AFC42B-DE46-47E1-B4D2-E677085174D5@gmail.com> <04E307A1-AB61-4C55-A0E3-CA7C855B9F3A@gmail.com> To: user@flink.apache.org X-Mailer: Apple Mail (2.3094) So does the filter maybe filter out everything? > On 21 Oct 2015, at 16:18, Gayu wrote: >=20 > Yes, exactly.=20 >=20 > On Wed, Oct 21, 2015 at 10:17 AM, Aljoscha Krettek = wrote: > So it is received in the filter but the print afterwards does not = print? > > On 21 Oct 2015, at 15:49, Gayu wrote: > > > > The data does arrive in the second port and i am able to see that in = the filter class received. > > It happens only on specific machine on which i run the code. > > > > > > Yes, i did forget to post here, but my program calls the = unionMessageStreams() > > > > On Wed, Oct 21, 2015 at 9:39 AM, Aljoscha Krettek = wrote: > > Hi Gayu, > > could it be that no data ever arrives on the second input stream? Or = that the filter filters out all messages? > > > > Also, in the example you posted you forgot to call = unionMessageStreams(). > > > > Cheers, > > Aljoscha > > > > > On 21 Oct 2015, at 15:29, Till Rohrmann = wrote: > > > > > > Can it be that you forgot to call unionMessageStreams in your main = method? > > > > > > Cheers, > > > Till > > > > > > > > > On Wed, Oct 21, 2015 at 3:02 PM, flinkuser = wrote: > > > Here is the strange behavior. > > > > > > Below code works in one box but not in the other. I had it working = in my > > > laptop the whole of yesterday, but strangely today it doesnt work = in my > > > desktop. > > > > > > Can anyone please let me know what the issue is. > > > > > > > > > public static void main(String[] args) throws Exception { > > > try { > > > final StreamExecutionEnvironment env =3D > > > StreamExecutionEnvironment.getExecutionEnvironment(); > > > DataStream msgDataStream1 =3D = env.addSource((new > > > SocketSource(hostName1, port, '\n', -1))).filter(new > > > MessageFilter()).setParallelism(1); > > > DataStream msgDataStream2 =3D = env.addSource((new > > > SocketSource(hostName2, port, '\n', -1))).filter(new > > > MessageFilter()).setParallelism(1); > > > > > > env.execute("Stock stream"); > > > > > > } catch (Exception e) { > > > System.err.println("Exception =3D > " + = e.getMessage()); > > > e.printStackTrace(); > > > } > > > } > > > > > > private static void unionMessageStreams(DataStream = msgDataStream1, > > > DataStream msgDataStream2) { > > > try { > > > > > > DataStream ds =3D = msgDataStream1.union(msgDataStream2); > > > ds.print(); > > > } catch (Exception e) { > > > System.err.println("Exception in union = Message Streams () =3D > " + > > > e.getMessage()); > > > } > > > } > > > > > > Thanks > > > > > > > > > > > > -- > > > View this message in context: = http://apache-flink-user-mailing-list-archive.2336050.n4.nabble.com/Flink-= Data-Stream-Union-tp3169p3196.html > > > Sent from the Apache Flink User Mailing List archive. mailing list = archive at Nabble.com. > > > > > > > > > > > > > -- > > Gayu >=20 >=20 >=20 >=20 > --=20 > Gayu