ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jaikiran Pai <jaiki...@apache.org>
Subject Re: [ant] branch master updated: Avoid connection refused errors by leaving some time between the gets, works locally lets see if it also works for jenkins
Date Tue, 28 May 2019 05:10:31 GMT
Hi Martijn,

You are right - these tests have been failing regularly with connection
refused issues on Jenkins. Your commit seems to have improved the
situation although, they still seem to fail once in a while like here
https://builds.apache.org/job/Ant-Build-Matrix-master-Windows/jdk=JDK%201.8.0_121%20(unlimited%20security)%2064-bit%20Windows%20only,label_exp=Windows/894/testReport/junit/src.tests.antunit.taskdefs/get-test_xml/testTemporaryRedirect/

-Jaikiran

On 26/05/19 12:35 PM, jkf@apache.org wrote:
> Hi all
>
> Sorry the patch also contains another change, yesterday I updated the
> get-test.xml to also use https to the extend possible, and I did
> "break" the test case following a redirect from http to https. After
> fixing this I immediately put a workaround in place for the connection
> refused errors we often get in the get-test and gunzip-test.
>
> Br Martijn
>
>
>
> On 26-05-19 08:46, jkf@apache.org wrote:
>> This is an automated email from the ASF dual-hosted git repository.
>>
>> jkf pushed a commit to branch master
>> in repository https://gitbox.apache.org/repos/asf/ant.git
>>
>>
>> The following commit(s) were added to refs/heads/master by this push:
>>       new 9b4393b  Avoid connection refused errors by leaving some
>> time between the gets, works locally lets see if it also works for
>> jenkins
>> 9b4393b is described below
>>
>> commit 9b4393b85ca7acebd7b228ea5ee79e4aa7e810a8
>> Author: jkf <jm@famkruithof.net>
>> AuthorDate: Sun May 26 08:46:09 2019 +0200
>>
>>      Avoid connection refused errors by leaving some time between the
>> gets, works locally lets see if it also works for jenkins
>> ---
>>   src/tests/antunit/taskdefs/get-test.xml    | 12 +++++++++++-
>>   src/tests/antunit/taskdefs/gunzip-test.xml |  2 ++
>>   2 files changed, 13 insertions(+), 1 deletion(-)
>>
>> diff --git a/src/tests/antunit/taskdefs/get-test.xml
>> b/src/tests/antunit/taskdefs/get-test.xml
>> index b6b5e11..2133321 100644
>> --- a/src/tests/antunit/taskdefs/get-test.xml
>> +++ b/src/tests/antunit/taskdefs/get-test.xml
>> @@ -20,12 +20,14 @@
>>     <import file="../antunit-base.xml" />
>>       <property name="location"
>> value="https://ant.apache.org/webtest/gettest" />
>> +  <property name="unsecurelocation"
>> value="http://ant.apache.org/webtest/gettest/http-to-https.txt" />
>>       <target name="setUp">
>>       <mkdir dir="${output}" />
>>     </target>
>>       <target name="testSeeOtherRedirect">
>> +    <sleep milliseconds="250"/>
>>       <get  src="${location}/other.txt" dest="${output}/other.tmp"/>
>>         <au:assertTrue>
>>               <resourcecount count="1">
>> @@ -39,6 +41,7 @@
>>     </target>
>>             <target name="testPermanentRedirect">
>> +      <sleep milliseconds="250"/>
>>         <get  src="${location}/permanent.txt"
>> dest="${output}/permanent.tmp"/>
>>           <au:assertTrue>
>>             <resourcecount count="1">
>> @@ -52,6 +55,7 @@
>>       </target>
>>             <target name="testTemporaryRedirect">
>> +      <sleep milliseconds="250"/>
>>         <get  src="${location}/temp.txt" dest="${output}/temp.txt"/>
>>           <au:assertTrue>
>>             <resourcecount count="1">
>> @@ -65,6 +69,7 @@
>>       </target>
>>             <target name="testStatusCode307Redirect">
>> +      <sleep milliseconds="250"/>
>>         <get  src="${location}/307.txt" dest="${output}/307.txt"/>
>>           <au:assertTrue>
>>             <resourcecount count="1">
>> @@ -78,6 +83,7 @@
>>       </target>
>>             <target name="test5LevelsOfRedirect">
>> +      <sleep milliseconds="250"/>
>>         <get  src="${location}/redir5.txt" dest="${output}/redir5.tmp"/>
>>           <au:assertTrue>
>>             <resourcecount count="1">
>> @@ -95,6 +101,7 @@
>>                   <target name="testInfiniteRedirect" unless="jenkins">
>> +      <sleep milliseconds="250"/>
>>         <au:expectfailure expectedmessage="More than 25 times
>> redirected, giving up">
>>         <get  src="${location}/infinite.txt"
>> dest="${output}/infinite.tmp"/>
>>           </au:expectfailure>
>> @@ -102,6 +109,7 @@
>>           <target name="testNestedResources">
>> +      <sleep milliseconds="250"/>
>>         <get dest="${output}/downloads">
>>           <url url="https://ant.apache.org/index.html"/>
>>           <url url="https://ant.apache.org/faq.html"/>
>> @@ -111,6 +119,7 @@
>>       </target>
>>       <target name="XtestRelativeRedirect">
>> +    <sleep milliseconds="250"/>
>>       <get  src="${location}/local.cgi" dest="${output}/other.tmp"/>
>>       <au:assertTrue>
>>         <resourcecount count="1">
>> @@ -125,7 +134,8 @@
>>       <target name="testHttpToHttpsRedirect" description="Tests that
>> a resource that's redirected
>>           from HTTP to HTTPS works without an error. See
>> bugzilla-62499 for details">
>> -    <get  src="${location}/http-to-https.txt"
>> dest="${output}/http-to-https-redirect.tmp"/>
>> +    <sleep milliseconds="250"/>
>> +    <get  src="${unsecurelocation}"
>> dest="${output}/http-to-https-redirect.tmp"/>
>>       <au:assertFileExists file="${output}/http-to-https-redirect.tmp"/>
>>       <au:assertTrue>
>>         <resourcecontains
>> resource="${output}/http-to-https-redirect.tmp" substring="hello
>> world"/>
>> diff --git a/src/tests/antunit/taskdefs/gunzip-test.xml
>> b/src/tests/antunit/taskdefs/gunzip-test.xml
>> index f8ec6d9..19ca0ce 100644
>> --- a/src/tests/antunit/taskdefs/gunzip-test.xml
>> +++ b/src/tests/antunit/taskdefs/gunzip-test.xml
>> @@ -39,6 +39,7 @@
>>     </target>
>>       <target name="testWithNonFileResourceToFile" depends="setup">
>> +    <sleep milliseconds="250"/>
>>       <gunzip dest="${output}/greeting.txt">
>>         <url
>> url="https://ant.apache.org/webtest/gunzip/greeting.txt.gz"/>
>>       </gunzip>
>> @@ -49,6 +50,7 @@
>>     </target>
>>       <target name="testWithNonFileResourceToDir" depends="setup">
>> +    <sleep milliseconds="250"/>
>>       <gunzip dest="${output}">
>>         <url
>> url="https://ant.apache.org/webtest/gunzip/greeting.txt.gz"/>
>>       </gunzip>
>>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@ant.apache.org
> For additional commands, e-mail: dev-help@ant.apache.org
>

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@ant.apache.org
For additional commands, e-mail: dev-help@ant.apache.org


Mime
View raw message