1 Reply Latest reply on Sep 4, 2008 4:59 PM by nimo22

    Install(precedence = APPLICATION) IdentityStore

    nimo22

      In 15.12. Extending the Identity component, there is an example of extending a SEAM-Component. It is said:


      The install precendence of APPLICATION ensures that this extended Identity gets installed in preference to the built-in Identity.



      But when I do this:


      @Name("org.jboss.seam.security.jpaIdentityStore")
      @Install(precedence = org.jboss.seam.annotations.Install.APPLICATION)
      @Scope(APPLICATION)
      @BypassInterceptors
      @Startup
      public class MyIdentityStore implements IdentityStore, Serializable
      {



      then this failure occurs:


      java.lang.IllegalStateException: Two components with the same name and precedence - component name: org.jboss.seam.security.jpaIdentityStore, component classes: com.MyIdentityStore



      when I do this, then MyIdentityStore is installed:



      @Name("org.jboss.seam.security.jpaIdentityStore")
      @Install(precedence = DEPLOYMENT)
      @Scope(APPLICATION)
      @BypassInterceptors
      @Startup
      public class MyIdentityStore implements IdentityStore, Serializable
      {



      However, then I can find in my Application Scope, both MyIdentityStore and JpaIdentityStore. Is that okay?