diff --git a/datastore_server/source/java/ch/ethz/sis/openbis/generic/server/dss/plugins/sync/common/EntityRetriever.java b/datastore_server/source/java/ch/ethz/sis/openbis/generic/server/dss/plugins/sync/common/EntityRetriever.java
index ee41b4daa3e7a05f2509c8000c8c056101e4330b..e840fe5b07aebcf358c10f50d9461de401c53e12 100644
--- a/datastore_server/source/java/ch/ethz/sis/openbis/generic/server/dss/plugins/sync/common/EntityRetriever.java
+++ b/datastore_server/source/java/ch/ethz/sis/openbis/generic/server/dss/plugins/sync/common/EntityRetriever.java
@@ -28,8 +28,6 @@ import javax.xml.parsers.ParserConfigurationException;
 import javax.xml.transform.TransformerException;
 
 import ch.ethz.sis.openbis.generic.asapi.v3.IApplicationServerApi;
-import ch.ethz.sis.openbis.generic.asapi.v3.dto.attachment.Attachment;
-import ch.ethz.sis.openbis.generic.asapi.v3.dto.common.interfaces.IAttachmentsHolder;
 import ch.ethz.sis.openbis.generic.asapi.v3.dto.common.interfaces.ICodeHolder;
 import ch.ethz.sis.openbis.generic.asapi.v3.dto.common.search.SearchResult;
 import ch.ethz.sis.openbis.generic.asapi.v3.dto.dataset.DataSet;
@@ -128,7 +126,6 @@ public class EntityRetriever
             Node<Project> prjNode = new Node<Project>(project);
             graph.addNode(prjNode);
             findExperiments(prjNode);
-            findAndAddAttachments(prjNode);
         }
 
         findSpaceSamples(spaceId);
@@ -154,21 +151,10 @@ public class EntityRetriever
             Node<Experiment> expNode = new Node<Experiment>(exp);
             graph.addEdge(prjNode, expNode, new Edge(CONNECTION));
             findSamplesForExperiment(expNode);
-            findAndAddAttachments(expNode);
             findAndAttachDataSetsForExperiment(expNode);
         }
     }
 
-    private void findAndAddAttachments(Node<? extends IAttachmentsHolder> node)
-    {
-        List<Attachment> attachments = node.getEntity().getAttachments();
-        for (Attachment attachment : attachments)
-        {
-            node.addBinaryData(attachment.getPermlink());
-            // System.out.println("Attachment:" + attachment.getPermlink());
-        }
-    }
-
     private void findSpaceSamples(String spaceCode)
     {
         SampleSearchCriteria criteria = new SampleSearchCriteria();
@@ -190,7 +176,6 @@ public class EntityRetriever
             graph.addNode(sampleNode);
             findChildAndComponentSamples(sampleNode);
             findAndAttachDataSets(sampleNode);
-            findAndAddAttachments(sampleNode);
         }
     }
 
@@ -214,7 +199,6 @@ public class EntityRetriever
             graph.addEdge(expNode, sampleNode, new Edge(CONNECTION));
 
             findAndAttachDataSets(sampleNode);
-            findAndAddAttachments(sampleNode);
             findChildAndComponentSamples(sampleNode);
         }
     }
@@ -295,7 +279,6 @@ public class EntityRetriever
             graph.addEdge(sampleNode, subSampleNode, new Edge(COMPONENT));
 
             findAndAttachDataSets(subSampleNode);
-            findAndAddAttachments(subSampleNode);
             findChildAndComponentSamples(subSampleNode);
         }
     }
@@ -311,7 +294,6 @@ public class EntityRetriever
             graph.addEdge(sampleNode, subSampleNode, new Edge(CHILD));
    
             findAndAttachDataSets(subSampleNode);
-            findAndAddAttachments(subSampleNode);
             findChildAndComponentSamples(subSampleNode);
         }
     }
diff --git a/openbis/source/java/ch/ethz/sis/openbis/generic/shared/entitygraph/Node.java b/openbis/source/java/ch/ethz/sis/openbis/generic/shared/entitygraph/Node.java
index fd235896d0335a35f8d3d99903da3ccbc242837f..25bc4a5898153a515f2bb39cf2ccc42acd97bb2d 100644
--- a/openbis/source/java/ch/ethz/sis/openbis/generic/shared/entitygraph/Node.java
+++ b/openbis/source/java/ch/ethz/sis/openbis/generic/shared/entitygraph/Node.java
@@ -20,6 +20,8 @@ import java.util.Date;
 import java.util.List;
 import java.util.Map;
 
+import ch.ethz.sis.openbis.generic.asapi.v3.dto.attachment.Attachment;
+import ch.ethz.sis.openbis.generic.asapi.v3.dto.common.interfaces.IAttachmentsHolder;
 import ch.ethz.sis.openbis.generic.asapi.v3.dto.common.interfaces.ICodeHolder;
 import ch.ethz.sis.openbis.generic.asapi.v3.dto.common.interfaces.IExperimentHolder;
 import ch.ethz.sis.openbis.generic.asapi.v3.dto.common.interfaces.IModificationDateHolder;
@@ -42,7 +44,7 @@ public class Node<T extends ICodeHolder & IModificationDateHolder & IModifierHol
 
     private final List<EdgeNodePair> connections;
 
-    private final List<String> binaryData;
+    private final List<Attachment> attachments;
 
     public T getEntity()
     {
@@ -53,7 +55,7 @@ public class Node<T extends ICodeHolder & IModificationDateHolder & IModifierHol
     {
         this.entity = entity;
         this.connections = new ArrayList<EdgeNodePair>();
-        this.binaryData = new ArrayList<String>();
+        this.attachments = new ArrayList<Attachment>();
     }
 
     @Override
@@ -253,21 +255,19 @@ public class Node<T extends ICodeHolder & IModificationDateHolder & IModifierHol
         return connections;
     }
 
-    public void addBinaryData(String link)
+    public void setAttachments(List<Attachment> attachmentList)
     {
-        binaryData.add(link);
+        attachments.clear();
+        attachments.addAll(attachmentList);
     }
 
-    public List<String> getBinaryData()
+    public List<Attachment> getAttachmentsOrNull()
     {
-        return binaryData;
-    }
-
-    public boolean hasBinaryData() {
-        if (entity instanceof DataSet)
+        if (entity instanceof IAttachmentsHolder)
         {
-            return true;
+            IAttachmentsHolder holder = (IAttachmentsHolder) entity;
+            return holder.getAttachments();
         }
-        return binaryData.size() > 0;
+        return null;
     }
 }