- CXF 2.7.x no longer supports Java 5. In order to upgrade to 2.7.0, you must be using Java 6 (or newer). Many of the dependencies that CXF uses have moved to Java 6 and in order to get fixes and updates, we have moved to Java 6 as well.
- New UDP Transport.
- New optional HTTP transport based on Apache HTTP Components HttpAsyncClient.
- Support for the SOAP over UDP.
- Ability to only apply schema validation to incoming or outgoing messages by setting the "schema-validation-enabled" property to "IN", "OUT", "BOTH", or "NONE". @SchemaValidationEnabled annotation updated to have a type=IN|OUT|BOTH|NONE parameter.
- Support for WS-Discovery.
- Services can send Hello/Bye when started/stopped as well as respond to Probe requests
- API for sending probes and resolving to EndpointReferences
- Initial support for parts of the JAX-RS 2.0 (JSR-339) specification
Major Dependency Changes
- The Jetty based HTTP transport has been updated from Jetty 7.6 to Jetty 8.1. This brings in all the new functionality of the Servlet API 3.0 specification. The transport can still work with the older 7.6 and 7.5 versions of Jetty, but you will need to exclude the 8.1 versions and explicitly depend on the appropriate Jetty dependencies and servlet-api jar.
- The HTTPConduit class has been made abstract with the HttpURLConnection related code moving to an URLConnectionHTTPConduit. Several method calls of the HTTPConduit that used to take HttpURLConnection objects have been eliminated. Also, most methods taking a URL object now take a URI object instead. The HTTPConduit.WrappedOutputStream class is also now abstract. If you have custom subclasses of HTTPConduit, changing them to subclass URLConnectionHTTPConduit will likely work.
- The WS-Addressing related VersionTransformer and MAPCodec classes have been changed to not encode the WS-Addressing headers to DOM elements and instead just use the Header list on the SoapMessage directly. This did change the parameters on the encode methods to take the JAXBContext instead of the Marshaller. Any custom VersionTransformers will need to be updated. (very rare)
- All methods that took or returned org.apache.cxf.feature.AbstractFeatures have been changed to just use org.apache.cxf.feature.Feature.
- JAX-RS: 3 classes have been removed from the org.apache.cxf.jaxrs.client package: ResponseReader, ServerWebApplicationException, ClientWebApplicationException. The first class in the list is not needed with JAX-RS 2.0 Response class, the latter two are replaced by javax.ws.rs.WebApplicationException and javax.ws.rs.client.ClientException
- The STS Claims object now uses a List<String> for the values instead of a single String value.
- The following CXF JAX-RS specific extensions have been deprecated and will be eventually removed
- org.apache.cxf.jaxrs.ext.ParamHandler (use javax.ws.rs.ext.ParamConverterProvider and javax.ws.rs.ext.ParamConverter instead).
- org.apache.cxf.jaxrs.ext.RequestHandler and org.apache.cxf.jaxrs.ext.ResponseHandler (use javax.ws.rs.container.ContainerRequestFilter and javax.ws.rs.container.ContainerResponseFilter instead).
Note that no @Deprecated annotation has been attached to the deprecated classes in order to minimize the 'noise' in the runtime code while these classes are still maintained.
JAX-RS endpoints in OSGI
- If you have compiled the application bundles against JSR-311 (JAX-RS 1.1) API and would like to get them running with CXF 2.7.x without recompiling against JSR-339 (JAX-RS 2.0) API then either
- have "javax.ws.rs", "javax.ws.rs.core" and "javax.ws.rs.ext" imported with the "[1.1, 3)" version range and use org.apache.servicemix.specs.jsr339-api-m10-2.1.0 spec bundle or
- use org.apache.servicemix.specs.jsr339-api-m10-2.2.0 spec bundle when it gets released.