geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From johnx...@apache.org
Subject svn commit: r1324667 - in /geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v30.core/src/main/java/org/apache/geronimo/st/v30/core: DefaultModuleHandler.java ModuleArtifactMapper.java
Date Wed, 11 Apr 2012 09:32:36 GMT
Author: johnxiao
Date: Wed Apr 11 09:32:35 2012
New Revision: 1324667

URL: http://svn.apache.org/viewvc?rev=1324667&view=rev
Log:
add the module into cache after redeploy and eliminate the NullPointerException

Modified:
    geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v30.core/src/main/java/org/apache/geronimo/st/v30/core/DefaultModuleHandler.java
    geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v30.core/src/main/java/org/apache/geronimo/st/v30/core/ModuleArtifactMapper.java

Modified: geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v30.core/src/main/java/org/apache/geronimo/st/v30/core/DefaultModuleHandler.java
URL: http://svn.apache.org/viewvc/geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v30.core/src/main/java/org/apache/geronimo/st/v30/core/DefaultModuleHandler.java?rev=1324667&r1=1324666&r2=1324667&view=diff
==============================================================================
--- geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v30.core/src/main/java/org/apache/geronimo/st/v30/core/DefaultModuleHandler.java
(original)
+++ geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v30.core/src/main/java/org/apache/geronimo/st/v30/core/DefaultModuleHandler.java
Wed Apr 11 09:32:35 2012
@@ -107,6 +107,7 @@ public class DefaultModuleHandler extend
                     doFail(status, Messages.REDEPLOY_FAIL);
                 } else {
                     setModuleState(new IModule [] { module }, IServer.STATE_STARTED);
+                    mapper.addArtifactEntry(getServer(), module, moduleConfigId);
                 }
             } else {
                 //different configIds from what needs to be undeployed to what will be deployed

Modified: geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v30.core/src/main/java/org/apache/geronimo/st/v30/core/ModuleArtifactMapper.java
URL: http://svn.apache.org/viewvc/geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v30.core/src/main/java/org/apache/geronimo/st/v30/core/ModuleArtifactMapper.java?rev=1324667&r1=1324666&r2=1324667&view=diff
==============================================================================
--- geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v30.core/src/main/java/org/apache/geronimo/st/v30/core/ModuleArtifactMapper.java
(original)
+++ geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v30.core/src/main/java/org/apache/geronimo/st/v30/core/ModuleArtifactMapper.java
Wed Apr 11 09:32:35 2012
@@ -148,7 +148,8 @@ public class ModuleArtifactMapper {
             ModuleSet<Artifact> artifacts = getServerArtifacts(server);
             if (artifacts != null) {
                 try {
-                    return artifacts.query("projectName", getId(module)).getConfigId();
+                    Artifact artifact = artifacts.query("projectName", getId(module));
+                    if(artifact != null) return artifact.getConfigId();
                 } catch (Exception e) {
                     Trace.trace(Trace.ERROR, e.getMessage(), e, Activator.logCore);
                 }



Mime
View raw message