<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Multiple parents for document and deletion trouble- addchild in Alfresco Archive</title>
    <link>https://connect.hyland.com/t5/alfresco-archive/multiple-parents-for-document-and-deletion-trouble-addchild/m-p/271156#M224286</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;We found the similar problem with Alfresco Share (r26807). (deleting and moving actions).&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;E.g.:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; var folderNodeRef = "workspace://SpacesStore/e7bfa076-ab8a-4211-b821-e367ee36d33e"; //existing space "test"&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; var fileNodeRef = "workspace://SpacesStore/7831203d-805e-42d9-9a36-e4d1abbed1f0";&amp;nbsp; //existing document "file1"&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; var folderNode = search.findNode(folderNodeRef);&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; var fileNode = search.findNode(fileNodeRef);&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; folderNode.addNode(fileNode);&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;—-&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Enter into space "test" and make action "delete". The document is really deleted and vanished from both primary and "test" spaces. But any trying to add a document with the same name "file1" into the primary space generates the following exception: "org.mozilla.javascript.WrappedException: Wrapped org.alfresco.service.cmr.repository.DuplicateChildNodeNameException: Duplicate child name not allowed: Файл1 (workspace://SpacesStore/Company Home/Data Dictionary/Web Scripts Extensions/………ourscript.post.json.hs#948"&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;We checked that the document is really deleted ( fileNode = search.findNode(fileNodeRef) returns null ), but folderNode.getChildren() for the primary space return Node-object with a name of the deleted document.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;PS: the reason for using multiple parents for document for us is absence of virtual spaces. We need to process dynamic hierarchical lists of documents (working with clusters of documents) allowing all actions that possible in AlfrescoShare Document Library. &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Moreover it is very strange that Alfresco Share contain different realizations for browsing documents in the library and viewing search results because it makes impossible to use actions for documents in search result that accessible for documents in the library.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 16 Jun 2011 08:42:27 GMT</pubDate>
    <dc:creator>rss</dc:creator>
    <dc:date>2011-06-16T08:42:27Z</dc:date>
    <item>
      <title>Multiple parents for document and deletion trouble- addchild</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/multiple-parents-for-document-and-deletion-trouble-addchild/m-p/271150#M224280</link>
      <description>Hello all.We need to be able to have a document inside two folders (one as work-flow basis, the other as filing/"storage").Looking around the forum (http://forums1.man.alfresco.com/en/viewtopic.php?f=6&amp;amp;t=16170) and doc we built an action that take the target folder (where the "duplicate" should</description>
      <pubDate>Thu, 10 Mar 2011 15:58:21 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/multiple-parents-for-document-and-deletion-trouble-addchild/m-p/271150#M224280</guid>
      <dc:creator>annakan</dc:creator>
      <dc:date>2011-03-10T15:58:21Z</dc:date>
    </item>
    <item>
      <title>Re: Multiple parents for document and deletion trouble- addchild</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/multiple-parents-for-document-and-deletion-trouble-addchild/m-p/271151#M224281</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Nobody has a clue ? &lt;img id="smileyhappy" class="emoticon emoticon-smileyhappy" src="https://connect.hyland.com/i/smilies/16x16_smiley-happy.png" alt="Smiley Happy" title="Smiley Happy" /&gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;We are evaluating Alfresco on a small scale project and this is vital to avoid the messy workflows that would prove to be too constraining anyway.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Plus it is a great functionality for people workflows or not, it allows the same document to be filled under two logics, corresponding to different usages ('sorting plan' on one side, working reviews on the other side) that often conflict in a document lifecycle.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Last it allows very graphical / CIFS like process that are easier for occasional users who can even be un aware there is a DM in place.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;We have a short time frame to complete this proof of concept, and it would be a big plus for Alfresco to be able to do something useful in this time frame, and it is quite frustrating to have the whole action stuff nearly working, but not&amp;nbsp; quite …&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Far away, so close &lt;img id="smileyhappy" class="emoticon emoticon-smileyhappy" src="https://connect.hyland.com/i/smilies/16x16_smiley-happy.png" alt="Smiley Happy" title="Smiley Happy" /&gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;So any pointers appreciated &lt;img id="smileyvery-happy" class="emoticon emoticon-smileyvery-happy" src="https://connect.hyland.com/i/smilies/16x16_smiley-very-happy.png" alt="Smiley Very Happy" title="Smiley Very Happy" /&gt;&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 21 Mar 2011 15:02:21 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/multiple-parents-for-document-and-deletion-trouble-addchild/m-p/271151#M224281</guid>
      <dc:creator>annakan</dc:creator>
      <dc:date>2011-03-21T15:02:21Z</dc:date>
    </item>
    <item>
      <title>Re: Multiple parents for document and deletion trouble- addchild</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/multiple-parents-for-document-and-deletion-trouble-addchild/m-p/271152#M224282</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I am not sure what you really meant by "doing the right behaviour" and what you want to achieve. Maybe you could just be more clear about this? Do you want the archive:// Noderef to be removed or do you want to remove a document which you linked in two spaces individually or … &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;There can be only exactly one primary association to a parent node.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;This primary assoc controls the "contains" behaviour - that is, the life cycle of a node is controlled by its primary parent node. In other words, deleting a node will delete all its "primary" children as well. In contrast, all children of the deleted node, which have secondary assocs to it will not be deleted. &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;The mysterious archive://… node reference you see belongs to a node of the trashbin - it was deleted and the secondary assoc was changed to point now to the document located in the trashbin. If you empty the trashbin this will be removed too. So its not some kind of proxy or leftovers, its just a node reference.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;HTH&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp; lothar&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 21 Mar 2011 21:06:19 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/multiple-parents-for-document-and-deletion-trouble-addchild/m-p/271152#M224282</guid>
      <dc:creator>lotharmärkle</dc:creator>
      <dc:date>2011-03-21T21:06:19Z</dc:date>
    </item>
    <item>
      <title>Re: Multiple parents for document and deletion trouble- addchild</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/multiple-parents-for-document-and-deletion-trouble-addchild/m-p/271153#M224283</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Thanks for your anwer I missed it because somehow I must have forgotten to activate notifications.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks for your explanation, I less cleanly arrived to the same conclusion but was disappointed by some design decision :&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;- you must have one primary parent-child assoc, meaning you can't have "delete on last un-parenting" behavior. &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;- Or delete on "any" un-parenting behavior&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;- although afresco model supports multiple parents and this is GOOD and GREAT and much better in my book than the "proxy/stub" model, Alfresco forget that right away, implementing copy and move without passing the "source parent" information. The consequence is that the source is always fetched from the node itself, assuming it is its primary parent. That is wrong of course.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;The consequence is that, when you assign multiple parents to a node/document, you can't act on any of the "non primary childs", all acts upon any of those is carried upon the arbitrarily elected "primary child" (the first parent at creation time in fact).&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;The moveTo and copy to signature are like this fn(node, destination), instead of fn(node, source, destination).&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I was able to make work the multiple parenthood but I need to rewrite the copy and move action to be able to progress, something even more ambitious &lt;img id="smileywink" class="emoticon emoticon-smileywink" src="https://connect.hyland.com/i/smilies/16x16_smiley-wink.png" alt="Smiley Wink" title="Smiley Wink" /&gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;On a side note they had to "do it right" &lt;img id="smileyhappy" class="emoticon emoticon-smileyhappy" src="https://connect.hyland.com/i/smilies/16x16_smiley-happy.png" alt="Smiley Happy" title="Smiley Happy" /&gt; for the CMIS implementation where a source and a destination are expected.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 01 Apr 2011 13:03:48 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/multiple-parents-for-document-and-deletion-trouble-addchild/m-p/271153#M224283</guid>
      <dc:creator>annakan</dc:creator>
      <dc:date>2011-04-01T13:03:48Z</dc:date>
    </item>
    <item>
      <title>Re: Multiple parents for document and deletion trouble- addchild</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/multiple-parents-for-document-and-deletion-trouble-addchild/m-p/271154#M224284</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I think you may find that the copy scenario has been fixed …&amp;nbsp;&amp;nbsp; It looks like a familiar issue.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I like your idea of delete on last reference, but you are right that its not there at the moment.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 01 Apr 2011 13:17:34 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/multiple-parents-for-document-and-deletion-trouble-addchild/m-p/271154#M224284</guid>
      <dc:creator>mrogers</dc:creator>
      <dc:date>2011-04-01T13:17:34Z</dc:date>
    </item>
    <item>
      <title>Re: Multiple parents for document and deletion trouble- addchild</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/multiple-parents-for-document-and-deletion-trouble-addchild/m-p/271155#M224285</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Great news &lt;img id="smileyhappy" class="emoticon emoticon-smileyhappy" src="https://connect.hyland.com/i/smilies/16x16_smiley-happy.png" alt="Smiley Happy" title="Smiley Happy" /&gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Fixed in the SVN ?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;and the move action ? &lt;img id="smileyhappy" class="emoticon emoticon-smileyhappy" src="https://connect.hyland.com/i/smilies/16x16_smiley-happy.png" alt="Smiley Happy" title="Smiley Happy" /&gt; (greedy me) &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;To know if I still have to make my own (makeshift) custom move action.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;As for the deletion policy, I happen to think that the "delete on last reference" is the most "sound" and generic but I would even be nice if we could choose the policy on a document type by document type basis.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;More generally It would be nice if the move behaviour was preceded by onBeforeMove allowing us to mingle with the source and destination folder, thus implementing any policy.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;As I said, greedy &lt;img id="smileywink" class="emoticon emoticon-smileywink" src="https://connect.hyland.com/i/smilies/16x16_smiley-wink.png" alt="Smiley Wink" title="Smiley Wink" /&gt;&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 01 Apr 2011 14:21:11 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/multiple-parents-for-document-and-deletion-trouble-addchild/m-p/271155#M224285</guid>
      <dc:creator>annakan</dc:creator>
      <dc:date>2011-04-01T14:21:11Z</dc:date>
    </item>
    <item>
      <title>Re: Multiple parents for document and deletion trouble- addchild</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/multiple-parents-for-document-and-deletion-trouble-addchild/m-p/271156#M224286</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;We found the similar problem with Alfresco Share (r26807). (deleting and moving actions).&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;E.g.:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; var folderNodeRef = "workspace://SpacesStore/e7bfa076-ab8a-4211-b821-e367ee36d33e"; //existing space "test"&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; var fileNodeRef = "workspace://SpacesStore/7831203d-805e-42d9-9a36-e4d1abbed1f0";&amp;nbsp; //existing document "file1"&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; var folderNode = search.findNode(folderNodeRef);&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; var fileNode = search.findNode(fileNodeRef);&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; folderNode.addNode(fileNode);&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;—-&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Enter into space "test" and make action "delete". The document is really deleted and vanished from both primary and "test" spaces. But any trying to add a document with the same name "file1" into the primary space generates the following exception: "org.mozilla.javascript.WrappedException: Wrapped org.alfresco.service.cmr.repository.DuplicateChildNodeNameException: Duplicate child name not allowed: Файл1 (workspace://SpacesStore/Company Home/Data Dictionary/Web Scripts Extensions/………ourscript.post.json.hs#948"&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;We checked that the document is really deleted ( fileNode = search.findNode(fileNodeRef) returns null ), but folderNode.getChildren() for the primary space return Node-object with a name of the deleted document.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;PS: the reason for using multiple parents for document for us is absence of virtual spaces. We need to process dynamic hierarchical lists of documents (working with clusters of documents) allowing all actions that possible in AlfrescoShare Document Library. &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Moreover it is very strange that Alfresco Share contain different realizations for browsing documents in the library and viewing search results because it makes impossible to use actions for documents in search result that accessible for documents in the library.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 16 Jun 2011 08:42:27 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/multiple-parents-for-document-and-deletion-trouble-addchild/m-p/271156#M224286</guid>
      <dc:creator>rss</dc:creator>
      <dc:date>2011-06-16T08:42:27Z</dc:date>
    </item>
    <item>
      <title>Re: Multiple parents for document and deletion trouble- addchild</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/multiple-parents-for-document-and-deletion-trouble-addchild/m-p/271157#M224287</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;moving a secondary is fixed now but I created a ticket in JIRA since deleting a secondary will still delete the primary node (tested in 4.2.c) ALF-18792.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;The suggestion from Annakan would fix the issue &lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 29 Apr 2013 12:54:32 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/multiple-parents-for-document-and-deletion-trouble-addchild/m-p/271157#M224287</guid>
      <dc:creator>heiko_robert</dc:creator>
      <dc:date>2013-04-29T12:54:32Z</dc:date>
    </item>
  </channel>
</rss>

