You are viewing a plain text version of this content. The canonical link for it is here.
Posted to scm@geronimo.apache.org by dj...@apache.org on 2006/01/09 22:28:59 UTC
svn commit: r367399 - in
/geronimo/trunk/modules/hot-deploy/src/java/org/apache/geronimo/deployment/hot:
DirectoryHotDeployer.java DirectoryMonitor.java
Author: djencks
Date: Mon Jan 9 13:28:57 2006
New Revision: 367399
URL: http://svn.apache.org/viewcvs?rev=367399&view=rev
Log:
GERONIMO-1443 Further fixes whose need was pointed out by ammulder
Modified:
geronimo/trunk/modules/hot-deploy/src/java/org/apache/geronimo/deployment/hot/DirectoryHotDeployer.java
geronimo/trunk/modules/hot-deploy/src/java/org/apache/geronimo/deployment/hot/DirectoryMonitor.java
Modified: geronimo/trunk/modules/hot-deploy/src/java/org/apache/geronimo/deployment/hot/DirectoryHotDeployer.java
URL: http://svn.apache.org/viewcvs/geronimo/trunk/modules/hot-deploy/src/java/org/apache/geronimo/deployment/hot/DirectoryHotDeployer.java?rev=367399&r1=367398&r2=367399&view=diff
==============================================================================
--- geronimo/trunk/modules/hot-deploy/src/java/org/apache/geronimo/deployment/hot/DirectoryHotDeployer.java (original)
+++ geronimo/trunk/modules/hot-deploy/src/java/org/apache/geronimo/deployment/hot/DirectoryHotDeployer.java Mon Jan 9 13:28:57 2006
@@ -320,7 +320,12 @@
Target[] targets = mgr.getTargets();
TargetModuleID[] ids = mgr.getAvailableModules(null, targets);
ids = (TargetModuleID[]) DeployUtils.identifyTargetModuleIDs(ids, configId).toArray(new TargetModuleID[0]);
- ProgressObject po = mgr.redeploy(ids, file, null);
+ ProgressObject po;
+ if (DeployUtils.isJarFile(file) || file.isDirectory()) {
+ po = mgr.redeploy(ids, file, null);
+ } else {
+ po = mgr.redeploy(ids, null, file);
+ }
waitForProgress(po);
if (po.getDeploymentStatus().isCompleted()) {
TargetModuleID[] modules = po.getResultTargetModuleIDs();
Modified: geronimo/trunk/modules/hot-deploy/src/java/org/apache/geronimo/deployment/hot/DirectoryMonitor.java
URL: http://svn.apache.org/viewcvs/geronimo/trunk/modules/hot-deploy/src/java/org/apache/geronimo/deployment/hot/DirectoryMonitor.java?rev=367399&r1=367398&r2=367399&view=diff
==============================================================================
--- geronimo/trunk/modules/hot-deploy/src/java/org/apache/geronimo/deployment/hot/DirectoryMonitor.java (original)
+++ geronimo/trunk/modules/hot-deploy/src/java/org/apache/geronimo/deployment/hot/DirectoryMonitor.java Mon Jan 9 13:28:57 2006
@@ -21,6 +21,7 @@
import org.apache.geronimo.deployment.cli.DeployUtils;
import java.io.File;
import java.io.Serializable;
+import java.io.IOException;
import java.util.Map;
import java.util.HashMap;
import java.util.HashSet;
@@ -310,7 +311,11 @@
try {
moduleId = DeployUtils.extractModuleIdFromArchive(module);
} catch (Exception e) {
- log.warn("Unable to calculate module ID for module "+module.getAbsolutePath()+" ["+e.getMessage()+"]");
+ try {
+ moduleId = DeployUtils.extractModuleIdFromPlan(module);
+ } catch (IOException e2) {
+ log.warn("Unable to calculate module ID for file "+module.getAbsolutePath()+" ["+e2.getMessage()+"]");
+ }
}
if(moduleId == null) {
int pos = module.getName().lastIndexOf('.');