Re: svn commit: r1035744 - /maven/doxia/doxia/trunk/doxia-core/src/main/java/org/apache/maven/doxia/parser/AbstractXmlParser.java

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Re: svn commit: r1035744 - /maven/doxia/doxia/trunk/doxia-core/src/main/java/org/apache/maven/doxia/parser/AbstractXmlParser.java

brettporter
Administrator
No need to re-roll the release, but I'd set the version by extracting it from the pom.properties file (if it exists) instead of hardcoding it.

Cheers,
Brett

On 17/11/2010, at 5:48 AM, [hidden email] wrote:

> Author: dennisl
> Date: Tue Nov 16 18:48:53 2010
> New Revision: 1035744
>
> URL: http://svn.apache.org/viewvc?rev=1035744&view=rev
> Log:
> [DOXIA-417] The XmlParser is blocked from W3C URLs
>
> o Change the user-agent name/version
>
> Modified:
>    maven/doxia/doxia/trunk/doxia-core/src/main/java/org/apache/maven/doxia/parser/AbstractXmlParser.java
>
> Modified: maven/doxia/doxia/trunk/doxia-core/src/main/java/org/apache/maven/doxia/parser/AbstractXmlParser.java
> URL: http://svn.apache.org/viewvc/maven/doxia/doxia/trunk/doxia-core/src/main/java/org/apache/maven/doxia/parser/AbstractXmlParser.java?rev=1035744&r1=1035743&r2=1035744&view=diff
> ==============================================================================
> --- maven/doxia/doxia/trunk/doxia-core/src/main/java/org/apache/maven/doxia/parser/AbstractXmlParser.java (original)
> +++ maven/doxia/doxia/trunk/doxia-core/src/main/java/org/apache/maven/doxia/parser/AbstractXmlParser.java Tue Nov 16 18:48:53 2010
> @@ -800,7 +800,7 @@ public abstract class AbstractXmlParser
>             HttpGet method = new HttpGet( url.toString() );
>             // Set a user-agent that doesn't contain the word "java", otherwise it will be blocked by the W3C
>             // The default user-agent is "Apache-HttpClient/4.0.2 (java 1.5)"
> -            method.setHeader( "user-agent", "Apache-HttpClient/4.0.2" );
> +            method.setHeader( "user-agent", "Apache-Doxia/1.1.4" );
>
>             HttpRequestRetryHandler retryHandler = new DefaultHttpRequestRetryHandler( 3, false );
>             client.setHttpRequestRetryHandler(retryHandler);
>
>

--
Brett Porter
[hidden email]
http://brettporter.wordpress.com/




Reply | Threaded
Open this post in threaded view
|

Re: svn commit: r1035744 - /maven/doxia/doxia/trunk/doxia-core/src/main/java/org/apache/maven/doxia/parser/AbstractXmlParser.java

dennisl
On 2010-11-16 23:01, Brett Porter wrote:
> No need to re-roll the release, but I'd set the version by extracting it from the pom.properties file (if it exists) instead of hardcoding it.

Yes, I was thinking the same thing, but didn't have time to fix it this
time around. I will put it in JIRA so it won't be forgotten.

> Cheers,
> Brett
>
> On 17/11/2010, at 5:48 AM, [hidden email] wrote:
>
>> Author: dennisl
>> Date: Tue Nov 16 18:48:53 2010
>> New Revision: 1035744
>>
>> URL: http://svn.apache.org/viewvc?rev=1035744&view=rev
>> Log:
>> [DOXIA-417] The XmlParser is blocked from W3C URLs
>>
>> o Change the user-agent name/version
>>
>> Modified:
>>    maven/doxia/doxia/trunk/doxia-core/src/main/java/org/apache/maven/doxia/parser/AbstractXmlParser.java
>>
>> Modified: maven/doxia/doxia/trunk/doxia-core/src/main/java/org/apache/maven/doxia/parser/AbstractXmlParser.java
>> URL: http://svn.apache.org/viewvc/maven/doxia/doxia/trunk/doxia-core/src/main/java/org/apache/maven/doxia/parser/AbstractXmlParser.java?rev=1035744&r1=1035743&r2=1035744&view=diff
>> ==============================================================================
>> --- maven/doxia/doxia/trunk/doxia-core/src/main/java/org/apache/maven/doxia/parser/AbstractXmlParser.java (original)
>> +++ maven/doxia/doxia/trunk/doxia-core/src/main/java/org/apache/maven/doxia/parser/AbstractXmlParser.java Tue Nov 16 18:48:53 2010
>> @@ -800,7 +800,7 @@ public abstract class AbstractXmlParser
>>             HttpGet method = new HttpGet( url.toString() );
>>             // Set a user-agent that doesn't contain the word "java", otherwise it will be blocked by the W3C
>>             // The default user-agent is "Apache-HttpClient/4.0.2 (java 1.5)"
>> -            method.setHeader( "user-agent", "Apache-HttpClient/4.0.2" );
>> +            method.setHeader( "user-agent", "Apache-Doxia/1.1.4" );
>>
>>             HttpRequestRetryHandler retryHandler = new DefaultHttpRequestRetryHandler( 3, false );
>>             client.setHttpRequestRetryHandler(retryHandler);
>>
>>
>
> --
> Brett Porter
> [hidden email]
> http://brettporter.wordpress.com/
>
>
>
>
>


--
Dennis Lundberg