### Eclipse Workspace Patch 1.0
#P org.jboss.ide.eclipse.as.core
Index: jbosscore/org/jboss/ide/eclipse/as/core/server/internal/v7/DelegatingJBoss7ServerBehavior.java
===================================================================
--- jbosscore/org/jboss/ide/eclipse/as/core/server/internal/v7/DelegatingJBoss7ServerBehavior.java	(revision 37255)
+++ jbosscore/org/jboss/ide/eclipse/as/core/server/internal/v7/DelegatingJBoss7ServerBehavior.java	(working copy)
@@ -101,7 +101,7 @@
 		}
 		List<IPath> paths = getMarkedDoDeploy();
 		monitor.beginTask("Completing Publishes", paths.size() + 1); //$NON-NLS-1$
-		createDoDeployMarker(paths, monitor);
+		createDoDeployMarker(getOrCreatePublishMethod(), paths, monitor);
 	}
 	
 	@Override
@@ -110,9 +110,9 @@
 		if( ds == null ) 
 			return;
 
-		IJBossServerPublishMethod method = getOrCreatePublishMethod();
+		IJBossServerPublishMethod method = createPublishMethod();
 		IPath depPath = PublishUtil.getDeployPath(method, module, ds);
-		createDoDeployMarker(new IPath[]{depPath}, monitor);
+		createDoDeployMarker(method, new IPath[]{depPath}, monitor);
 	}
 
 	@Override
@@ -180,12 +180,14 @@
 		}
 		return (List<IPath>) o;
 	}
-	private void createDoDeployMarker(IPath[] paths, IProgressMonitor monitor) throws CoreException {
+	private void createDoDeployMarker(IJBossServerPublishMethod method, IPath[] paths, IProgressMonitor monitor) throws CoreException {
 		List<IPath> allPaths = Arrays.asList(paths);
-		createDoDeployMarker(allPaths, monitor);
+		createDoDeployMarker(method, allPaths, monitor);
 	}
-	private void createDoDeployMarker(List<IPath> paths, IProgressMonitor monitor) throws CoreException {
-		DeploymentMarkerUtils.addDoDeployMarker(getOrCreatePublishMethod(), getServer(), paths, monitor);
+	private void createDoDeployMarker(IJBossServerPublishMethod method, List<IPath> paths, IProgressMonitor monitor) throws CoreException {
+		if( method == null )
+			method = createPublishMethod();
+		DeploymentMarkerUtils.addDoDeployMarker(method, getServer(), paths, monitor);
 	}
 	
 	@Override
Index: jbosscore/org/jboss/ide/eclipse/as/core/server/internal/DeployableServerBehavior.java
===================================================================
--- jbosscore/org/jboss/ide/eclipse/as/core/server/internal/DeployableServerBehavior.java	(revision 37255)
+++ jbosscore/org/jboss/ide/eclipse/as/core/server/internal/DeployableServerBehavior.java	(working copy)
@@ -60,6 +60,17 @@
 		method.publishStart(this, monitor);
 	}
 
+	/**
+	 * Get the current publish method if one exists, or, create one and return it. 
+	 * Any created publish method will be cached and stored. 
+	 * 
+	 * This method should NOT be called except as part of the publishing process. 
+	 * Clients that need a disposable single-use publish method should call
+	 * createPublishMethod() instead. 
+	 * 
+	 * @return
+	 * @throws CoreException
+	 */
 	protected IJBossServerPublishMethod getOrCreatePublishMethod() throws CoreException {
 		if( method == null )
 			method = createPublishMethod();
@@ -103,11 +114,16 @@
 	}
 	
 	/**
-	 * This should only be called once per overall publish. 
-	 * publishStart() should call this, cache the method, and use it 
-	 * until after publishFinish() is called. 
+	 * This method creates a disposable publishMethod for use in publishing modules and projects, 
+	 * touching files, copying files, or any other task relevent to publish methods. 
 	 * 
-	 * @return
+	 * This method will also be called once during a "publish cycle" 
+	 * between publishStart and publishFinish, with the 
+	 * IJBossServerPublishMethod cached for the duration. 
+	 * 
+	 * Other clients can use this API to have a disposable publish method to use.
+	 * 
+	 * @return The publish method
 	 */
 	public IJBossServerPublishMethod createPublishMethod() {
 		IJBossServerPublishMethodType type = DeploymentPreferenceLoader.getCurrentDeploymentMethodType(getServer());
Index: jbosscore/org/jboss/ide/eclipse/as/core/server/internal/JBossServerBehavior.java
===================================================================
--- jbosscore/org/jboss/ide/eclipse/as/core/server/internal/JBossServerBehavior.java	(revision 37263)
+++ jbosscore/org/jboss/ide/eclipse/as/core/server/internal/JBossServerBehavior.java	(working copy)
@@ -169,11 +169,11 @@
 		if( ds == null ) 
 			return;
 
-		IJBossServerPublishMethod method = getOrCreatePublishMethod();
+		IJBossServerPublishMethod method = createPublishMethod();
 		IPath depPath = PublishUtil.getDeployPath(method, module, ds);
 		if( ServerModelUtilities.isBinaryModule(module[module.length-1]) || ds.zipsWTPDeployments()) {
 			// touch the file
-			getOrCreatePublishMethod().getCallbackHandler(depPath.removeLastSegments(1), getServer()).touchResource(new Path(depPath.lastSegment()));
+			method.getCallbackHandler(depPath.removeLastSegments(1), getServer()).touchResource(new Path(depPath.lastSegment()));
 		} else {
 			// touch the descriptor
 			IPublishCopyCallbackHandler callback = method.getCallbackHandler(AbstractServerToolsPublisher.getRootPath(depPath).append(depPath), getServer());
Index: jbosscore/org/jboss/ide/eclipse/as/core/server/internal/DelegatingServerBehavior.java
===================================================================
--- jbosscore/org/jboss/ide/eclipse/as/core/server/internal/DelegatingServerBehavior.java	(revision 37255)
+++ jbosscore/org/jboss/ide/eclipse/as/core/server/internal/DelegatingServerBehavior.java	(working copy)
@@ -169,11 +169,11 @@
 		if( ds == null ) 
 			return;
 
-		IJBossServerPublishMethod method = getOrCreatePublishMethod();
+		IJBossServerPublishMethod method = createPublishMethod();
 		IPath depPath = PublishUtil.getDeployPath(method, module, ds);
 		if( ServerModelUtilities.isBinaryModule(module[module.length-1]) || ds.zipsWTPDeployments()) {
 			// touch the file
-			getOrCreatePublishMethod().getCallbackHandler(depPath.removeLastSegments(1), getServer()).touchResource(new Path(depPath.lastSegment()));
+			method.getCallbackHandler(depPath.removeLastSegments(1), getServer()).touchResource(new Path(depPath.lastSegment()));
 		} else {
 			// touch the descriptor
 			IPublishCopyCallbackHandler callback = method.getCallbackHandler(AbstractServerToolsPublisher.getRootPath(depPath).append(depPath), getServer());
