Return-Path: X-Original-To: apmail-tomcat-users-archive@www.apache.org Delivered-To: apmail-tomcat-users-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 2252210886 for ; Wed, 2 Apr 2014 14:50:26 +0000 (UTC) Received: (qmail 59389 invoked by uid 500); 2 Apr 2014 14:50:22 -0000 Delivered-To: apmail-tomcat-users-archive@tomcat.apache.org Received: (qmail 58656 invoked by uid 500); 2 Apr 2014 14:50:20 -0000 Mailing-List: contact users-help@tomcat.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: "Tomcat Users List" Delivered-To: mailing list users@tomcat.apache.org Received: (qmail 58606 invoked by uid 99); 2 Apr 2014 14:50:18 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 02 Apr 2014 14:50:18 +0000 X-ASF-Spam-Status: No, hits=-0.0 required=5.0 tests=SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of aw@ice-sa.com designates 212.85.38.228 as permitted sender) Received: from [212.85.38.228] (HELO tor.combios.es) (212.85.38.228) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 02 Apr 2014 14:50:11 +0000 Received: from [192.168.245.129] (HSI-KBW-46-237-206-233.hsi.kabel-badenwuerttemberg.de [46.237.206.233]) (Authenticated sender: andre.warnier@ice-sa.com) by tor.combios.es (Postfix) with ESMTPA id 51A6F3C1657 for ; Wed, 2 Apr 2014 16:50:15 +0200 (CEST) Message-ID: <533C2389.9090406@ice-sa.com> Date: Wed, 02 Apr 2014 16:49:45 +0200 From: =?ISO-8859-1?Q?Andr=E9_Warnier?= Reply-To: Tomcat Users List User-Agent: Thunderbird 2.0.0.24 (Windows/20100228) MIME-Version: 1.0 To: Tomcat Users List Subject: Re: External URL delay from webapp References: <4311ADB24E76A147A0BA51077BF45F9DA7412AF8@S01-EXMX-01.donlen.com> In-Reply-To: <4311ADB24E76A147A0BA51077BF45F9DA7412AF8@S01-EXMX-01.donlen.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org Scott Bailey wrote: > Hi all, > We are having an issue with a new tomcat deployment, in our webapp we make a request to a 3rd party webservice site using http URL for retrieving the data, the first time we click the button to make the request the information is returned within a second or 2 but if we click the button again within 5 seconds to request the information again it takes a good minute for the data to be returned. > > We found that if we set the "-Dhttp.proxyHost and -Dhttp.proxyPort" options in tomcat under the java options this resolves the delay but also breaks another request to a different 3rd party using https URL. > Maybe first, understand that this has nothing to do with Tomcat. So you may have been looking for information in the wrong places. It is your application making a connection to some outside endpoint, and Tomcat knows nothing about it. The only thing in common between your application and Tomcat, is that they both run in the same JVM. So if you set a global JVM option "-D", this impacts *everything* that runs in that JVM : Tomcat, other applications, and your own application. You probably need to find a way to set these properties for your application only (or for that connection only). Sadly, I don't know java well-enough to know if that is possible in this case. What library are you using, to make that HTTP call ? Look there first. --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org For additional commands, e-mail: users-help@tomcat.apache.org