You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Looks like Adapter annotation manages to change effective type to String, which then produces schema you see.
So I don't think it is specific date/time type but converter that is the problem here.
This does not really help much other than suggest that almost any other type would exhibit similar problem with similar annotations.
Oh. Actually... it's probably type=String.class in @XmlElement that is problematic.
Is that actually needed? If not, I'd consider removing it and seeing if that resolves the problem.
yeah, I figure it out the same. However, the jaxb classes are generated by xjc from wsdl, so change it manually really is not an option.
I guess this is mainly due to the java type and/or the @XMLSchemaType is ignored by JaxbAnnotationIntrospector
I don't think @XMLSchemaType could be used in here in the sense that it would related to XML Schema information that Jackson cannot really use for anything. It is possible that type from @XmlElement is used in incorrect way.
You might be able to sub-class JaxbAnnotationIntrospector (or whatever the name is), and override relevant method to discard that bit of information.
run into issue with OffsetJavaDateTime while generate JSON schema from existing jaxb classes.
For example, the jaxb class is defined as following
It generates the following json schema:
what I expect is to have "format" : "date-time" in ExceptionDateTime.
Here's the code I used to test this:
Note that if I register JavaTimeModule only, then I got the correct format element in JSON schema, but it misses the "required" : true
The jackson lib version is 2.13.0
The text was updated successfully, but these errors were encountered: