Quote:
What appears to happen is that the Person is returned from JPA/Hibernate and then CXF is walking the object model to serialize it and it hits the lazy associations and then throws an exception because the transaction is closed and CXF/JAXB is forcing the retrieval of those lazy loaded entities.
You said before "the transaction is pointcut around the data service", so why is it closed now? It must be around CXF processing.
Quote:
Is there something I can do to resolve this or will I have to force detach these objects before serializing them with JAXB?
Kind of the opposite, you must guarantee that the Session is open until you finished serializing, you should couple the Session lifecycle to the transaction, i.e. also around the CXF processing.