[weld-dev] SQL framework proof of concept

Marcus Smedman marcus at smedman.org
Thu Nov 26 15:16:10 EST 2009


OK. I played around with it a bit, but it's all pretty new to me. I mean not
only the seam-sql, but the whole JEE stack and everything that comes with
it. I've monitored this mail list for a while though and it's very
interesting and I really learn a lot.

 

Regarding the seam-sql I added a Drop (to speed up my small tests), Alter
(to add foreign keys) and a Join (a bit messy when/if using aliases) to try
to understand how Gavin had did the other stuff. There's a lot of stuff I
don't fully understand. (is a join an Expression for example?). 

 

Anyway, my idea was to make some tests using (some of) the tables added when
running add-identity-management by seam-gen (user_account, user_role and
user_account_role). I have tested it (DROP/ALTER/JOIN) on MySQL  and it
seems to work, but I'm not sure I fully understand how to follow the
"pattern" that Gavin have put together. 

 

Anyway, if I can help in any way please let me know, I might get some time
to help with tests or whatever.

 

Regards

Marcus

 

 

From: Arbi Sookazian [mailto:asookazian at gmail.com] 
Sent: den 26 november 2009 18:03
To: Marcus Smedman
Cc: Weld-Dev
Subject: Re: [weld-dev] SQL framework proof of concept

 

Marcus, yep, this is basically exactly what I did.  Now I need to spend some
more time with the API and testing, etc.  And unfortunately, today is not a
good day...  So thx for the zip offer but I don't think I'll need it for
now.  Eventually I'd like to run some load tests to compare performance vs.
iBATIS and Spring JDBC equivalents.  I'll need to come up with a
plan/roadmap for this sub-project first and then I'll post that on this
list.

On Thu, Nov 26, 2009 at 12:12 AM, Marcus Smedman <marcus at smedman.org> wrote:

Hi Arbi,

 

Not sure if this is what you where referring to, but I got it up and running
by doing this:

 

1. Create an Eclipse project and add the source from seam-sql.zip

2. Download weld from http://seamframework.org/Download

3. Unpack and add the following libs to the project:

                             * <weld-x.y.z>\artifacts\weld\weld-se.jar

                             * <weld-x.y.z>\artifacts\weld\weld-servlet.jar

4. Add a hsql jdbc driver to the project (from
http://sourceforge.net/projects/hsqldb/files/ or
<jboss-seam-x.y.z>\lib\hsqldb.jar)

5. Uncomment the eg.Main.main method and execute it. Generates the following
output:

 

   create table users (name varchar not null, username varchar not null
primary key, password varchar not null)

   insert into users (name, username, password) values (?, ?, ?)

   update users set name=?, password=? where username=?

   select u.name as n from users as u where (u.username=? and u.password=?)

   Gavin King

 

I have an Eclipse proj packed up in a zip if you'd like it (4MB).

 

Regards

Marcus

 

 

 

From: weld-dev-bounces at lists.jboss.org
[mailto:weld-dev-bounces at lists.jboss.org] On Behalf Of Arbi Sookazian
Sent: den 26 november 2009 08:41
To: Gavin King
Cc: Weld-Dev
Subject: Re: [weld-dev] SQL framework proof of concept

 

I'm interested.  Plz provide instructions on how to build/deploy so I can
test it out (it's getting late so I haven't even opened the project in
Eclipse yet).  I noticed that the public static void main() in Main class is
commented out.  Is it safe to assume that this is basically a Weld SE app
(or soon to be Seam3) to test with? thx.

On Wed, Nov 25, 2009 at 11:02 PM, Gavin King <gavin.king at gmail.com> wrote:

Here's a proof-of concept for the typesafe SQL framework. There's lots
of stuff missing, but I can already do basic queries, inserts and
updates. Anyone want to take over from here?

--
Gavin King
gavin.king at gmail.com
http://in.relation.to/Bloggers/Gavin
http://hibernate.org
http://seamframework.org

_______________________________________________
weld-dev mailing list
weld-dev at lists.jboss.org
https://lists.jboss.org/mailman/listinfo/weld-dev

 

 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/weld-dev/attachments/20091126/0fcfa525/attachment.html 


More information about the weld-dev mailing list