[seam-issues] [JBoss JIRA] Commented: (JBSEAM-3996) Seam should ignore duplicate classes on classpath

Max Rydahl Andersen (JIRA) jira-events at lists.jboss.org
Fri Feb 26 07:59:10 EST 2010


    [ https://jira.jboss.org/jira/browse/JBSEAM-3996?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12516966#action_12516966 ] 

Max Rydahl Andersen commented on JBSEAM-3996:
---------------------------------------------

note, the current patch will probably work in a single standalone unit tests, but running inside a container that you might be scanning manually you could bump into the same classname but different classloaders and then the equals method will return false and that is exactly the case we want to avoid.

Reading Marek's note says it does solve it for JBDS which is great - but just saying that I think the correct patch is to just use the class name and ignore any of the classloader comparison clazz().equals will do.

> Seam should ignore duplicate classes on classpath
> -------------------------------------------------
>
>                 Key: JBSEAM-3996
>                 URL: https://jira.jboss.org/jira/browse/JBSEAM-3996
>             Project: Seam
>          Issue Type: Bug
>          Components: Core
>    Affects Versions: 2.1.0.SP1, 2.1.1.GA
>            Reporter: Max Rydahl Andersen
>            Assignee: Marek Novotny
>            Priority: Critical
>             Fix For: 2.2.1.CR1
>
>
> As discussed in JBIDE-3623 then Seam is reporting "Two components with the same name and precedence - component name: <name>, component classes: <classname>" when the class name is exactly the same. In that case it should only be the one that is first on the classpath that is used; that the class exist in other locations is irrelevant since you won't be able to load the class anyway since in java classloading first-found wins.

-- 
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