summaryrefslogtreecommitdiffstats
path: root/sca-java-2.x/trunk
diff options
context:
space:
mode:
authorantelder <antelder@13f79535-47bb-0310-9956-ffa450edef68>2012-03-21 10:43:13 +0000
committerantelder <antelder@13f79535-47bb-0310-9956-ffa450edef68>2012-03-21 10:43:13 +0000
commit1f3b3a280da7235f865188d43ae516cfcd3c3baf (patch)
tree4cba67e068df7d6a2a599eba30891b2ebe61d9a2 /sca-java-2.x/trunk
parentf0004c884787a12918774ae8d0e375d5a1150a2c (diff)
Fix Node validateContribution to not cause duplicate definition problems by removing definitions aggregation from the resolve method
git-svn-id: http://svn.us.apache.org/repos/asf/tuscany@1303355 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'sca-java-2.x/trunk')
-rw-r--r--sca-java-2.x/trunk/modules/deployment/src/main/java/org/apache/tuscany/sca/deployment/impl/DeployerImpl.java34
1 files changed, 18 insertions, 16 deletions
diff --git a/sca-java-2.x/trunk/modules/deployment/src/main/java/org/apache/tuscany/sca/deployment/impl/DeployerImpl.java b/sca-java-2.x/trunk/modules/deployment/src/main/java/org/apache/tuscany/sca/deployment/impl/DeployerImpl.java
index 57bd6507d9..4631462aab 100644
--- a/sca-java-2.x/trunk/modules/deployment/src/main/java/org/apache/tuscany/sca/deployment/impl/DeployerImpl.java
+++ b/sca-java-2.x/trunk/modules/deployment/src/main/java/org/apache/tuscany/sca/deployment/impl/DeployerImpl.java
@@ -629,22 +629,24 @@ public class DeployerImpl implements Deployer {
for (Contribution contribution : contributionList) {
monitor.pushContext("Contribution: " + contribution.getURI());
try {
- // aggregate definitions
- for (Artifact artifact : contribution.getArtifacts()) {
- if (!"META-INF/definitions.xml".equals(artifact.getURI())) {
- continue;
- }
- Object model = artifact.getModel();
- // FIXME: Should we check the artifact URI is META-INF/definitions.xml?
- if (model instanceof Definitions) {
- try {
- monitor.pushContext("Definitions: " + artifact.getLocation());
- DefinitionsUtil.aggregate((Definitions)model, systemDefinitions, monitor);
- } finally {
- monitor.popContext();
- }
- }
- }
+// For now don't aggregate definitions in resolve as that causes duplicate definitions when build is run
+// as there is no way presently to remove aggregated definitions
+// // aggregate definitions
+// for (Artifact artifact : contribution.getArtifacts()) {
+// if (!"META-INF/definitions.xml".equals(artifact.getURI())) {
+// continue;
+// }
+// Object model = artifact.getModel();
+// // FIXME: Should we check the artifact URI is META-INF/definitions.xml?
+// if (model instanceof Definitions) {
+// try {
+// monitor.pushContext("Definitions: " + artifact.getLocation());
+// DefinitionsUtil.aggregate((Definitions)model, systemDefinitions, monitor);
+// } finally {
+// monitor.popContext();
+// }
+// }
+// }
// create a default import and wire it up to the system contribution
// model resolver. This is the trick that makes the resolution processing