Bug 1050003

Summary: [GSS] (6.2.x) Class-Path: . can cause JBAS011046: A component named 'TestBean' is already defined in this module
Product: [JBoss] JBoss Enterprise Application Platform 6 Reporter: Brad Maxwell <bmaxwell>
Component: ServerAssignee: Kyle Lape <klape>
Status: CLOSED CURRENTRELEASE QA Contact:
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 6.2.0CC: cdewolf, jkudrnac, lcosti, myarboro, smumford
Target Milestone: CR1   
Target Release: EAP 6.2.1   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
When deploying a WAR which includes JAR manifests setting `Class-Path` as `.`, annotations in JAR files may have been processed twice. This resulted in failed deployments and produced errors similar to: `JBAS011046: A component named 'TestBean' is already defined in this module`. This issue has been fixed in this release of JBoss EAP 6. When JAR manifests are processed, those containing `Class-Path: .` are now checked and ignored.
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-02-24 20:15:55 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On: 1049999    
Bug Blocks: 1027004    

Description Brad Maxwell 2014-01-08 15:33:44 UTC
'JBAS011046: A component named
'TestBean' is already defined in this module', I have narrowed it
down to it occurs if they have a jar manifest with Class-Path: .
It looks like when deploying it looks at the jar with the manifest
entry which then must be having it scan the jar containing the EJB
again and failing.

Having the Class-Path: . doesn't really make sense to me, however it
also seems like we should not be trying to deploy it twice.

It appears ManifestClassPathProcessor ignores the . when the Class-Path is in a jar at the root of an ear but not when the jar is in a war's WEB-INF/lib

server/src/main/java/org/jboss/as/server/deployment/module/ManifestClassPathProcessor.java

Comment 2 Scott Mumford 2014-01-20 05:48:40 UTC
Marking for inclusion in 6.2.1 release notes documentation.

Comment 6 Jitka Kozana 2014-01-27 15:03:24 UTC
Verified.