Hi, Can you explain why we need to add these extra configuration parameters?
Thanks, Raymond ________________________________________________________________ Raymond Feng [email protected] Apache Tuscany PMC member and committer: tuscany.apache.org Co-author of Tuscany SCA In Action book: www.tuscanyinaction.com Personal Web Site: www.enjoyjava.com ________________________________________________________________ On Sep 29, 2010, at 8:47 AM, [email protected] wrote: > Author: antelder > Date: Wed Sep 29 15:47:25 2010 > New Revision: 1002694 > > URL: http://svn.apache.org/viewvc?rev=1002694&view=rev > Log: > Add extra contribution attributes. these are currently only supported by the > node2 Node, i guess all the config classes could be copied to there instead > of changing these here, but ideally node/node2 will get merged into one so > node2 will go away. > > Modified: > > tuscany/sca-java-2.x/trunk/modules/node-api/src/main/java/org/apache/tuscany/sca/node/configuration/ContributionConfiguration.java > > tuscany/sca-java-2.x/trunk/modules/node-api/src/main/java/org/apache/tuscany/sca/node/configuration/impl/ContributionConfigurationImpl.java > > Modified: > tuscany/sca-java-2.x/trunk/modules/node-api/src/main/java/org/apache/tuscany/sca/node/configuration/ContributionConfiguration.java > URL: > http://svn.apache.org/viewvc/tuscany/sca-java-2.x/trunk/modules/node-api/src/main/java/org/apache/tuscany/sca/node/configuration/ContributionConfiguration.java?rev=1002694&r1=1002693&r2=1002694&view=diff > ============================================================================== > --- > tuscany/sca-java-2.x/trunk/modules/node-api/src/main/java/org/apache/tuscany/sca/node/configuration/ContributionConfiguration.java > (original) > +++ > tuscany/sca-java-2.x/trunk/modules/node-api/src/main/java/org/apache/tuscany/sca/node/configuration/ContributionConfiguration.java > Wed Sep 29 15:47:25 2010 > @@ -99,4 +99,43 @@ public interface ContributionConfigurati > * @return > */ > ContributionConfiguration addDeploymentComposite(InputStream content); > + > + /** > + * Set if the deployable composites should be started when the > contribution is installed > + * @param startDeployables whether or not deployable composites should > be started. The default is false. > + */ > + void setStartDeployables(boolean startDeployables); > + > + /** > + * Tests if the deployable composites should be started when the > contribution is installed > + */ > + boolean isStartDeployables(); > + > + /** > + * Gets the URIs of any dependent contributions. The dependent > contributions are the > + * contributions that will be used to resolve any imports used by this > contribution. > + * @return the URIs of any dependent contribution > + */ > + List<String> getDependentContributionURIs(); > + > + /** > + * Sets the dependent contribution URIs for this contribution. The > dependent contributions are the > + * contributions that will be used to resolve any imports used by this > contribution. > + * @param dependentContributionURIs > + */ > + void setDependentContributionURIs(List<String> > dependentContributionURIs); > + > + /** > + * Get the contribution meta data url. This is sca-contribution.xml data > that is added to any > + * existing meta-inf/sca-contribution.xml file within the contribution. > + * @return the metadata url string > + */ > + String getMetaDataURL(); > + > + /** > + * Set the contribution meta data url. This is sca-contribution.xml data > that is added to any > + * existing meta-inf/sca-contribution.xml file within the contribution. > + * @param metaDataURL the url string to the metadata file. > + */ > + void setMetaDataURL(String metaDataURL); > } > > Modified: > tuscany/sca-java-2.x/trunk/modules/node-api/src/main/java/org/apache/tuscany/sca/node/configuration/impl/ContributionConfigurationImpl.java > URL: > http://svn.apache.org/viewvc/tuscany/sca-java-2.x/trunk/modules/node-api/src/main/java/org/apache/tuscany/sca/node/configuration/impl/ContributionConfigurationImpl.java?rev=1002694&r1=1002693&r2=1002694&view=diff > ============================================================================== > --- > tuscany/sca-java-2.x/trunk/modules/node-api/src/main/java/org/apache/tuscany/sca/node/configuration/impl/ContributionConfigurationImpl.java > (original) > +++ > tuscany/sca-java-2.x/trunk/modules/node-api/src/main/java/org/apache/tuscany/sca/node/configuration/impl/ContributionConfigurationImpl.java > Wed Sep 29 15:47:25 2010 > @@ -39,6 +39,9 @@ public class ContributionConfigurationIm > private List<DeploymentComposite> deploymentComposites = new > ArrayList<DeploymentComposite>(); > private String uri; > private String location; > + private boolean startDeployables; > + private List<String> dependentContributionURIs; > + private String metaDataURL; > > public ContributionConfigurationImpl() { > super(); > @@ -152,4 +155,34 @@ public class ContributionConfigurationIm > composite.setLocation(location.toString()); > return addDeploymentComposite(composite); > } > + > + @Override > + public void setStartDeployables(boolean startDeployables) { > + this.startDeployables = startDeployables; > + } > + > + @Override > + public boolean isStartDeployables() { > + return startDeployables; > + } > + > + @Override > + public List<String> getDependentContributionURIs() { > + return dependentContributionURIs; > + } > + > + @Override > + public void setDependentContributionURIs(List<String> > dependentContributionURIs) { > + this.dependentContributionURIs = dependentContributionURIs; > + } > + > + @Override > + public String getMetaDataURL() { > + return metaDataURL; > + } > + > + @Override > + public void setMetaDataURL(String metaDataURL) { > + this.metaDataURL = metaDataURL; > + } > } > >
