0

After successfully installing and using one of our web applications, I tried to restart the application (via Integrated Solutions Console), but the outcome was not what I was expecting. The SystemOut.log file was immediately flooded with exceptions. I'll just highlight the most relevants:

java.lang.ClassCastException: pt.sibs.epms.persistence.entity.EpmsDebugParameters incompatible with pt.sibs.epms.persistence.entity.EpmsDebugParameters
                at pt.sibs.epms.ecc.ApplicationManager.init(ApplicationManager.java:100) ~[classes/:na]

java.lang.IllegalArgumentException: Object: x.EccAudit[ eccAuditPK=x.EccAuditPK[ eventUsername=system, eventTimestamp=Thu Jul 14 17:20:04 BST 2016, eventModule=ECC ] ] is not a known Entity type.
                at org.eclipse.persistence.internal.sessions.UnitOfWorkImpl.registerNewObjectForPersist(UnitOfWorkImpl.java:4229) ~[com.ibm.ws.jpa.eclipselink.jar:na]

CWOWB2001E: A POST_CONSTRUCT lifecycle inteceptor threw an exception: org.jboss.weld.exceptions.WeldException: WELD-000049: Unable to invoke public void pt.sibs.epms.ecc.ThreadPoolManager.init() on pt.sibs.epms.ecc.ThreadPoolManager@7878f48b
                at org.jboss.weld.injection.producer.DefaultLifecycleCallbackInvoker.invokeMethods(DefaultLifecycleCallbackInvoker.java:100)

CNTR0020E: EJB threw an unexpected (non-declared) exception during invocation of method "init" on bean "BeanId(EpmsControlCenter-v2#EpmsControlCenter.war#NotificationEventGenerator, null)". Exception data: org.jboss.weld.exceptions.WeldException: WELD-000049: Unable to invoke public void pt.sibs.epms.ecc.ThreadPoolManager.init() on pt.sibs.epms.ecc.ThreadPoolManager@7878f48b
                at org.jboss.weld.injection.producer.DefaultLifecycleCallbackInvoker.invokeMethods(DefaultLifecycleCallbackInvoker.java:100)

CNTR0019E: EJB threw an unexpected (non-declared) exception during invocation of method "fireScheduledEvent". Exception data: javax.ejb.NoSuchEJBException: An error occurred during initialization of singleton session bean EpmsControlCenter-v2#EpmsControlCenter.war#NotificationEventGenerator, resulting in the discarding of the singleton instance.; nested exception is: javax.ejb.EJBException: See nested exception; nested exception is: org.jboss.weld.exceptions.WeldException: WELD-000049: Unable to invoke public void pt.sibs.epms.ecc.ThreadPoolManager.init() on pt.sibs.epms.ecc.ThreadPoolManager@7878f48b
                at com.ibm.ejs.container.util.ExceptionUtil.NoSuchEJBException(ExceptionUtil.java:540)

SRVE0293E: [Servlet Error]-[Faces Servlet]: java.lang.IllegalArgumentException: Unknown Entity bean class: class pt.sibs.epms.persistence.entity.EpmsOtherSystemParameters, please verify that this class has been marked with the @Entity annotation.
                at org.eclipse.persistence.internal.jpa.EntityManagerImpl.find(EntityManagerImpl.java:718)

The application is no longer working and I have to restart the server to make it work again. Not cool.

Any ideas?

EDIT #1

This seems to happen only after redeploys.

EPMS Devteam
  • 273
  • 2
  • 15
  • For re-deployment, are you using the 'Update' option or do you uninstall and re-install the application? – Haxiel Jul 21 '16 at 15:08
  • @XSurgent, I'm using the update option. – EPMS Devteam Jul 21 '16 at 16:19
  • No problem on that side, then. I've seen temporary artifacts causing trouble with the uninstall/re-install route, which is why I wanted to check. – Haxiel Jul 21 '16 at 17:41
  • And it is really a pain. JRebel doesn't yet support WAS 9 and redeploys force me to restart the profile. I'm trying to fix a bug and it is taking me ages. – EPMS Devteam Jul 22 '16 at 07:19

1 Answers1

0

You need to restart the application after the redeploy, as CDI does not support the dynamic update scenario.

Emily Jiang
  • 151
  • 3
  • I don't think that will solve the issue as I'm stopping the application before updating it and starting it afterwards. – EPMS Devteam Jul 22 '16 at 14:24
  • Please contact IBM Help Desk to report this issue. – Emily Jiang Jul 22 '16 at 21:50
  • contacting IBM was completely useless, they require a customer ID, which I don't have. The software is bought by the company, they are the ones who have the ID and I'm not allowed to use it. – EPMS Devteam Sep 21 '16 at 10:21