Building JAXB Contexts with Huge XSDs Runs Out of Memory- Workaround?
Edit: This guy has the same problem, and does a better job of explaining it I feel: http://www.java.net/forum/topic/glassfish/metro-and-jaxb/building-jaxb-contexts-huge-xsds-runs-ou
My colleagues have informed me that we have so many JAXB types, that we're running out of memory in our deployment environment when loading them via JAXB context, and have asked me and others to take a look at it. They may have already increased the heap size to the max, and new hardware is out of the question for now(assume we're stuck with 3开发者_如何转开发2-bit for now). They've talked about splitting JAXB projects up and using different contexts, although I don't see how that helps if they want everything in memory at the same time. I've suggested inserting explicit calls to the Garbage Collector, but that didn't go over well. Any thoughts?
The JAXB context uses reflection, so they needed to increase their permgen space.
精彩评论