From dev-return-30841-archive-asf-public=cust-asf.ponee.io@ignite.apache.org Fri Feb 9 12:55:42 2018 Return-Path: X-Original-To: archive-asf-public@eu.ponee.io Delivered-To: archive-asf-public@eu.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by mx-eu-01.ponee.io (Postfix) with ESMTP id 79E23180654 for ; Fri, 9 Feb 2018 12:55:42 +0100 (CET) Received: by cust-asf.ponee.io (Postfix) id 6A80D160C4C; Fri, 9 Feb 2018 11:55:42 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id AF507160C2E for ; Fri, 9 Feb 2018 12:55:41 +0100 (CET) Received: (qmail 52649 invoked by uid 500); 9 Feb 2018 11:55:40 -0000 Mailing-List: contact dev-help@ignite.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@ignite.apache.org Delivered-To: mailing list dev@ignite.apache.org Received: (qmail 52633 invoked by uid 99); 9 Feb 2018 11:55:40 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd1-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 09 Feb 2018 11:55:39 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd1-us-west.apache.org (ASF Mail Server at spamd1-us-west.apache.org) with ESMTP id 929DFC31F2 for ; Fri, 9 Feb 2018 11:55:39 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd1-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: 1.879 X-Spam-Level: * X-Spam-Status: No, score=1.879 tagged_above=-999 required=6.31 tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, HTML_MESSAGE=2, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01, SPF_PASS=-0.001] autolearn=disabled Authentication-Results: spamd1-us-west.apache.org (amavisd-new); dkim=pass (2048-bit key) header.d=gmail.com Received: from mx1-lw-eu.apache.org ([10.40.0.8]) by localhost (spamd1-us-west.apache.org [10.40.0.7]) (amavisd-new, port 10024) with ESMTP id UE2o8_ZY3qdh for ; Fri, 9 Feb 2018 11:55:38 +0000 (UTC) Received: from mail-wm0-f47.google.com (mail-wm0-f47.google.com [74.125.82.47]) by mx1-lw-eu.apache.org (ASF Mail Server at mx1-lw-eu.apache.org) with ESMTPS id 11BF15F1A1 for ; Fri, 9 Feb 2018 11:55:38 +0000 (UTC) Received: by mail-wm0-f47.google.com with SMTP id v71so15787477wmv.2 for ; Fri, 09 Feb 2018 03:55:38 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:from:date:message-id:subject:to; bh=fM4bnUjREknII/56HrZ2ZNqQs2haIKflsPyDEbFAO1w=; b=h42VdKby3eijGNKjIwCQLT7vzO99tbA99cGPcaLJS+uxHwfytWLnMglzjz2ZdoTt+Z eAbCiHWXOujrQGj0T4kSftES9vVNJvovN9BOhY2yMfivpqYBcsctfPQoXxJs6DZxVN54 aS/3+MvseDj0OKw74FACLHq2JVAtDBvQ3o/2DtNRXGWM3yUd1K0RWDYrei86u4uZ64mF hFkUZZ2TYY/GCs2pJitNDK5bsKuaTFpEn8F5efud6G5VTzmC8BMiZxOY1alAs4HsaG57 pKoTdayqawwS7LG9X5gzfnj0jYPVyDbwN4s3MwyVypgTGYuUWApNvD5PXHflsDTU4okD gMwg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:from:date:message-id:subject:to; bh=fM4bnUjREknII/56HrZ2ZNqQs2haIKflsPyDEbFAO1w=; b=kLe3iTSMsF9OJanDovvIQSrZbiPhTpxnirvu0iipFvq2WK4/kVLUm9PVfrReeLDsnE UkQWgVXarga8x1ocJAiYPAE6NZyfXM/x05BPHSc4oz6bwmSOJvj9l4dNKMPRK5Lv8A2X nfeSUafW9nql9bVPxw5q1A6EXs/yU3HMX/oEVW9WJ4XcCsOY6pLSqpD4h0JzrxBIlSMG A2w3zjRq48SfXb+LbbUcS35y7xCFq94MaibEBiNhP6/Ic7Uu01XHMakOzVhnvm/M3Qjy 7N3nyQmwQVKlUy/CoEtZi1AupwO6bC79tw2s2rMpq20QFrJwz5VYGYrOFVtA4ROmzeBG LIpg== X-Gm-Message-State: APf1xPABVCZaW9m7ha6IJ4c/gxdV20fRZmYQekj4avkwERIpCvvEDnoY rTlP2zO8kH3+jS5g+X/jA+cCLkgU3fFLajVtSdb3kg== X-Google-Smtp-Source: AH8x224xejY2H2jdNg/IKp/CoaOmx9fOBH7JYsYubjpMFCHpy/OR1RHGJULPantGzvQ2lKtyaHus5uK2kkJ+MzMD4Qc= X-Received: by 10.80.148.248 with SMTP id t53mr3459642eda.180.1518177337639; Fri, 09 Feb 2018 03:55:37 -0800 (PST) MIME-Version: 1.0 Received: by 10.80.227.131 with HTTP; Fri, 9 Feb 2018 03:54:57 -0800 (PST) From: Sergey Chugunov Date: Fri, 9 Feb 2018 14:54:57 +0300 Message-ID: Subject: TcpCommunicationSpi in dockerized environment To: dev@ignite.apache.org Content-Type: multipart/alternative; boundary="94eb2c195cc0ea85dc0564c634dd" --94eb2c195cc0ea85dc0564c634dd Content-Type: text/plain; charset="UTF-8" Hello Ignite community, When testing Ignite in dockerized environment I faced the following issue with current TcpComminicationSpi implementation. I had several physical machines and each Ignite node running inside Docker container had at least two InetAddresses associated with it: one IP address associated with physical host and one additional IP address of Docker bridge interface *which was default and the same accross all physical machines*. Each node publishes address of its Docker bridge in the list of its addresses although it is not reachable from remote nodes. So when node tries to establish communication connection using remote node's Docker address its request goes to itself like it was a loopback address. I would suggest to implement a simple heuristic to avoid this: before connecting to some remote node's address CommunicationSpi should check whether local node has exactly the same address. If "remote" and local addresses are the same CommunicationSpi should skip such address from remote node's list and proceed with the next one. Is it safe to implement such heuristic in TcpCommunicationSpi or there are some risks I'm missing? I would really appreciate any help from expert with deep knowledge of Communication mechanics. If such improvement makes sense I'll file a ticket and start working on it. Thanks, Sergey. --94eb2c195cc0ea85dc0564c634dd--