<div dir="ltr">Cool, I would be more than happy to contribute to that.<div><br></div><div>PS : @lincoln BTW, I&#39;ve updated the JIRA related to the CLI syntax with what you&#39;ve just said : <a href="https://issues.jboss.org/browse/FORGE-944?focusedCommentId=12825594&amp;page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-12825594">https://issues.jboss.org/browse/FORGE-944?focusedCommentId=12825594&amp;page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-12825594</a></div>
</div><div class="gmail_extra"><br><br><div class="gmail_quote">2013/10/29 Lincoln Baxter, III <span dir="ltr">&lt;<a href="mailto:lincolnbaxter@gmail.com" target="_blank">lincolnbaxter@gmail.com</a>&gt;</span><br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div dir="ltr">Hey Antonio!<div><br></div><div>I&#39;m definitely very interested in seeing more styles of programming supported! I think this would be a great project. I am all for it.</div><div><br></div><div>The interesting part will be trying to determine appropriate patterns for each style. REST APIs vary greatly, but if we can find some kind of best practice, which based on your blog, it looks like you already have an idea of, then I think that makes our job much simpler (and it is a complex job :)</div>

<div><br></div><div>So far, our command style is following this basic premise:</div><div><br></div><div><pre style="margin-top:0px;margin-bottom:0px;padding:0px;max-height:30em;overflow:auto;white-space:pre-wrap;word-wrap:normal;color:rgb(51,51,51);font-size:11.818181991577148px;line-height:14.545454025268555px;background-color:rgb(245,245,245)">
jpa-<span style="color:rgb(0,0,145)">new</span>-entity (instead of entity --named)
jpa-<span style="color:rgb(0,0,145)">new</span>-embedable
jpa-<span style="color:rgb(0,0,145)">new</span>-mapped-superclass --named Person
jpa-<span style="color:rgb(0,0,145)">new</span>-entity --named Vet --<span style="color:rgb(0,0,145)">extends</span> Person</pre></div><div class="gmail_extra"><br></div><div class="gmail_extra">{spec alias or acronym}-new-{something}</div>

<div class="gmail_extra">{spec alias or acronym}-{something}-from-{something else}</div><div class="gmail_extra"><br></div><div class="gmail_extra">We have a dilemma with faces and CDI, though. Should we call them &#39;faces&#39; and &#39;rest&#39; or &quot;jsf&quot; and &quot;jaxrs&quot;, since we already have &quot;jpa&quot; &quot;ejb&quot; etc. I think JAX-RS is the real issue, because most people know it as REST.</div>

<div class="gmail_extra"><br></div><div class="gmail_extra">But back on topic, yes, I&#39;m all for this!</div><div class="gmail_extra">~Lincoln<div><div class="h5"><br><br><div class="gmail_quote">On Tue, Oct 29, 2013 at 9:49 AM, Antonio Goncalves <span dir="ltr">&lt;<a href="mailto:antonio.mailing@gmail.com" target="_blank">antonio.mailing@gmail.com</a>&gt;</span> wrote:<br>

<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div dir="ltr">Hi <span>Vineet</span>,<div><br></div><div>

I&#39;ve published the blog : <a href="http://antoniogoncalves.org/2013/10/29/several-architectural-styles-with-java-ee-7/" target="_blank">http://<span>antoniogoncalves</span>.org/2013/10/29/several-architectural-styles-with-java-<span>ee</span>-7/</a></div>



<div><br></div><div>I&#39;ve implemented the three different architectural styles and you can have a look at : <a href="https://github.com/agoncal/agoncal-sample-javaee/tree/master/03-TierArchitecture" target="_blank">https://<span>github</span>.com/<span>agoncal</span>/<span>agoncal</span>-sample-<span>javaee</span>/tree/master/03-<span>TierArchitecture</span></a></div>



<div><br></div><div><span>Unfortunately</span> I still have an issue with the <span>RESTendpoint</span> doing a paginate (I&#39;ve asked some help in the jersey mailing list, but still no news, you can have a look at : <a href="https://java.net/projects/jersey/lists/users/archive/2013-10/message/64" target="_blank">https://java.net/projects/jersey/lists/users/archive/2013-10/message/64</a></div>


<div><br></div><div>If you look at the code for the three styles, there are not many changes. I would hope that Forge could help developers to generate different architectural styles. As I said, we could do something like this (depending on the future syntax : <a href="https://issues" target="_blank">https://issues</a>.<span>jboss</span>.org/browse/FORGE-944)</div>


<div><br></div><div><div><b>
Horizontal :</b></div><div><ul><li><span>jpa</span>-scaffold-from-database<br></li><li><span>jsf</span>-scaffold-from-entity<br></li><li>rest-scaffold-from-entity<br></li></ul></div><div><br>
</div><div><b><span>EJB</span> Centric :</b></div><div><ul><li><span>jpa</span>-scaffold-from-database<br></li><li><span>ejb</span>-scaffold-from-entity <br></li><li><span>jsf</span>-scaffold-from-<span>ejb</span><br>
</li><li>rest-scaffold-from-<span>ejb</span><br></li></ul></div>
<div><br></div><div><b>REST centric :</b></div><div><ul><li><span>jpa</span>-scaffold-from-database<br></li><li>rest-scaffold-from-entity<br></li><li><span>jsf</span>-scaffold-from-rest<br></li>
</ul></div></div><div>If that interests you, I would be more than happy to contribute to something like that.</div><span><font color="#888888"><div><br></div><div>Antonio</div></font></span><div><div>
<div><br></div><div><br></div><div class="gmail_extra"><br><br><div class="gmail_quote">
2013/10/21 <span>Vineet</span> Reynolds <span>Pereira</span> <span dir="ltr">&lt;<a href="mailto:vpereira@redhat.com" target="_blank"><span>vpereira</span>@<span>redhat</span>.com</a>&gt;</span><br>

<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div><div><br>
<br>
----- Original Message -----<br>
&gt; From: &quot;Antonio Goncalves&quot; &lt;<a href="mailto:antonio.mailing@gmail.com" target="_blank">antonio.mailing@gmail.com</a>&gt;<br>
&gt; To: &quot;forge-dev List&quot; &lt;<a href="mailto:forge-dev@lists.jboss.org" target="_blank">forge-dev@lists.jboss.org</a>&gt;<br>
&gt; Sent: Monday, October 21, 2013 2:09:41 PM<br>
&gt; Subject: [forge-dev] Several architectural styles in Forge (was Wondering about coding convention)<br>
&gt;<br>
&gt; 2013/10/21 Vineet Reynolds Pereira &lt; <a href="mailto:vpereira@redhat.com" target="_blank">vpereira@redhat.com</a> &gt;<br>
&gt;<br>
&gt;<br>
&gt;<br>
&gt;<br>
&gt;<br>
&gt; IMHO we should not be putting persistence concerns in either the JSF beans or<br>
&gt; the REST resources.<br>
&gt; They should go into a service or a repository or whatever data access pattern<br>
&gt; is suitable for the context.<br>
&gt; This is where we lack any standardization at the moment, and it would be<br>
&gt; better to not limit this exercise to improving the conventions alone, but<br>
&gt; also the architecture.<br>
&gt;<br>
&gt;<br>
&gt; Vineet, this is the topic I&#39;m writing about at the moment. To be honest, I<br>
&gt; quite like to have persistent concerns in JSF beans and REST for certain<br>
&gt; projects... but not all, and that&#39;s where I thing Forge should give some<br>
&gt; choices. What I&#39;m writing is about having 3 different architectural styles<br>
&gt; that could be resume like this (using CLI) :<br>
&gt;<br>
&gt; Current (generates JSF/REST from entities) :<br>
&gt; jsf-scaffold-from-entity<br>
&gt; rest-scaffold-from-entity<br>
&gt;<br>
&gt; EJB Centric (add a service layer to deal with persistence) :<br>
&gt; ejb-scaffold-from-entity<br>
&gt; jsf-scaffold-from-ejb<br>
&gt; rest-scaffold-from-ejb<br>
&gt;<br>
&gt; REST centric (the JSF backing beans use the REST endpoint, using JAX-RS 2.0<br>
&gt; Client API) :<br>
&gt; rest-scaffold-from-entity<br>
&gt; jsf-scaffold-from-rest<br>
&gt;<br>
<br>
</div></div>Very interesting. I was about to suggest linking any work in this space with FORGE-944.<br>
Overall, I get the impression that we should structure commands based on<br>
developer workflows given common architectural styles.<br>
<br>
I&#39;ll await your post.<br>
<div><br>
&gt;<br>
&gt; I will let you know when the post is written, it will be clearer<br>
&gt;<br>
&gt; --<br>
&gt; Antonio Goncalves<br>
&gt; Software architect and Java Champion<br>
&gt;<br>
&gt; Web site | Twitter | LinkedIn | Paris JUG | Devoxx France<br>
&gt;<br>
</div>&gt; _______________________________________________<br>
&gt; forge-dev mailing list<br>
&gt; <a href="mailto:forge-dev@lists.jboss.org" target="_blank">forge-dev@lists.jboss.org</a><br>
&gt; <a href="https://lists.jboss.org/mailman/listinfo/forge-dev" target="_blank">https://lists.jboss.org/mailman/listinfo/forge-dev</a><br>
_______________________________________________<br>
forge-dev mailing list<br>
<a href="mailto:forge-dev@lists.jboss.org" target="_blank">forge-dev@lists.jboss.org</a><br>
<a href="https://lists.jboss.org/mailman/listinfo/forge-dev" target="_blank">https://lists.jboss.org/mailman/listinfo/forge-dev</a><br>
</blockquote></div><br><br clear="all"><div><br></div>-- <br>Antonio <span>Goncalves</span> <br>Software architect and Java Champion<br><br><a href="http://www.antoniogoncalves.org/" target="_blank">Web site</a> | <a href="http://twitter.com/agoncal" target="_blank">Twitter</a> | <a href="http://www.linkedin.com/in/agoncal" target="_blank"><span>LinkedIn</span></a> | <a href="http://www.parisjug.org/" target="_blank">Pa<span>ris</span> JUG</a> | <a href="http://www.devoxx.fr/" target="_blank"><span>Devoxx</span> France</a>
</div></div></div></div>
<br>_______________________________________________<br>
forge-dev mailing list<br>
<a href="mailto:forge-dev@lists.jboss.org" target="_blank">forge-dev@lists.jboss.org</a><br>
<a href="https://lists.jboss.org/mailman/listinfo/forge-dev" target="_blank">https://lists.jboss.org/mailman/listinfo/forge-dev</a><br></blockquote></div><br><br clear="all"><div><br></div>-- <br></div></div><span class="HOEnZb"><font color="#888888">Lincoln Baxter, III<br>
<a href="http://ocpsoft.org" target="_blank">http://ocpsoft.org</a><br>
&quot;Simpler is better.&quot;
</font></span></div></div>
<br>_______________________________________________<br>
forge-dev mailing list<br>
<a href="mailto:forge-dev@lists.jboss.org">forge-dev@lists.jboss.org</a><br>
<a href="https://lists.jboss.org/mailman/listinfo/forge-dev" target="_blank">https://lists.jboss.org/mailman/listinfo/forge-dev</a><br></blockquote></div><br><br clear="all"><div><br></div>-- <br>Antonio Goncalves <br>Software architect and Java Champion<br>
<br><a href="http://www.antoniogoncalves.org/" target="_blank">Web site</a> | <a href="http://twitter.com/agoncal" target="_blank">Twitter</a> | <a href="http://www.linkedin.com/in/agoncal" target="_blank">LinkedIn</a> | <a href="http://www.parisjug.org/" target="_blank">Paris JUG</a> | <a href="http://www.devoxx.fr/" target="_blank">Devoxx France</a>
</div>