<div dir="ltr">Thanks for all the feedback on the API.<div><br></div><div>Before going into detail I wanted to put the accent on the Weld 3.0.Alpha16 release post[1] which give a good explanation regarding this API. Its the best starting point to discover this new API IMO. Thanks Martin, Tomas and Matej for this release.</div><div><br><div>@John. The debate Configurator vs Builder is still open. At the moment we focused on configurator since they are easier to limit to a given container lifecycle, but having builders to reuse the configuration could make sense as well. AnnotatedType is a special case since it could make sense to use it at runtime (to ease creation of an InjectionTarget for instance, so perhaps it will require a Builder.</div><div>If we keep the API in this spirit for the release, it should be better to talk about Configurator API vs Builder API to avoid confusion for missing build() methods ;)</div><div><br></div><div>@Antonin the enhancement you propose is very interesting but as Martin said we could imagine a solution to load an existing bean after decision on the API (a mute(Bean) method in ABD perhaps).</div><div><br></div><div>For me the goal is to decide if we are on the right path and avoid decision that will prevent future enhancement. I think having this API perfect and complete in one PR is almost impossible. So we should validate something to move on missing features or enhancements.</div><div><br></div><div>Antoine</div><div><br></div><div>[1] <a href="http://weld.cdi-spec.org/news/2016/04/28/weld-300Alpha16/">http://weld.cdi-spec.org/news/2016/04/28/weld-300Alpha16/</a></div><div dir="ltr"><br><div class="gmail_quote"><div dir="ltr">Le jeu. 28 avr. 2016 à 10:43, Martin Kouba &lt;<a href="mailto:mkouba@redhat.com" target="_blank">mkouba@redhat.com</a>&gt; a écrit :<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi all,<br>
<br>
we&#39;ve just released Weld 3.0.0.Alpha16. So anyone can start playing with<br>
the API, discover possibilities and find potential issues:<br>
<br>
<a href="http://weld.cdi-spec.org/news/2016/04/28/weld-300Alpha16/" rel="noreferrer" target="_blank">http://weld.cdi-spec.org/news/2016/04/28/weld-300Alpha16/</a><br>
<br>
Any feedback is appreciated!<br>
<br>
Martin<br>
<br>
Dne 25.4.2016 v 09:30 Martin Kouba napsal(a):<br>
&gt; Hi all,<br>
&gt;<br>
&gt; me and Matej, we&#39;ve already tried to explain some points in cdi/pull/287<br>
&gt; discussion. Anyway, we&#39;re going to release Weld 3.0.0.Alpha16 (base on<br>
&gt; 2.0.Alpha4) later this week so that everyone can start playing with the<br>
&gt; new API. And we&#39;d like to prepare some simple examples to help people<br>
&gt; get started as well.<br>
&gt;<br>
&gt; Martin<br>
&gt;<br>
&gt;<br>
&gt; Dne 23.4.2016 v 12:56 John D. Ament napsal(a):<br>
&gt;&gt; Hey guys<br>
&gt;&gt;<br>
&gt;&gt; Based on the last f2f I was in, I took an action item to look at how<br>
&gt;&gt; applications can leverage the new builder methods/classes from this PR:<br>
&gt;&gt; <a href="https://github.com/cdi-spec/cdi/pull/287" rel="noreferrer" target="_blank">https://github.com/cdi-spec/cdi/pull/287</a><br>
&gt;&gt;<br>
&gt;&gt; To do this, I took some existing OSS CDI extensions and converted parts<br>
&gt;&gt; to use the new APIs instead of the old ones.<br>
&gt;&gt;<br>
&gt;&gt; The results were iffy to be honest.  Here&#39;s some of the key issues I<br>
&gt;&gt; noticed:<br>
&gt;&gt;<br>
&gt;&gt; - AfterBeanDiscovery#addBean - vs AfterBeanDiscovery.addBean(Bean&lt;?&gt; bean)<br>
&gt;&gt; In the latter, it&#39;s clearer to a developer which attributes are required<br>
&gt;&gt; vs optional.  Builders typically use sensible defaults.  Maybe that was<br>
&gt;&gt; the intention here, but I couldn&#39;t really get that sense when converting<br>
&gt;&gt; over.  It also wasn&#39;t clear what to do when done.  I suspect I just<br>
&gt;&gt; leave it, but without some kind of closing &quot;build()&quot; or &quot;done()&quot; method,<br>
&gt;&gt; it becomes ambiguous.<br>
&gt;&gt;<br>
&gt;&gt; - Annotated*Configurator<br>
&gt;&gt; TBH, I have no idea what I was configuring in this one at the first<br>
&gt;&gt; pass.  I started with a method.  I wanted to replace the method&#39;s<br>
&gt;&gt; annotations.  It seemed like I could set that up using the configurator,<br>
&gt;&gt; but I ended up having to do setAnnotated at the end anyways, so I&#39;m not<br>
&gt;&gt; sure what the configurator bought me.<br>
&gt;&gt;<br>
&gt;&gt; The one nice thing I saw was the simpler to use lambda functions.  Being<br>
&gt;&gt; able to stream through things like annotated method made the code much<br>
&gt;&gt; cleaner.<br>
&gt;&gt;<br>
&gt;&gt; For the open source code, I&#39;ll try to get some gists together that show<br>
&gt;&gt; the changes.  Maybe there&#39;s something I&#39;m missing, so wouldn&#39;t mind a<br>
&gt;&gt; second set of eyes on the changes to see.<br>
&gt;&gt;<br>
&gt;&gt; John<br>
&gt;&gt;<br>
&gt;&gt;<br>
&gt;&gt; _______________________________________________<br>
&gt;&gt; cdi-dev mailing list<br>
&gt;&gt; <a href="mailto:cdi-dev@lists.jboss.org" target="_blank">cdi-dev@lists.jboss.org</a><br>
&gt;&gt; <a href="https://lists.jboss.org/mailman/listinfo/cdi-dev" rel="noreferrer" target="_blank">https://lists.jboss.org/mailman/listinfo/cdi-dev</a><br>
&gt;&gt;<br>
&gt;&gt; Note that for all code provided on this list, the provider licenses the code under the Apache License, Version 2 (<a href="http://www.apache.org/licenses/LICENSE-2.0.html" rel="noreferrer" target="_blank">http://www.apache.org/licenses/LICENSE-2.0.html</a>). For all other ideas provided on this list, the provider waives all patent and other intellectual property rights inherent in such information.<br>
&gt;&gt;<br>
&gt;<br>
<br>
--<br>
Martin Kouba<br>
Software Engineer<br>
Red Hat, Czech Republic<br>
_______________________________________________<br>
cdi-dev mailing list<br>
<a href="mailto:cdi-dev@lists.jboss.org" target="_blank">cdi-dev@lists.jboss.org</a><br>
<a href="https://lists.jboss.org/mailman/listinfo/cdi-dev" rel="noreferrer" target="_blank">https://lists.jboss.org/mailman/listinfo/cdi-dev</a><br>
<br>
Note that for all code provided on this list, the provider licenses the code under the Apache License, Version 2 (<a href="http://www.apache.org/licenses/LICENSE-2.0.html" rel="noreferrer" target="_blank">http://www.apache.org/licenses/LICENSE-2.0.html</a>). For all other ideas provided on this list, the provider waives all patent and other intellectual property rights inherent in such information.<br>
</blockquote></div></div></div></div>