[
http://jira.jboss.com/jira/browse/JBSEAM-2799?page=comments#action_12406054 ]
Shane Bryzak commented on JBSEAM-2799:
--------------------------------------
What did you have in your components.xml? The easiest way to reproduce this is to simply
create the following class in the seamspace example and deploy.
package org.jboss.seam.example.seamspace;
import static org.jboss.seam.ScopeType.APPLICATION;
import org.jboss.seam.annotations.Install;
import org.jboss.seam.annotations.Name;
import org.jboss.seam.annotations.Scope;
import org.jboss.seam.annotations.intercept.BypassInterceptors;
import org.jboss.seam.security.management.JpaIdentityStore;
@Name("org.jboss.seam.security.management.jpaIdentityStore")
@Install(precedence = Install.APPLICATION)
@Scope(APPLICATION)
@BypassInterceptors
public class CustomJpaIdentityStore extends JpaIdentityStore { }
Overridden components with @Install(value = false) ignores
precedence.
----------------------------------------------------------------------
Key: JBSEAM-2799
URL:
http://jira.jboss.com/jira/browse/JBSEAM-2799
Project: JBoss Seam
Issue Type: Bug
Components: Core
Reporter: Shane Bryzak
Assigned To: Shane Bryzak
Priority: Critical
Fix For: 2.1.0.BETA1
An easy way to reproduce this - take the JpaIdentityStore as an example:
@Name("org.jboss.seam.security.management.jpaIdentityStore")
@Install(precedence=Install.BUILT_IN, value = false)
@Scope(APPLICATION)
@BypassInterceptors
public class JpaIdentityStore implements IdentityStore, Serializable
Overriding it with a component with a higher precedence fails:
@Name("org.jboss.seam.security.management.jpaIdentityStore")
@Install(precedence = Install.APPLICATION)
@Scope(APPLICATION)
@BypassInterceptors
public class CustomJpaIdentityStore extends JpaIdentityStore
With the following stack trace:
java.lang.IllegalStateException: Two components with the same name and precedence:
org.jboss.seam.security.management.jpaIdentityStore
at
org.jboss.seam.init.Initialization.addComponentDescriptor(Initialization.java:484)
at
org.jboss.seam.init.Initialization.installScannedComponentAndRoles(Initialization.java:755)
at org.jboss.seam.init.Initialization.scanForComponents(Initialization.java:702)
at org.jboss.seam.init.Initialization.init(Initialization.java:567)
at org.jboss.seam.servlet.SeamListener.contextInitialized(SeamListener.java:34)
at
org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:3856)
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira