<div dir="ltr">Hey guys<div><br></div><div>Seems like we have some issues in JIRA all focused on managing the lifecycle of Dependent scoped beans.  It also seems like we have many differing opinions about how to manage them.</div><div><br></div><div>- Martin raised a PR to add a release() method to Instance to help destroy a dependent bean <a href="https://github.com/cdi-spec/cdi/pull/286">https://github.com/cdi-spec/cdi/pull/286</a></div><div>- I raised a PR <a href="https://github.com/cdi-spec/cdi/pull/289">https://github.com/cdi-spec/cdi/pull/289</a> to update the spec to clarify how to manage a dependent scoped bean.</div><div><br></div><div>Right now, it seems that the big disagreement is whether Instance.destroy() can destroy objects not created by it (the case being around the CDI utility class, being an impl of Instance).  I&#39;m currently heavily against Martin&#39;s proposed changes, but want to get input from others on the group to understand their perspective.</div><div><br></div><div>- Does the spec require destroy() to be called only on instances that it created?  When I read 5.6.1 the only requirement I see is that it has to be a dependent scoped bean.  Note when I ask this I&#39;m asking from the spec perspective, its a different problem if there&#39;s some issues with implementations following suite (I would imagine there needs to be some shared global registry of dependent scoped beans for this to work).</div><div><br></div><div>- Do we want two methods that effectively do the same thing?  I don&#39;t see a strong difference between the two.</div><div><br></div><div>On the flipside, my change is more a spec clarification.  I&#39;m thinking more now that it belongs as a reword of 5.6.1 to clarify how to use destroy() on dependent beans, rather than where I put it.  I think realistically we have all of the tools needed to manage the lifecycle of these classes, just need to clarify them for people to use.</div><div><br></div><div>John</div></div>