-
1. Re: ejb3_1 and its relation with ejb3 bom
alrubinger Apr 9, 2010 12:37 PM (in response to jaikiran)jaikiran pai wrote:
As such, I think that the ejb3 bom as-6 should be the parent for the ejb3_1 module. That way, the ejb3_1 module pom will just declare the dependencies and let the parent bom declare the dependency versions.
I think this is good, though there's something worthy of noting here.
If the BOM is the parent of the ejb3_1 module, then the ejb3_1 module will have the correct exported dependencies. Now something else, project X, makes a depedendency upon ejb3_1. Any "exclusion"s defined by the BOM will be *ignored*. This is because Project X doesn't have the BOM in its hierarchy. The way around this is to declare in Project X a dependency twice upon ejb3_1; once in "dependencies", once in "dependencyManagement" (with scope import).
S,
ALR
-
2. Re: ejb3_1 and its relation with ejb3 bom
jaikiran Apr 9, 2010 12:47 PM (in response to alrubinger)Andrew Rubinger wrote:
jaikiran pai wrote:
As such, I think that the ejb3 bom as-6 should be the parent for the ejb3_1 module. That way, the ejb3_1 module pom will just declare the dependencies and let the parent bom declare the dependency versions.
I think this is good
(I think) there's a catch though. The ejb3_1 module can go into both AS6.0 and AS6.1 (let's assume we have it). And AS6.0 and AS6.1 will have separate bom artifacts. So we won't be able to mark this bom as the parent for ejb3_1.
-
3. Re: ejb3_1 and its relation with ejb3 bom
jaikiran Apr 9, 2010 12:53 PM (in response to alrubinger)Andrew Rubinger wrote:
If the BOM is the parent of the ejb3_1 module, then the ejb3_1 module will have the correct exported dependencies. Now something else, project X, makes a depedendency upon ejb3_1. Any "exclusion"s defined by the BOM will be *ignored*. This is because Project X doesn't have the BOM in its hierarchy. The way around this is to declare in Project X a dependency twice upon ejb3_1; once in "dependencies", once in "dependencyManagement" (with scope import).
S,
ALR
The project X that I was considering was AS. So we would have something like:
ejb3_1 module pom.xml:
<parent> <artifactId>bom-as6</artifactId> <version>0.1.3</version> </parent> <artifactId>jboss-ejb3_1</artifactId>
bom-as6 pom.xml:
<artifactId>bom-as6</artifactId> <dependencyManagement> <dependency> <artifactId>jboss-ejb3-core</artifactId> <version>1.3.2</version> </dependency> <!-- rest of the dep management --> </dependencyManagement>
JBoss AS component-matrix pom.xml (or some module which "imports" the bom)
<dependencyManagement> <dependency> <artifactId>bom-as6</artifactId> <scope>import</scope> </dependency> </dependencyManagement>
The AS/ejb3 module pom.xml would add "dependency" on *ejb3_1*
<dependencies> <dependency> <artifactId>jboss-ejb3_1</artifactId> <!-- We don't specify any version here, it will be picked up from bom --> </dependency> </dependencies>
But like I said in my previous post, making bom-as6 the parent of ejb3_1 may not work out.
-
4. Re: ejb3_1 and its relation with ejb3 bom
jaikiran Apr 9, 2010 12:56 PM (in response to jaikiran)The other option that I have been thinking of is to get rid of ejb3_1 entirely. That way we will have a bom which will both have dependencyManagement and dependencies specified. Effectively, that will act as the entity which manages the right versions and also let's the consuming projects (like AS) "depend" (so that dependencies are pulled in the CP) as well as import it. So we would probably end up having bom-as6 (multiple version), bom-as-6.1 (multiple versions) artifacts.