1 Reply Latest reply on Oct 30, 2008 10:30 AM by peterj

    java.lang.IllegalStateException: Can't overwrite cause

      Dear All,

      I used below tools to build up my EJB project :
      - NetBean
      - JBoss
      - MySQL

      After successful created Stateless Bean & persistence units. I try to create Entity class from database. After that, I try to deploy such project and JBoss Application Server response below error message :

      ObjectName: persistence.units:ear=ScheduleTool.ear,jar=ScheduleTool-ejb.jar,unitName=ScheduleTool-ejbPU
      State: FAILED
      Reason: java.lang.IllegalStateException: Can't overwrite cause
      I Depend On:
      jboss.jca:service=DataSourceBinding,name=STS


      Also, I cannot find Persistence.Units item in Global JNDI Namespace webpage.

      Please please kindly been help. Thanks !

      OUHK

        • 1. Re: java.lang.IllegalStateException: Can't overwrite cause
          peterj

          The text you posted is part of a report the deployer prints after it finished deploying everything. This report typically contains no information about the root cause of the deployment failure. Earlier in the console log there should be a stack trace that provides the cause - find the very first exception stack trace and post it in its entirety.

          Regarding the persistence unit, please post the source for your session bean, and the source for persistence.xml. Make sure you enclose the source code in 'code' tags. You can do this by selecting the text and then clicking the Code button. Click the Preview button and check the formatting of your post before posting it.