THIS IS A TEST INSTANCE. ALL YOUR CHANGES WILL BE LOST!!!!
Table of Contents |
---|
Introduction
This page describes how CXF JAX-RS Client code can be used inside SpringBoot applications.
Please see a CXF JAX-RS starter section on how to enable JAX-RS endpoints.
Setup
If your SpringBoot Application depends on a CXF JAX-RS starter section then no more dependencies are required.
If you'd like to run JAX-RS clients in a pure client-side SpringBoot Application then the following Maven pom should suffice in many cases:
Code Block | ||
---|---|---|
| ||
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0
http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-parent</artifactId>
<version>1.3.5.RELEASE</version>
</parent>
<artifactId>spring-boot-cxf-client-application</artifactId>
<groupId>org.apache.cxf.samples</groupId>
<version>3.1.7</version>
<name>Spring Boot CXF Client Application</name>
<description>Spring Boot CXF Client Application</description>
<properties>
<cxf.version>3.1.7</cxf.version>
</properties>
<dependencies>
<dependency>
<groupId>org.apache.cxf</groupId>
<artifactId>cxf-rt-rs-client</artifactId>
<version>${cxf.version}</version>
</dependency>
</dependencies>
<build>
<plugins>
<plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
<configuration>
<mainClass>sample.rs.client.SpringBootCxfClientApplication</mainClass>
</configuration>
</plugin>
</plugins>
</build>
</project>
|