<!DOCTYPE html>
<html>
<head>
<title></title>
</head>
<body><div id="sig22609205"><div class="signature">On Thu, Jul 23, 2015, at 02:57 PM, miguelet tortosa wrote:<br></div>
</div>
<blockquote type="cite"><div dir="ltr"><div>The first attempt that the preset is executed, the first object is the only object created.<br></div>
<div>If I reexecute the preset, both objects are created.<br></div>
<div> </div>
<div>Notice that the second object is son of the first object.<br></div>
</div>
</blockquote><div> </div>
<div>The child object cannot be added until the parent object is added first. What's happening here is that the ACS is not checking presets a second time. Preset verification is an expensive process so agressive caching is employed to minimize how often the ACS need to verify presets. In this particular case this caching mechanism is preventing presets from being checked a second time.<br></div>
<div> </div>
<div>See the attached patch for a fix. However, this fix comes with a couple of down sides: a) it adds a considerable performance hit; and b) it can potentially cause infinite loop in rare cases.<br></div>
<div> </div>
<div>Will push this fix upstream if I can find a way to prevent infinite loops or at least let it fail gracefully.<br></div>
<div> </div>
<blockquote type="cite"><div dir="ltr"><div><div>I have noticed that it is also imposible to create 2 objects (brothers) at the same time via preset on the first attempt but it is posible to create both on the second execution.<br></div>
</div>
</div>
</blockquote><div> </div>
<div>Not sure about this one. Can you share they keys of the two objects you tried to add?<br></div>
<div> </div>
<div>Zaid<br></div>
</body>
</html>