August 26, 2010

EclipseLink 2.1.1 Patch Set Released

The first patch set for the EclipseLink 2.1 stream is now available.  EclipseLink 2.1.1 can be downloaded here:

The following XML binding layer bugs were fixed:

Using @XmlAnyElement to Build a Generic Message

In this post we are building our own XML messaging framework.  We want to have a standard message object (similar to a SOAP envelope) that the framework can understand, and the ability to easily add domain specific payloads over time.

August 25, 2010

@XmlTransformation - Going Beyond XmlAdapter

XML Adapter is my favourite JAXB feature, which is why it was the topic of my first post XmlAdapter - JAXB's Secret Weapon.  With it there is no such thing as an unmappable object in JAXB.  However today I came across a use case where the MOXy's transformation mapping was a much better fit.

August 23, 2010

Creating a RESTful Web Service - Part 5/5

In this post we will examine how a client may interact with the RESTful service we created in part 4

August 20, 2010

Creating a RESTful Web Service - Part 4/5

Java API for RESTful Web Services (JAX-RS) is the Java EE standard for creating RESTful Web Services.  In this post we will create a RESTful service from an EJB session bean using JAX-RS.

Creating a RESTful Web Service - Part 3/5

Java Architecture for XML Binding (JAXB) is the Java EE standard for mapping POJOs to XML.  In this example we will use JAXB to apply an XML representation to the JPA entities we created in part 2.  Since we are mapping JPA entities to XML we will use the EclipseLink JAXB  (MOXy) implementation and leverage some of its extensions.

Some developers will maintain separate JPA and JAXB models, and perform a copy step to move data between them.  This can be quite a painful and error prone process.  Luckily MOXy has a number of extensions that make this unnecessary:

August 19, 2010

Creating a RESTful Web Service - Part 2/5 (Annotations)

Java Persistence Architecture (JPA) is the Java EE standard for mapping POJOs to a relational database. In this example we will use JPA to interact with our database data we set up in part 1.

August 18, 2010

Creating a RESTful Web Service - Part 1/5

I have been doing a lot of work with data access services recently so I figure it's time to share what I have discovered.  Don't be scared off that this series is broken into 5 parts, I will keep them short:

In this series of posts we will use a number of standard Java EE technologies to quickly create a RESTful data access service:

August 17, 2010

XML Binding Talk at JavaOne

This year I will be doing a talk on XML Binding at JavaOne in San Francisco.  I will be pitting the two XML binding standards:  JAXB  (JSR-222) & SDO (JSR-235) against each other to help you determine which one is right for you.  I hope to see you there.


Effective XML: Leveraging JAXB and SDO (S314491)
Wednesday September 22, 1-2pm
Hilton San Francisco, Yosemite A

August 11, 2010

JAXB & Namespaces

The majority of XML documents are namespace qualified, yet most XML binding examples do not demonstrate namespaces (sometimes because the XML binding solution does not support them). In this post I'll demonstrate how easy namespace handling is using JAXB.