mirror of https://github.com/apache/archiva.git
add comment in code snippet and add a snippet in pom for rest dependencies
git-svn-id: https://svn.apache.org/repos/asf/archiva/trunk@1295689 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
3182934f75
commit
aabab285c4
|
@ -207,12 +207,14 @@ public abstract class AbstractArchivaRestTest
|
|||
JAXRSClientFactory.create( getBaseUrl() + "/" + getRestServicesPath() + "/archivaServices/",
|
||||
SearchService.class,
|
||||
Collections.singletonList( new JacksonJaxbJsonProvider() ) );
|
||||
|
||||
// to add authentification
|
||||
if ( authzHeader != null )
|
||||
{
|
||||
WebClient.client( service ).header( "Authorization", authzHeader );
|
||||
}
|
||||
// to configure read timeout
|
||||
WebClient.getConfig( service ).getHttpConduit().getClient().setReceiveTimeout( 100000000 );
|
||||
// if you want to use json as exchange format xml is supported too
|
||||
WebClient.client( service ).accept( MediaType.APPLICATION_JSON_TYPE );
|
||||
WebClient.client( service ).type( MediaType.APPLICATION_JSON_TYPE );
|
||||
return service;
|
||||
|
|
3
pom.xml
3
pom.xml
|
@ -471,6 +471,7 @@
|
|||
<artifactId>jsr311-api</artifactId>
|
||||
<version>1.1.1</version>
|
||||
</dependency>
|
||||
<!-- START SNIPPET: rest-dependencies -->
|
||||
<dependency>
|
||||
<groupId>org.codehaus.jackson</groupId>
|
||||
<artifactId>jackson-jaxrs</artifactId>
|
||||
|
@ -505,7 +506,7 @@
|
|||
</exclusion>
|
||||
</exclusions>
|
||||
</dependency>
|
||||
|
||||
<!-- END SNIPPET: rest-dependencies -->
|
||||
<dependency>
|
||||
<groupId>com.google.guava</groupId>
|
||||
<artifactId>guava</artifactId>
|
||||
|
|
Loading…
Reference in New Issue