Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id E6FB6200C39 for ; Thu, 16 Mar 2017 16:33:52 +0100 (CET) Received: by cust-asf.ponee.io (Postfix) id E5A47160B7A; Thu, 16 Mar 2017 15:33:52 +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 3A774160B78 for ; Thu, 16 Mar 2017 16:33:52 +0100 (CET) Received: (qmail 12931 invoked by uid 500); 16 Mar 2017 15:33:51 -0000 Mailing-List: contact users-help@qpid.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: users@qpid.apache.org Delivered-To: mailing list users@qpid.apache.org Received: (qmail 12919 invoked by uid 99); 16 Mar 2017 15:33:51 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd3-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 16 Mar 2017 15:33:51 +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 A059C180BB2 for ; Thu, 16 Mar 2017 15:33:50 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd3-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -5.023 X-Spam-Level: X-Spam-Status: No, score=-5.023 tagged_above=-999 required=6.31 tests=[RCVD_IN_DNSWL_HI=-5, RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01, RP_MATCHES_RCVD=-0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001] autolearn=disabled Received: from mx1-lw-us.apache.org ([10.40.0.8]) by localhost (spamd3-us-west.apache.org [10.40.0.10]) (amavisd-new, port 10024) with ESMTP id th6_KAfH6d43 for ; Thu, 16 Mar 2017 15:33:49 +0000 (UTC) Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by mx1-lw-us.apache.org (ASF Mail Server at mx1-lw-us.apache.org) with ESMTPS id 68FD360DFC for ; Thu, 16 Mar 2017 15:33:49 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 29E98811A7 for ; Thu, 16 Mar 2017 15:33:49 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com 29E98811A7 Authentication-Results: ext-mx03.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=redhat.com Authentication-Results: ext-mx03.extmail.prod.ext.phx2.redhat.com; spf=pass smtp.mailfrom=astitcher@redhat.com DKIM-Filter: OpenDKIM Filter v2.11.0 mx1.redhat.com 29E98811A7 Received: from marigold (unknown [10.18.97.150]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 98B1C4DA31 for ; Thu, 16 Mar 2017 15:33:48 +0000 (UTC) Message-ID: <1489678427.3306.15.camel@redhat.com> Subject: Re: [Qpid-Proton C++] detecting only connection errors From: Andrew Stitcher To: users@qpid.apache.org Date: Thu, 16 Mar 2017 11:33:47 -0400 In-Reply-To: References: Organization: Red Hat Inc Content-Type: text/plain; charset="UTF-8" Mime-Version: 1.0 Content-Transfer-Encoding: 7bit X-Scanned-By: MIMEDefang 2.79 on 10.5.11.16 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.27]); Thu, 16 Mar 2017 15:33:49 +0000 (UTC) archived-at: Thu, 16 Mar 2017 15:33:53 -0000 On Tue, 2017-03-14 at 15:23 +0100, Rabih M wrote: > Hello, > > I am trying to implement a retry mechanism using proton. If the > connection > between the amqp peers is down or the remote peer itself is down, i > would > like to retry the current operation (send, receive...). A bit similar > to > the failover Url in JMS... > > Therefore i would like to capture only the errors related to > connection > problems to trigger the retry. > If I implement on_transport_error(), will I get only the connection > error > here? or will I receive other types of undesired errors too? If you implement on_transport_error() you will see events for every time the proton-c transport connection closes with an error condition set. I think this is only the underlying socket failures, but I'm not 100% sure about that. I think it would be reasonable to report a bug if you get other errors reported here. So try it, and if it doesn't work the way you expect, come back to the list. Note, you will probably have to set an idle timeout (heartbeat) to ensure that you notice in a timely fashion when the peer is disconnected, or the network goes away. Andrew --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscribe@qpid.apache.org For additional commands, e-mail: users-help@qpid.apache.org