[jbossseam-issues] [JBoss JIRA] Created: (JBSEAM-4093) TypeNotPresentException (PostConstruct) in org.jboss.seam.persistence.persistenceProvider

Julien Kronegg (JIRA) jira-events at lists.jboss.org
Thu Apr 9 02:39:22 EDT 2009


TypeNotPresentException (PostConstruct) in org.jboss.seam.persistence.persistenceProvider
-----------------------------------------------------------------------------------------

                 Key: JBSEAM-4093
                 URL: https://jira.jboss.org/jira/browse/JBSEAM-4093
             Project: Seam
          Issue Type: Bug
          Components: Platform interoperability
    Affects Versions: 2.1.2.GA
         Environment: IBM JVM, Websphere 6.1, Seam 2.1.2-SNAPSHOT, http://fisheye.jboss.org/browse/Seam/trunk/src/main/org/jboss/seam/persistence/PersistenceProvider.java?r1=9696&r2=10260
            Reporter: Julien Kronegg


When deploying the WAR on Websphere 6.1, the following stacktrace occurs:

    java.lang.RuntimeException: could not create Component: org.jboss.seam.persistence.persistenceProvider
      at org.jboss.seam.init.Initialization.addComponent(Initialization.java:1198)
      ...
    Caused by: java.lang.TypeNotPresentException: Type javax.annotation.PostConstruct not present
      at com.ibm.oti.reflect.AnnotationHelper.getAnnotation(AnnotationHelper.java:38)
      ...
      at org.jboss.seam.Component.hasAnnotation(Component.java:1160)
      ...

Dan introduced the following code between the two versions of PersistenceProvider:

    @PostConstruct // from the javax.annotations package
    public void init() {}

It seems (see forum) that this annotation comes from the wrong package: it should come from 
    org.jboss.seam.annotations.intercept.PostConstruct
, a class introduced in the very similar issue was raised by Denis Forveille in JBSEAM-3726. 

To correct the problem, the "import javax.annotations.PostConstruct;" must be replaced by "import org.jboss.seam.annotations.intercept.PostConstruct;" in PersistenceProvider


-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        



More information about the seam-issues mailing list