|
Re: Classes with @MappedSuperclass use a lot of memory [message #1826174 is a reply to message #1824482] |
Mon, 20 April 2020 15:42  |
Chris Delahunt Messages: 1389 Registered: July 2009 |
Senior Member |
|
|
As for the 600MB extra memory - it would entirely depend on what is in there, to which you've not provided any insights, such as how many persistence units this is used in, how much memory was required before this base jar was added etc. Doesn't sound like a bug though, and until you know what/where the cause is, no one can suggest workarounds or switches to disable memory consumption. Could be you defined a million named queries on one of those base classes - who but you can say?
I'm not sure what you mean "even if the service doesn't use any base entity", but everything referenced from a persistence unit must be loaded when the persistence unit is loaded. Everything must be traversed looking for annotations etc that build metadata for every entity within the persistence unit, and this happens upon deployment. If this is a concern, you should be using smaller, compartmentalized persistence units, to prevent having to load unnecessary classes and mapping data.
|
|
|
Powered by
FUDForum. Page generated in 0.01924 seconds