Return-Path: X-Original-To: apmail-flume-user-archive@www.apache.org Delivered-To: apmail-flume-user-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 7D1A2175E9 for ; Thu, 9 Oct 2014 17:38:42 +0000 (UTC) Received: (qmail 219 invoked by uid 500); 9 Oct 2014 17:38:42 -0000 Delivered-To: apmail-flume-user-archive@flume.apache.org Received: (qmail 156 invoked by uid 500); 9 Oct 2014 17:38:42 -0000 Mailing-List: contact user-help@flume.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@flume.apache.org Delivered-To: mailing list user@flume.apache.org Received: (qmail 146 invoked by uid 99); 9 Oct 2014 17:38:42 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 09 Oct 2014 17:38:42 +0000 X-ASF-Spam-Status: No, hits=1.5 required=5.0 tests=HTML_MESSAGE,RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of terreyshih@gmail.com designates 209.85.213.46 as permitted sender) Received: from [209.85.213.46] (HELO mail-yh0-f46.google.com) (209.85.213.46) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 09 Oct 2014 17:38:15 +0000 Received: by mail-yh0-f46.google.com with SMTP id f73so961340yha.5 for ; Thu, 09 Oct 2014 10:38:14 -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=3CSUYsg9X3wJJ26osNZNoR+jV+Mb98A5TkiP4mvSIJM=; b=pMB6dWvLczj/0dYtrPUN31KPdrJ57DqxXtMRqDoGHvgvfGZ7W/dOqITT7yBDBs3uyR BVxqn5uoVh3jQXzj5v+a678gkd8ENyLpMwcEQiKd+wYanUhr0AyhUa8jplCk0G0BLa4o jFziCQJdqxzPuQ6rofwxSb/i5gVXuHyUc51J8m6j3JR9ChxHIuFPYeL230u52gENLprH c9UNPnX4ksBxD7uyDWUgSyTPQMtJ7+rP7AXYp6NyjfA0CFS0nMGGhTvlsU6T0ITimUAr ZMp26fRMZIvdm40EY89A6zypgNulKC6avo0WQdwYNiLPl/CCHjOLADQ37PjEKQ2bcvHD dgRg== MIME-Version: 1.0 X-Received: by 10.236.84.48 with SMTP id r36mr26765375yhe.5.1412876294050; Thu, 09 Oct 2014 10:38:14 -0700 (PDT) Received: by 10.170.59.145 with HTTP; Thu, 9 Oct 2014 10:38:14 -0700 (PDT) Date: Thu, 9 Oct 2014 10:38:14 -0700 Message-ID: Subject: does flume send event in a multi threaded manner ? From: terrey shih To: user@flume.apache.org Content-Type: multipart/alternative; boundary=20cf301af91f9e5d87050500e5a1 X-Virus-Checked: Checked by ClamAV on apache.org --20cf301af91f9e5d87050500e5a1 Content-Type: text/plain; charset=UTF-8 Hi Can sending an event gets blocked because something happened down at the source of the other agent? For example, consider the following taken from the developer guide. public void myMethod(){ SomeDataObject data = getData() Event event = EventBuilder.withBody(data); // Send the event try { client.append(event); } catch (EventDeliveryException e) { // clean up and recreate the client client.close(); client = null; client = RpcClientFactory.getDefaultInstance(hostname, port); } } if for some reason, the event has problem sending downstream, would it block myMethod from returning ? I know the catch block might catch the exception, but is it possible that something else happens and the method just hangs and myMethod never returns ? Or is it multithreaded and does not block ? thx, Terrey --20cf301af91f9e5d87050500e5a1 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Hi

Can sending an event gets bl= ocked because something happened down at the source of the other agent?
=
For example, consider the following taken from the developer guide.
=
public void myMethod(){
    <=
br>SomeDataObject data =3D getData()
Event
event= =3D EventBuilder.withBody(data); // Send the event try { client.append(event); } catch (EventDeliveryException e= ) { // clean up and recreate the client client.close(); client =3D null; client =3D RpcClientFactory.get= DefaultInstance(hostname, port= ); }

}

if for some reason, the event has problem sending = downstream, would it block myMethod from returning ?

I know th= e catch block might catch the exception, but is it possible that something = else happens and the method just hangs and myMethod never returns ?=C2=A0 O= r is it multithreaded and does not block ?

thx,
Terrey
<= div>



--20cf301af91f9e5d87050500e5a1--