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 2DE6C200C13 for ; Mon, 6 Feb 2017 10:11:48 +0100 (CET) Received: by cust-asf.ponee.io (Postfix) id 2C852160B62; Mon, 6 Feb 2017 09:11:48 +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 7521C160B53 for ; Mon, 6 Feb 2017 10:11:47 +0100 (CET) Received: (qmail 45995 invoked by uid 500); 6 Feb 2017 09:11:46 -0000 Mailing-List: contact dev-help@hc.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: "HttpComponents Project" Delivered-To: mailing list dev@hc.apache.org Received: (qmail 45984 invoked by uid 99); 6 Feb 2017 09:11:46 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd4-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 06 Feb 2017 09:11:46 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd4-us-west.apache.org (ASF Mail Server at spamd4-us-west.apache.org) with ESMTP id 1D613C12C0 for ; Mon, 6 Feb 2017 09:11:46 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd4-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -1.999 X-Spam-Level: X-Spam-Status: No, score=-1.999 tagged_above=-999 required=6.31 tests=[KAM_LAZY_DOMAIN_SECURITY=1, RP_MATCHES_RCVD=-2.999] autolearn=disabled Received: from mx1-lw-eu.apache.org ([10.40.0.8]) by localhost (spamd4-us-west.apache.org [10.40.0.11]) (amavisd-new, port 10024) with ESMTP id 1u6prrAmW2uc for ; Mon, 6 Feb 2017 09:11:45 +0000 (UTC) Received: from mailrelay1-us-west.apache.org (mailrelay1-us-west.apache.org [209.188.14.139]) by mx1-lw-eu.apache.org (ASF Mail Server at mx1-lw-eu.apache.org) with ESMTP id F01E55FC0C for ; Mon, 6 Feb 2017 09:11:44 +0000 (UTC) Received: from jira-lw-us.apache.org (unknown [207.244.88.139]) by mailrelay1-us-west.apache.org (ASF Mail Server at mailrelay1-us-west.apache.org) with ESMTP id A8A69E05BB for ; Mon, 6 Feb 2017 09:11:42 +0000 (UTC) Received: from jira-lw-us.apache.org (localhost [127.0.0.1]) by jira-lw-us.apache.org (ASF Mail Server at jira-lw-us.apache.org) with ESMTP id 1B21925292 for ; Mon, 6 Feb 2017 09:11:42 +0000 (UTC) Date: Mon, 6 Feb 2017 09:11:42 +0000 (UTC) From: "ASF GitHub Bot (JIRA)" To: dev@hc.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (HTTPCLIENT-1806) Add a route inteceptor MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 archived-at: Mon, 06 Feb 2017 09:11:48 -0000 [ https://issues.apache.org/jira/browse/HTTPCLIENT-1806?page=3Dcom.atla= ssian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId= =3D15853724#comment-15853724 ]=20 ASF GitHub Bot commented on HTTPCLIENT-1806: -------------------------------------------- GitHub user Coderec opened a pull request: https://github.com/apache/httpclient/pull/63 HTTPCLIENT-1806 Add a route inteceptor https://issues.apache.org/jira/browse/HTTPCLIENT-1806 You can merge this pull request into a Git repository by running: $ git pull https://github.com/Coderec/httpclient cuibaosen/HTTPCLIENT-1= 806 Alternatively you can review and apply these changes as the patch at: https://github.com/apache/httpclient/pull/63.patch To close this pull request, make a commit to your master/trunk branch with (at least) the following in the commit message: This closes #63 =20 ---- commit c9551fc021247e6297dd0a62a1b08236634b3c87 Author: CuiBaosen Date: 2017-02-06T09:07:21Z HTTPCLIENT-1806 Add a route inteceptor ---- > Add a route inteceptor > ---------------------- > > Key: HTTPCLIENT-1806 > URL: https://issues.apache.org/jira/browse/HTTPCLIENT-180= 6 > Project: HttpComponents HttpClient > Issue Type: Improvement > Components: HttpClient (async), HttpClient (classic) > Reporter: Baosen Cui > Priority: Minor > Fix For: 5.0 > > > I had meet a problem that I need to log the time cost by method =E2=80= =9CestablishRoute=E2=80=9D( in httpclient ). > Since there seems nothing to support, I wrote a interceptor into HttpCore= coping the structure of =E2=80=9CHttpProcessor" > Would this be accepted? Or there has already something alike? > @ThreadSafe // provided injected dependencies are immutable > public final class ImmutableRouteProcessor implements RouteProcessor { > ... > } > public interface PostRouteInterceptor { > void postProcess(final HttpRequest request, final HttpContext context); > } > public interface PreRouteInterceptor { > void preProcess(final HttpRequest request, final HttpContext context); > } > public interface RouteProcessor extends PreRouteInterceptor, PostRouteInt= erceptor { > } -- This message was sent by Atlassian JIRA (v6.3.15#6346) --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscribe@hc.apache.org For additional commands, e-mail: dev-help@hc.apache.org