Author: rombert
Date: Wed Feb 18 11:34:00 2015
New Revision: 1660599
URL: http://svn.apache.org/r1660599
Log:
SLING-4409 - Invalid .content.xml files are silently ignored when
synchronising
Modified:
sling/trunk/tooling/ide/eclipse-core/src/org/apache/sling/ide/eclipse/core/internal/ResourceChangeCommandFactory.java
Modified:
sling/trunk/tooling/ide/eclipse-core/src/org/apache/sling/ide/eclipse/core/internal/ResourceChangeCommandFactory.java
URL:
http://svn.apache.org/viewvc/sling/trunk/tooling/ide/eclipse-core/src/org/apache/sling/ide/eclipse/core/internal/ResourceChangeCommandFactory.java?rev=1660599&r1=1660598&r2=1660599&view=diff
==============================================================================
---
sling/trunk/tooling/ide/eclipse-core/src/org/apache/sling/ide/eclipse/core/internal/ResourceChangeCommandFactory.java
(original)
+++
sling/trunk/tooling/ide/eclipse-core/src/org/apache/sling/ide/eclipse/core/internal/ResourceChangeCommandFactory.java
Wed Feb 18 11:34:00 2015
@@ -55,6 +55,7 @@ import org.eclipse.core.runtime.IPath;
import org.eclipse.core.runtime.IStatus;
import org.eclipse.core.runtime.Path;
import org.eclipse.core.runtime.Status;
+import org.eclipse.ui.statushandlers.StatusManager;
/**
* The <tt>ResourceChangeCommandFactory</tt> creates new {@link #Command
commands} correspoding to resource addition,
@@ -171,7 +172,9 @@ public class ResourceChangeCommandFactor
}
} catch (IOException e) {
- Activator.getDefault().getPluginLogger().warn(e.getMessage(),
e);
+ Status s = new Status(Status.WARNING, Activator.PLUGIN_ID,
"Failed reading file at "
+ + resource.getFullPath(), e);
+ StatusManager.getManager().handle(s, StatusManager.LOG |
StatusManager.SHOW);
return null;
} finally {
IOUtils.closeQuietly(contents);