|
1 | 1 | Dear Spring community, |
2 | 2 |
|
3 | | -I'm pleased to announce that Spring Web Services 2.0 Milestone 1 has been |
| 3 | +I'm pleased to announce that Spring Web Services 2.0 Milestone 2 has been |
4 | 4 | released! |
5 | 5 |
|
6 | | -This is the first milestone release in the 2.0 release cycle. It does not |
7 | | -introduce any new features (yet), but does add the following: |
| 6 | +This is the second milestone release in the 2.0 release cycle. The most |
| 7 | +important new feature in this release is the ability to use arbitrary parameter |
| 8 | +types in @Endpoint methods (similar to @Controller methods in Spring-MVC). The |
| 9 | +big improvement to the 1.5 @Endpoint model is that you can mix and match |
| 10 | +parameters, and are not as limited in the return types. This |
| 11 | +means, for instance, that you can have the following @Endpoint method: |
8 | 12 |
|
9 | | -- Usage of Spring's OXM |
10 | | -- Java 5 API (including generics, varargs, etc) |
| 13 | +@PayloadRoot(localPart = "myRequest", namespace = "http://example.com") |
| 14 | +@ResponsePayload |
| 15 | +public MyJaxb2Response handleMyRequest(@RequestPayload org.w3c.dom.Element myElement, |
| 16 | + SoapHeader requestHeader, |
| 17 | + MessageContext messageContext) { |
11 | 18 |
|
12 | | -Please see the changelog for details. |
| 19 | + // do something interesting here |
| 20 | +} |
13 | 21 |
|
14 | | -Spring Web Services 2.0 is due in the second quarter of 2010. |
| 22 | +Currently supported parameters/return types include: |
| 23 | +- DOM Elements (W3C DOM by default; JDOM, dom4j, XOM are enabled automatically |
| 24 | + if present on the classpath) |
| 25 | +- Types supported by an OXM Marshaller (requires an explicitely configured |
| 26 | + marshaller) |
| 27 | +- JAXB2 types, if JAXB2 is found on the classpath (this means you no longer |
| 28 | + have to configure a Jaxb2Marshaller explicitly) |
| 29 | +- javax.xml.transform.Source and subtypes |
| 30 | + |
| 31 | +For the above parameters/return types, you will have to use |
| 32 | +@RequestPayload/@ResponsePayload, as shown in the sample above. |
| 33 | + |
| 34 | +Supported parameters (not return types) include: |
| 35 | +- MessageContext |
| 36 | +- StAX readers |
| 37 | +- SoapHeader, SoapBody, SoapEvelope (of the request message) |
| 38 | +- @XPathParam parameters. Note that you can now use the @Namespace and |
| 39 | + @Namespaces annotations to specify any namespaces used in your XPath |
| 40 | + expressions, and no longer need to set them up in XML application contexts. |
| 41 | + For instance: |
| 42 | + |
| 43 | +@Namespaces(@Namespace(prefix = "tns", uri = "http://springframework.org/spring-ws")) |
| 44 | +public void myEndpointMethod(@XPathParam("/tns:root")String s) { |
| 45 | +} |
| 46 | + |
| 47 | +These namespace annotations can be present on the method, class, or package |
| 48 | +level (i.e. package-info.java). |
| 49 | + |
| 50 | +In addition to the above, Spring-WS 2.0 M2 includes: |
| 51 | +- Support for Spring Security 3.0 |
| 52 | +- XMPP transport |
| 53 | + |
| 54 | +Please see the changelog for more details. |
| 55 | + |
| 56 | +Spring Web Services 2.0 is due in the third quarter of 2010. |
15 | 57 |
|
16 | 58 | For more information, see http://static.springframework.org/spring-ws/site/ |
0 commit comments