@JacksonXmlRootElement does not enforce the local name during deserialization (add XmlReadFeature.ENFORCE_ROOT_ELEMENT_NAME) (original) (raw)

I was redirected here from the google group, so I'll just repeat what I said there : the localName attribute of @JacksonXmlRootElement is not enforced during deserialization. In other words, if I want the input to be

<test>
  <inner>1</inner>
</test>

And I get

<ohnoes>
  <inner>1</inner>
</ohnoes>

inner will still be deserialized properly. This seems weird to me. Here is a fully reproductible test.