cxf-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Denis Simonov (JIRA)" <>
Subject [jira] [Created] (CXF-5524) JAXBContextInitializer addType stopped handling recursive types (StackOverflow)
Date Fri, 24 Jan 2014 15:44:38 GMT
Denis Simonov created CXF-5524:

             Summary: JAXBContextInitializer addType stopped handling recursive types (StackOverflow)

                 Key: CXF-5524
             Project: CXF
          Issue Type: Bug
          Components: JAXB Databinding
    Affects Versions: 2.7.8, 3.0.0-milestone1, 2.7.2
            Reporter: Denis Simonov
            Priority: Blocker
             Fix For: 3.0.0-milestone2, 2.7.9

As I cannot reopen issue CXF-4711, created this one. If it is possible -delete this one and
reopen CXF-4711.
Reproduced this bug in latest version of CXF 2.7.8 and 3.0.0-milestone1(as well as in fix
version for CXF-4711 - 2.7.2). Same situation described there appears in following case:

public class CxfRecursiveTypeTest {

    public void testRecursiveType() throws Exception {
        Set<Class<?>> classes = new HashSet<Class<?>>();
        Collection<Object> typeReferences = new ArrayList<Object>();
        JAXBContextInitializer jaxbContextInitializer = new JAXBContextInitializer(null, classes,
        Method addClassMethod = JAXBContextInitializer.class.getDeclaredMethod("addClass",
        addClassMethod.invoke(jaxbContextInitializer, Validation.class);

    public static class ObjectGraphProcessorItem<T extends ObjectGraphProcessorItem<T>>

        protected T parentItem;
        protected List<T> childItems = new ArrayList<T>();

        public ObjectGraphProcessorItem(Object object) {

        public List<T> getChildItems() {
            return childItems;

        public void setChildItems(List<T> childItems) {
            this.childItems = childItems;

        public T getParentItem() {
            return parentItem;

        public void setParentItem(T parentItem) {
            this.parentItem = parentItem;

    public static class Validation extends ObjectGraphProcessorItem<Validation> implements
Serializable {

        public Validation() {

        public Validation(Object object) {

This message was sent by Atlassian JIRA

View raw message