JAXB: Namespace annotation not inherited during unmarshalling - regression in JDK 1.8_102?

前端 未结 1 1033
我寻月下人不归
我寻月下人不归 2021-01-19 02:01

I ran into a situation where JAXB refuses to unmarshal an XML element unless the corresponding Java field has a namespace annotation. This behavior only started in JDK 1.8.0

1条回答
  •  攒了一身酷
    2021-01-19 02:25

    I think this is the relevant bug - https://bugs.openjdk.java.net/browse/JDK-8165299

    From which I can say that there was indeed a fix for JAXB. So this strange behavior which ends up in null values is a wrong JAXB mapping and not a regression in Java.

    0 讨论(0)
提交回复
热议问题