[jboss-cvs] JBossAS SVN: r57877 - projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/vfs/jar
jboss-cvs-commits at lists.jboss.org
jboss-cvs-commits at lists.jboss.org
Fri Oct 27 00:29:19 EDT 2006
Author: scott.stark at jboss.org
Date: 2006-10-27 00:29:17 -0400 (Fri, 27 Oct 2006)
New Revision: 57877
Modified:
projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/vfs/jar/JARStructure.java
Log:
If the addAllChildren attempt fails, the context needs to be removed from the structure metadata.
Modified: projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/vfs/jar/JARStructure.java
===================================================================
--- projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/vfs/jar/JARStructure.java 2006-10-27 04:27:13 UTC (rev 57876)
+++ projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/vfs/jar/JARStructure.java 2006-10-27 04:29:17 UTC (rev 57877)
@@ -50,16 +50,24 @@
}
/**
- * Gets the list of suffixes recognised as jars
+ * Gets the set of suffixes recognised as jars
*
- * @return the list of suffixes
+ * @return the set of suffixes
*/
public Set<String> getSuffixes()
{
return JarUtils.getSuffixes();
}
-
-
+ /**
+ * Gets the set of suffixes recognised as jars
+ *
+ * @param suffixes - the set of suffixes
+ */
+ public void setSuffixes(Set<String> suffixes)
+ {
+ JarUtils.setJarSuffixes(suffixes);
+ }
+
@Override
public int getRelativeOrder()
{
@@ -68,6 +76,7 @@
public boolean determineStructure(VirtualFile root, StructureMetaData metaData, StructuredDeployers deployers)
{
+ String contextPath = null;
try
{
if (root.isLeaf() == false)
@@ -113,6 +122,7 @@
// The classpath is the root
super.addClassPath(root, root, true, true, context);
metaData.addContext(context);
+ contextPath = context.getVfsPath();
// We tentatively try all the children as potential subdeployments
addAllChildren(root, metaData, deployers);
@@ -121,6 +131,9 @@
catch (Exception e)
{
log.warn("Error determining structure: " + root.getName(), e);
+ // Remove the invalid context
+ if( contextPath != null )
+ metaData.removeContext(contextPath);
return false;
}
}
More information about the jboss-cvs-commits
mailing list