You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tapestry.apache.org by John Coleman <jo...@ntlworld.com> on 2005/11/24 14:02:25 UTC

how about a Tapestry app generator

I am working on a project to create a Tapestry application generator. This will be for lightweight applications, i.e. the typical web application not requiring EJB and a application server, and all that heavy J2EE stuff.

The idea is that a enterprise model is designed using a GUI tool. This will define a set of entity object interfaces, services and persistence layer.

>From these a set of Tapestry components will be generated; i.e. create entity page, retrieve entity page, update entity page, etc... and then a HiveMind service business class encapsulating the CRUD persistence and anything else, and hooking into the persistence layer - I'm using Cayenne at the moment. It will also wire up the services using a generated hivemodule. Everything will be well decoupled and pluggable, lightweight, using the minimum number of frameworks/technologies.

I wonder if others are interested in this venture, people with Tapestry/HiveMind/Cayenne and Velocity would be ideal. If so, it would be nice to set up an open source project.

If you know of anything simlar, please let me know.

John

Re: how about a Tapestry app generator

Posted by Ahmed Mohombe <am...@yahoo.com>.
> If you know of anything simlar, please let me know.
There's JAG:
http://jag.sourceforge.net/

It has almost everything, and it's extensible to Tapestry (only someone needs to do the velocity
templates for Tapestry) or other MVCs.
Of course, the GUI also needs some polish cause it looks pretty ugly for now, but still it's
pretty practical.

Ahmed.


---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org


persistence layer for a Tapestry app generator

Posted by Konstantin Ignatyev <kg...@yahoo.com>.
Actually Hibernate is LGPL:
http://www.hibernate.org/196.html
therefore is safe bet for any kind of projects. I
suggest using Hibernate and/or iBatis.

In both cases domain objects can be simple POJOs and
will have no dependency on either od those frameworks.


--- Spencer Crissman <sp...@gmail.com>
wrote:

> I did something similar here.  It is actually a
> Tapestry app where you can
> define the data model, and then download a zipped up
> project directory that
> contains all the CRUD classes, pages, and template
> files.  I'll probably
> redefine it once I've got my head around Tap4, as it
> only works with 3 right
> now.   Velocity templates are used for the actual
> generation.
> 
> The main problem seems to be the differences in the
> persistence layer.
> Someone has proposed Cayenne, others Hibernate,
> while we have been using
> Apache's OJB.  Since most of the files depend on the
> persistence layer
> objects, it is very hard to have a generic solution
> which will work for
> everyone.  Hibernate does seem to have the most
> support out there, but we
> prefer the Apache license to the GPL.
> 
> Code generation is a perfectly valid technique so
> long as you are aware of
> its limitations.  We use it as a starting point, and
> a way to quickly
> prototype applications, and have had no problems
> there.  There are
> limitations, but also many benefits.
> 
> I tend to agree with the idea that it is so much
> simpler to go with a
> targetted generator as opposed to a general one that
> it would be more
> worthwhile to approach from that direction, but
> please keep me up to date
> with what you decide to do because if there are
> places where reuse is
> possible, I'd happily pitch in.
> 
> Spencer
> 
> 
> On 11/24/05, Pedro Abelleira Seco <pe...@usc.es>
> wrote:
> >
> > For my current project I wrote a generator for the
> entity clases,
> > hibernate files, DAOs, CRUD pages in Tapestry,
> etc. I suppose that most
> > people doing Tapestry projects with many forms
> have some generator tool
> > or even some reflection magic to not having to
> generate anything
> > (alghough this, for a medium sized project as
> mine, doesn't pay the
> > effort).
> >
> > The  main problem is the enviroment which your
> application defines. My
> > forms have some visual and code conventions (as
> how to set the title,
> > some own developed components for security,
> related entities, etc.).
> >
> > So, for a medium sized app a generic generator
> would not be suitable.
> > For simple apps Trails seems to be a good enough
> tool.
> >
> > BTW, my generator took 2 days of work, being so
> focused in our
> > conventions, it turned out to be very simple to
> implement. I suspect
> > that the generic case would be enormously more
> difficult and not really
> > very useful, IMHO.
> >
> > My 2 cents, anyways.
> > Pedro
> >
> >
> > El Xov, 24-11-2005 a las 13:02 +0000, John Coleman
> escribió:
> > > I am working on a project to create a Tapestry
> application generator.
> > This will be for lightweight applications, i.e.
> the typical web
> > application not requiring EJB and a application
> server, and all that heavy
> > J2EE stuff.
> > >
> > > The idea is that a enterprise model is designed
> using a GUI tool. This
> > will define a set of entity object interfaces,
> services and persistence
> > layer.
> > >
> > > >From these a set of Tapestry components will be
> generated; i.e. create
> > entity page, retrieve entity page, update entity
> page, etc... and then a
> > HiveMind service business class encapsulating the
> CRUD persistence and
> > anything else, and hooking into the persistence
> layer - I'm using Cayenne at
> > the moment. It will also wire up the services
> using a generated hivemodule.
> > Everything will be well decoupled and pluggable,
> lightweight, using the
> > minimum number of frameworks/technologies.
> > >
> > > I wonder if others are interested in this
> venture, people with
> > Tapestry/HiveMind/Cayenne and Velocity would be
> ideal. If so, it would be
> > nice to set up an open source project.
> > >
> > > If you know of anything simlar, please let me
> know.
> > >
> > > John
> >
> >
> >
>
---------------------------------------------------------------------
> > To unsubscribe, e-mail:
> tapestry-user-unsubscribe@jakarta.apache.org
> > For additional commands, e-mail:
> tapestry-user-help@jakarta.apache.org
> >
> >
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org


Re: how about a Tapestry app generator

Posted by Spencer Crissman <sp...@gmail.com>.
I did something similar here.  It is actually a Tapestry app where you can
define the data model, and then download a zipped up project directory that
contains all the CRUD classes, pages, and template files.  I'll probably
redefine it once I've got my head around Tap4, as it only works with 3 right
now.   Velocity templates are used for the actual generation.

The main problem seems to be the differences in the persistence layer.
Someone has proposed Cayenne, others Hibernate, while we have been using
Apache's OJB.  Since most of the files depend on the persistence layer
objects, it is very hard to have a generic solution which will work for
everyone.  Hibernate does seem to have the most support out there, but we
prefer the Apache license to the GPL.

Code generation is a perfectly valid technique so long as you are aware of
its limitations.  We use it as a starting point, and a way to quickly
prototype applications, and have had no problems there.  There are
limitations, but also many benefits.

I tend to agree with the idea that it is so much simpler to go with a
targetted generator as opposed to a general one that it would be more
worthwhile to approach from that direction, but please keep me up to date
with what you decide to do because if there are places where reuse is
possible, I'd happily pitch in.

Spencer


On 11/24/05, Pedro Abelleira Seco <pe...@usc.es> wrote:
>
> For my current project I wrote a generator for the entity clases,
> hibernate files, DAOs, CRUD pages in Tapestry, etc. I suppose that most
> people doing Tapestry projects with many forms have some generator tool
> or even some reflection magic to not having to generate anything
> (alghough this, for a medium sized project as mine, doesn't pay the
> effort).
>
> The  main problem is the enviroment which your application defines. My
> forms have some visual and code conventions (as how to set the title,
> some own developed components for security, related entities, etc.).
>
> So, for a medium sized app a generic generator would not be suitable.
> For simple apps Trails seems to be a good enough tool.
>
> BTW, my generator took 2 days of work, being so focused in our
> conventions, it turned out to be very simple to implement. I suspect
> that the generic case would be enormously more difficult and not really
> very useful, IMHO.
>
> My 2 cents, anyways.
> Pedro
>
>
> El Xov, 24-11-2005 a las 13:02 +0000, John Coleman escribió:
> > I am working on a project to create a Tapestry application generator.
> This will be for lightweight applications, i.e. the typical web
> application not requiring EJB and a application server, and all that heavy
> J2EE stuff.
> >
> > The idea is that a enterprise model is designed using a GUI tool. This
> will define a set of entity object interfaces, services and persistence
> layer.
> >
> > >From these a set of Tapestry components will be generated; i.e. create
> entity page, retrieve entity page, update entity page, etc... and then a
> HiveMind service business class encapsulating the CRUD persistence and
> anything else, and hooking into the persistence layer - I'm using Cayenne at
> the moment. It will also wire up the services using a generated hivemodule.
> Everything will be well decoupled and pluggable, lightweight, using the
> minimum number of frameworks/technologies.
> >
> > I wonder if others are interested in this venture, people with
> Tapestry/HiveMind/Cayenne and Velocity would be ideal. If so, it would be
> nice to set up an open source project.
> >
> > If you know of anything simlar, please let me know.
> >
> > John
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
>
>

Re: how about a Tapestry app generator

Posted by Pedro Abelleira Seco <pe...@usc.es>.
For my current project I wrote a generator for the entity clases,
hibernate files, DAOs, CRUD pages in Tapestry, etc. I suppose that most
people doing Tapestry projects with many forms have some generator tool
or even some reflection magic to not having to generate anything
(alghough this, for a medium sized project as mine, doesn't pay the
effort).

The  main problem is the enviroment which your application defines. My
forms have some visual and code conventions (as how to set the title,
some own developed components for security, related entities, etc.).

So, for a medium sized app a generic generator would not be suitable.
For simple apps Trails seems to be a good enough tool.

BTW, my generator took 2 days of work, being so focused in our
conventions, it turned out to be very simple to implement. I suspect
that the generic case would be enormously more difficult and not really
very useful, IMHO.

My 2 cents, anyways.
Pedro
 

El Xov, 24-11-2005 a las 13:02 +0000, John Coleman escribió:
> I am working on a project to create a Tapestry application generator. This will be for lightweight applications, i.e. the typical web application not requiring EJB and a application server, and all that heavy J2EE stuff.
> 
> The idea is that a enterprise model is designed using a GUI tool. This will define a set of entity object interfaces, services and persistence layer.
> 
> >From these a set of Tapestry components will be generated; i.e. create entity page, retrieve entity page, update entity page, etc... and then a HiveMind service business class encapsulating the CRUD persistence and anything else, and hooking into the persistence layer - I'm using Cayenne at the moment. It will also wire up the services using a generated hivemodule. Everything will be well decoupled and pluggable, lightweight, using the minimum number of frameworks/technologies.
> 
> I wonder if others are interested in this venture, people with Tapestry/HiveMind/Cayenne and Velocity would be ideal. If so, it would be nice to set up an open source project.
> 
> If you know of anything simlar, please let me know.
> 
> John


---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org


Re: how about a Tapestry app generator

Posted by John Coleman <jo...@ntlworld.com>.
Thanks Michael, you are right, in fact both techniques might come into play.
I like the idea of Tapestry where the framework does most of the mundane
stuff leaving us to get on with more useful chores.

Coming from a 2GL background (IBMs RPG) I am amazed how long Java app dev
takes, and the lack of more sophisticated reusable components (like we see
in Swing). I also recall when 4GLs were hip, and really they were either too
simple or rather complex and expensive. They only seemed to hit the spot for
a niche market. A Tapestry component generator would be very useful, giving
us reuse but also flexibility.

I'll take a look at Trails and JAG, as I am sure they have some useful
concepts - many thanks for these suggestions. I am surprised there are not
more tools like this for Java though, and I think some more would be very
healthy. I though JAG probably a little heavy for lightweight apps and
Trails might be a little restrictive. Something a mix of both ideas and a
little inbetween in terms of complexity might fit better.

Tapestry plus Spring seems like a great idea, but probably still excessive
for the average simple web application, hence my idea of Tapestry +
HiveMind. Getting the dev team onboard with Tapestry is a struggle, and more
complex frameworks means a lot of learning curve and slower delivery, plus
higher price! We are finding Tapestry is more productive than our usual
Struts developments as the quality, clarity and simplicity of Tapestry pay
off nicely. HLS seems to have really hit the spot.

I think HiveMind needs some work on it, I'd like to see that xpooled idea
implemented, which steps closer to being useful for CMP, without getting too
tricky.

John

----- Original Message ----- 
From: "Michael Campbell" <mi...@gmail.com>
To: <ta...@jakarta.apache.org>
Sent: Thursday, November 24, 2005 4:25 PM
Subject: Re: how about a Tapestry app generator


> Ahmed Mohombe <am...@yahoo.com> writes:
>
> > > Sounds a bit like trails, doesn't it?
>
> > Nope :). AFAIK The main idea of Trails is NOT to generate code :),
> > but to "reflect" what's required, using mostly annotations.
>
> Let's not fall down on semantics; the OP is working on a project to
> come up with an application generator.  Code generation is one way of
> doing that.  So is reflection.  They are both means to the same end.
>
> In that light, it sounds a lot like trails.
>
> -- 
> Michael Campbell
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
>
>



---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org


Re: how about a Tapestry app generator

Posted by Michael Campbell <mi...@gmail.com>.
Ahmed Mohombe <am...@yahoo.com> writes:

> > Sounds a bit like trails, doesn't it?

> Nope :). AFAIK The main idea of Trails is NOT to generate code :),
> but to "reflect" what's required, using mostly annotations.

Let's not fall down on semantics; the OP is working on a project to
come up with an application generator.  Code generation is one way of
doing that.  So is reflection.  They are both means to the same end.

In that light, it sounds a lot like trails.

-- 
Michael Campbell


---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org


Re: how about a Tapestry app generator

Posted by "t.n.a." <tn...@sharanet.org>.
Ahmed Mohombe wrote:

>> Sounds a bit like trails, doesn't it? 
>
> Nope :). AFAIK The main idea of Trails is NOT to generate code :), but 
> to "reflect" what's required,
> using mostly annotations.

I see a lot of people seem to see the same similarity I saw, but you've 
probably given it a lot more thought so...what's the upside of 
generating code instead of reflection, regardless of the level of 
abstraction I use the term?
Generally speaking, code generation is not something a programmer should 
welcome with open arms - I've heard people say something along those 
lines, I got burned a couple of times myself, I've seen some of the 
problems. Still, it can be used to solve problems. What would be the 
main difference between AMAGe (Ahmed Mohombe Application Generator :-)) 
and Trails and would that justify going about a completely new framework?

t.n.a.

---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org


Re: how about a Tapestry app generator

Posted by Ahmed Mohombe <am...@yahoo.com>.
> Sounds a bit like trails, doesn't it? 
Nope :). AFAIK The main idea of Trails is NOT to generate code :), but to "reflect" what's required,
using mostly annotations.

Ahmed.


---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org


Re: how about a Tapestry app generator

Posted by "t.n.a." <tn...@sharanet.org>.
John Coleman wrote:

>I am working on a project to create a Tapestry application generator. This will be for lightweight applications, i.e. the typical web application not requiring EJB and a application server, and all that heavy J2EE stuff.
>
>The idea is that a enterprise model is designed using a GUI tool. This will define a set of entity object interfaces, services and persistence layer.
>
>>>From these a set of Tapestry components will be generated; i.e. create entity page, retrieve entity page, update entity page, etc... and then a HiveMind service business class encapsulating the CRUD persistence and anything else, and hooking into the persistence layer - I'm using Cayenne at the moment. It will also wire up the services using a generated hivemodule. Everything will be well decoupled and pluggable, lightweight, using the minimum number of frameworks/technologies.
>
>I wonder if others are interested in this venture, people with Tapestry/HiveMind/Cayenne and Velocity would be ideal. If so, it would be nice to set up an open source project.
>
>If you know of anything simlar, please let me know.
>  
>
Sounds like a wonderful goal you're aiming for...I'll reserve bolder 
comments till I hear and see more about/of it.
Sounds a bit like trails, doesn't it? I'm starting to hear cracks in the 
very thin ice here, comparing a technology I've never used with a 
technology that doesn't exist yet, so I'll leave it at that. :)

t.n.a.


---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org


Re: how about a Tapestry app generator

Posted by Geoff Longman <gl...@gmail.com>.
Hmm, sounds like Trails to me. Is it good idea to start another app
generator project? Perhaps Chris Nelson could use some help.

Cheers,

Geoff

On 11/24/05, John Coleman <jo...@ntlworld.com> wrote:
> I am working on a project to create a Tapestry application generator. This will be for lightweight applications, i.e. the typical web application not requiring EJB and a application server, and all that heavy J2EE stuff.
>
> The idea is that a enterprise model is designed using a GUI tool. This will define a set of entity object interfaces, services and persistence layer.
>
> From these a set of Tapestry components will be generated; i.e. create entity page, retrieve entity page, update entity page, etc... and then a HiveMind service business class encapsulating the CRUD persistence and anything else, and hooking into the persistence layer - I'm using Cayenne at the moment. It will also wire up the services using a generated hivemodule. Everything will be well decoupled and pluggable, lightweight, using the minimum number of frameworks/technologies.
>
> I wonder if others are interested in this venture, people with Tapestry/HiveMind/Cayenne and Velocity would be ideal. If so, it would be nice to set up an open source project.
>
> If you know of anything simlar, please let me know.
>
> John
>


--
The Spindle guy.           http://spindle.sf.net
Get help with Spindle:   
http://lists.sourceforge.net/mailman/listinfo/spindle-user
Announcement Feed:    
http://www.jroller.com/rss/glongman?catname=/Announcements
Feature Updates:            http://spindle.sf.net/updates

---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org


Re: how about a Tapestry app generator

Posted by Howard Lewis Ship <hl...@gmail.com>.
On 11/24/05, Christian Mittendorf <ch...@freenet.de> wrote:
>
> Step 1: create a new project
> Step 2: add you database model
> Step 3: there's no step 3 ;-)
>
> Ok, there are some more steps if you want your app to look nice and
> work properly.
>

Threre was a whole lot of step 3 for anything that felt like a real application.
And step 3 was often one-way: it would generate templates and wods and classes
and there was no back-and-forth.

Trails is better already in many ways; not quite a slick, but because
of the use of reflection and naming conventions, you can mix and
match, within the same page, what Trails does and what you do, pretty
much on a field-by-field basis.


--
Howard M. Lewis Ship
Independent J2EE / Open-Source Java Consultant
Creator, Jakarta Tapestry
Creator, Jakarta HiveMind

Professional Tapestry training, mentoring, support
and project work.  http://howardlewisship.com

---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org


Re: how about a Tapestry app generator

Posted by Christian Mittendorf <ch...@freenet.de>.
Hi!

> I am working on a project to create a Tapestry application  
> generator. This
> will be for lightweight applications, i.e. the typical web  
> application not
> requiring EJB and a application server, and all that heavy J2EE stuff.
[...]
> I wonder if others are interested in this venture, people with
> Tapestry/HiveMind/Cayenne and Velocity would be ideal. If so, it  
> would be
> nice to set up an open source project.
>
> If you know of anything simlar, please let me know.

Do you know Direct2Web? It's an old WebObjects technology where you  
start a new
application with an EOModel (compareable to your Cayenne DB Model).  
It's very
nice if you need a fast way to create a gui to your database.

http://developer.apple.com/documentation/WebObjects/ 
Developing_With_D2W/index.html

Step 1: create a new project
Step 2: add you database model
Step 3: there's no step 3 ;-)

Ok, there are some more steps if you want your app to look nice and  
work properly.

But it's already possible to work on your db after firing up your  
application
following these two steps.

In a next step you start creating rules. D2W is using a set of rules  
to change
the way your application works.You can create a rule for formatting  
text fields,
for defining the order of the object properties, for displaying  
relationsships
to other objects, etc.

It might be worth a look if you want to create a new OpenSource  
project. There are
some nice ideas hidden in D2W.

I've seen a company that reworked Apples templates for D2W apps to be  
fully xhtml
compliant and they did all customizing for their client gui using  
CSS. It was a
really nice solution.

Christian



---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org


Re: how about a Tapestry app generator

Posted by Chris Burnley <ch...@gmail.com>.
You should checkout trails https://trails.dev.java.net/. It does a lot of
what you're talking about but with Hibernate instead of Cayenne.

On 11/24/05, John Coleman <jo...@ntlworld.com> wrote:
>
> I am working on a project to create a Tapestry application generator. This
> will be for lightweight applications, i.e. the typical web application not
> requiring EJB and a application server, and all that heavy J2EE stuff.
>
> The idea is that a enterprise model is designed using a GUI tool. This
> will define a set of entity object interfaces, services and persistence
> layer.
>
> From these a set of Tapestry components will be generated; i.e. create
> entity page, retrieve entity page, update entity page, etc... and then a
> HiveMind service business class encapsulating the CRUD persistence and
> anything else, and hooking into the persistence layer - I'm using Cayenne at
> the moment. It will also wire up the services using a generated hivemodule.
> Everything will be well decoupled and pluggable, lightweight, using the
> minimum number of frameworks/technologies.
>
> I wonder if others are interested in this venture, people with
> Tapestry/HiveMind/Cayenne and Velocity would be ideal. If so, it would be
> nice to set up an open source project.
>
> If you know of anything simlar, please let me know.
>
> John
>