Project: mule
Issue MULE-7817: ClassLoader leak due to wrong use of DEFAULT_THREADING_PROFILE
MuleWorkManager is created based on the DEFAULT_THREADING_PROFILE. Because that default threading profile implements MuleContextAware, it ends up holding a reference to the application's muleContext. This causes the muleContext not to be collected and ultimately the classLoader is not collected. DEFAULT_THREADING_PROFILE should never be assigned directly. Only copies should be used.
Story points: 4