[forge-dev] Forge Plugin

Lincoln Baxter, III lincolnbaxter at gmail.com
Sun Nov 13 17:49:17 EST 2011


All good ideas.

One of the reasons we don't generate services with the entity command is
because typically users will continue to add fields to entities, or perform
other modifications before generating a service class.

By using a second command, you get the freedom to operate on new or
existing entities at will.

~Lincoln

On Sun, Nov 13, 2011 at 10:00 PM, Rafael Pestano <rmpestano at gmail.com>wrote:

> Hi Torben, hi Lincon,
>
> I also think that the entity plugin is a good place because to perform
> crud operation we basically only need the entity (ok you can generate the
> service later, its just a metter to inform the entity to the service plugin
> but i would preffer generate all at once), the only problem i see in the
> Torben's approach is that you're forcing the use of JPA + EJB, for example
> i preffer to use hibernate + statefull EJB  to perfform the crud opp,
> sometimes plain jdbc.
>
> To overcome this we could  provide some parametrized service templates
> which ${entity}Servive would extend, something like:
>
> import org.jboss.forge.scaffold.service.${serviceTemplate}
>
> public class ${entity}Servive extends
> org.jboss.forge.scaffold.service.${serviceTemplate}<${entity}>
>
> where serviceTemplate can be a stateless(ful) ebj or Spring template with
> crud operations based on entityManager or hibernate session.
>
> so when the user is generating the entity a list of service templates is
> prompted.
>
> Just an idea, maybe it helps.
>
>
> 2011/11/13 Lincoln Baxter <lincoln at ocpsoft.com>
>
>> Hi Torben,
>>
>> Our trip fron Stuttgart was great :) lots of speed.
>>
>> That's fantastic! Another win over Archetypes ;) I will take a look at
>> your code. We could definitely figure out where to put this. Just so I know
>> what you are thinking, why do you think the entity-plugin is the right
>> place?
>>
>> Copying forge-dev,
>> ~Lincoln
>>
>> On Fri, Nov 11, 2011 at 1:28 PM, Torben Jaeger <torben at jit-central.com>wrote:
>>
>>> Hey Lincoln,
>>>
>>> how was your trip to Munich? Devoxx next?
>>>
>>> I've made some first steps with forge plugins. I've convinced my team to
>>> use forge for code generation and my colleague told me that he wants to use
>>> forge instead of the already self-written, existing maven archetypes!
>>> Mission accomplished ;)
>>>
>>> If u have time maybe u can have a look at
>>> https://github.com/jicken/entity-service-forge-plugin
>>> Maybe this could be done using the entity plugin with an additional
>>> option: --create-service-facade.
>>>
>>> I was wondering why it doesn't already exist ...
>>>
>>> Say hi to Dan and ALR ... if u're still traveling together.
>>>
>>> Cheers,
>>>
>>> Torben
>>>
>>>
>>> Torben Jäger
>>> Geschäftsführer
>>>
>>> JIT Consulting GmbH
>>> Obere Schlossgartenstr. 10
>>> D-74196 Neuenstadt a. Kocher
>>>
>>> Handelsregister         Amtsgericht Heilbronn, HRB 8567
>>> Geschäftsführer         Torben Jäger
>>> Ust-IdNr.                             DE234692437
>>>
>>> Tel. +49 - (0) 152 3357 9096
>>> Fax  +49 - (0) 71 39 45 46 40
>>>
>>> mailto:torben.jaeger at jit-consulting.eu
>>> http://www.jit-consulting.eu
>>>
>>> public key available via keyserver hkp://subkeys.pgp.net
>>>
>>> "it's jit, not shit."
>>>
>>>
>>>
>>>
>>>
>>>
>>
>>
>> --
>> Lincoln Baxter, III
>> http://ocpsoft.com
>> http://scrumshark.com
>> "Keep it Simple"
>>
>> _______________________________________________
>> forge-dev mailing list
>> forge-dev at lists.jboss.org
>> https://lists.jboss.org/mailman/listinfo/forge-dev
>>
>>
>
>
> --
> <http://www.advancedit.com.br/>Att,
>
> Rafael M. Pestano
>
> Desenvolvedor Java Cia. de Processamento de Dados do Rio Grande do Sul
> Graduando em Ciência da Computação UFRGS
> @realpestano
>
>
> _______________________________________________
> forge-dev mailing list
> forge-dev at lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/forge-dev
>
>


-- 
Lincoln Baxter, III
http://ocpsoft.com
http://scrumshark.com
"Keep it Simple"
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/forge-dev/attachments/20111113/8d1297d3/attachment.html 


More information about the forge-dev mailing list