You are viewing a plain text version of this content. The canonical link for it is here.
Posted to scm@geronimo.apache.org by ga...@apache.org on 2010/02/23 01:19:17 UTC
svn commit: r915117 -
/geronimo/server/trunk/framework/modules/geronimo-deployment/src/main/java/org/apache/geronimo/deployment/DeploymentContext.java
Author: gawor
Date: Tue Feb 23 00:19:17 2010
New Revision: 915117
URL: http://svn.apache.org/viewvc?rev=915117&view=rev
Log:
make sure the dependencies in environment and in geronimo-plugin.xml as the same
Modified:
geronimo/server/trunk/framework/modules/geronimo-deployment/src/main/java/org/apache/geronimo/deployment/DeploymentContext.java
Modified: geronimo/server/trunk/framework/modules/geronimo-deployment/src/main/java/org/apache/geronimo/deployment/DeploymentContext.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/framework/modules/geronimo-deployment/src/main/java/org/apache/geronimo/deployment/DeploymentContext.java?rev=915117&r1=915116&r2=915117&view=diff
==============================================================================
--- geronimo/server/trunk/framework/modules/geronimo-deployment/src/main/java/org/apache/geronimo/deployment/DeploymentContext.java (original)
+++ geronimo/server/trunk/framework/modules/geronimo-deployment/src/main/java/org/apache/geronimo/deployment/DeploymentContext.java Tue Feb 23 00:19:17 2010
@@ -195,7 +195,7 @@
ConfigurationData configurationData = new ConfigurationData(moduleType, null, childConfigurationDatas, environment, baseDir, inPlaceConfigurationDir, naming);
File tempBundleFile = FileUtils.createTempFile();
createTempManifest();
- createTempPluginMetadata();
+ createPluginMetadata();
JarUtils.jarDirectory(baseDir, tempBundleFile);
String location = "reference:file:" + URLEncoder.encode(tempBundleFile.getAbsolutePath(), "UTF-8");
tempBundle = bundleContext.installBundle(location);
@@ -210,7 +210,7 @@
}
}
- private void createTempPluginMetadata() throws IOException, JAXBException, XMLStreamException {
+ private void createPluginMetadata() throws IOException, JAXBException, XMLStreamException {
PluginType pluginType = new PluginType();
pluginType.setName("Temporary Plugin metadata for deployment");
PluginArtifactType instance = new PluginArtifactType();
@@ -564,6 +564,13 @@
if (environment.getBundleActivator() == null) {
environment.setBundleActivator(ConfigurationActivator.class.getName());
}
+
+ try {
+ createPluginMetadata();
+ } catch (Exception e) {
+ throw new DeploymentException("Failed to update geronimo-plugin.xml", e);
+ }
+
ConfigurationData configurationData = new ConfigurationData(configuration.getModuleType(),
gbeans,
childConfigurationDatas,