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
We are using Dozer to map object trees resulting from a JAXB deserialization of XML documents containing lots of XMLGregorianCalendar values.
While processing large numbers of such objects (in the magnitude of tens of millions) we noticed that a lot of time is spent in calls to DatatypeFactory.newInstance() being issued from ConstructionStrategies.
Observed Results:
The inner class XmlGregorian in com.github.dozermapper.core.factory.ConstructionStrategies is creating a new instance of DatatypeFactory for each XMLGregorianCalendar object it is asked to create via calls to create(BeanCreationDirective directive).
Expected Results:
The overhead should be avoided so that creating XMLGregorianCalendar objects to map into remains reasonably cheap.
Whats your runtime?
Whats the problem?
We are using Dozer to map object trees resulting from a JAXB deserialization of XML documents containing lots of XMLGregorianCalendar values.
While processing large numbers of such objects (in the magnitude of tens of millions) we noticed that a lot of time is spent in calls to
DatatypeFactory.newInstance()
being issued fromConstructionStrategies
.Observed Results:
The inner class
XmlGregorian
incom.github.dozermapper.core.factory.ConstructionStrategies
is creating a new instance of DatatypeFactory for each XMLGregorianCalendar object it is asked to create via calls tocreate(BeanCreationDirective directive)
.Expected Results:
The overhead should be avoided so that creating XMLGregorianCalendar objects to map into remains reasonably cheap.
Link to GitHub repo with fix
We will provide a fix via https://github.com/kuehne-nagel/dozer/tree/datatypefactory and a pull request from there.
The text was updated successfully, but these errors were encountered: