You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@maven.apache.org by Vincent Massol <vm...@pivolis.com> on 2005/10/22 14:48:15 UTC

[M2] Database plugin?

Hi,

I'm looking for a m2 db plugin. Anyone working on one?

I'm currently working with Derby but ideally this plugin should probably be
generic (with extensions) and allow to do things like:

1- create schema
2- load data in database
3- start/stop database (database dependent)
4- create db instance (database dependent and not always scriptable I guess)

Would someone know a Java framework for manipulating databases and that
could be wrapped in a m2 plugin easily?

I was thinking about DDLUtils (http://db.apache.org/ddlutils/) but I have no
experience with it and I don't know how solid it is. Also it won't do points
3 and 4 above.

Any other idea?

Thanks
-Vincent


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


Re: [M2] Database plugin?

Posted by Brett Porter <br...@apache.org>.
Jason van Zyl wrote:
>>I was thinking about DDLUtils (http://db.apache.org/ddlutils/) but I have no
>>experience with it and I don't know how solid it is. Also it won't do points
>>3 and 4 above.
> 
> 
> There is commons-sql (which might have moved to db.apache.org) which was
> originally taken from Torque in the Turbine projects and it has been
> used for quite a while. It allows you to specify the table structure
> using XML and then generates the DDL for various RDBMSes.
> 
> I've not looked at ddlutils, but it would be nice to find some standard
> tools for this.

I think they are the same thing if memory serves (it was renamed when 
moved to db.apache.org).

- Brett

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


Re: [M2] Database plugin?

Posted by Jason van Zyl <ja...@maven.org>.
On Sat, 2005-10-22 at 14:48 +0200, Vincent Massol wrote:
> Hi,
> 
> I'm looking for a m2 db plugin. Anyone working on one?
> 
> I'm currently working with Derby but ideally this plugin should probably be
> generic (with extensions) and allow to do things like:
> 
> 1- create schema
> 2- load data in database
> 3- start/stop database (database dependent)
> 4- create db instance (database dependent and not always scriptable I guess)
> 
> Would someone know a Java framework for manipulating databases and that
> could be wrapped in a m2 plugin easily?
> 
> I was thinking about DDLUtils (http://db.apache.org/ddlutils/) but I have no
> experience with it and I don't know how solid it is. Also it won't do points
> 3 and 4 above.

There is commons-sql (which might have moved to db.apache.org) which was
originally taken from Torque in the Turbine projects and it has been
used for quite a while. It allows you to specify the table structure
using XML and then generates the DDL for various RDBMSes.

I've not looked at ddlutils, but it would be nice to find some standard
tools for this.

> Any other idea?
> 
> Thanks
> -Vincent
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> For additional commands, e-mail: dev-help@maven.apache.org
> 
> 
-- 
jvz.

Jason van Zyl
jason at maven.org
http://maven.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


RE: [M2] Database plugin?

Posted by Vincent Massol <vm...@pivolis.com>.

> -----Original Message-----
> From: Mark Hobson [mailto:markhobson@gmail.com]
> Sent: lundi 24 octobre 2005 11:49
> To: Maven Developers List
> Subject: Re: [M2] Database plugin?
> 
> It's also worth noting how ORM solutions can affect points (1) & (2).
> For example, Hibernate normally creates and executes the db script for
> (1) - this is currently provided by the hibernate2/3 m2 plugin goals.
> 
> Regarding (2) with Hibernate, it normally makes sense to load data
> using the objects themselves, since they are the native database
> language in ORMs as opposed to SQL.  I did look for support for this
> in DBUnit but couldn't find any.

Thanks for the information. I'll take that into account in the solution I'll
propose.
 
> So any generic solution would need to keep these points in mind.  I
> certainly think there's a need for something like this as it would
> eliminate proprietary db/orm plugins - almost Cargo for db's.. ;)

:-)

Thanks
-Vincent

> On 24/10/05, Eric Pugh <ep...@upstate.com> wrote:
> > While DBUnit IS about testing, I think that maybe the most common use
> > case for DBUnit isn't about testing datasets, but using it to load
> > test data up, which revolves around #2 on your list!
> >
> > I've thought about pulling out some sort of core part of DBUnit to be
> > called DBLoader or something....
> >
> > Eric
> > On Oct 22, 2005, at 1:05 PM, Vincent Massol wrote:
> >
> > >
> > >
> > >
> > >> -----Original Message-----
> > >> From: Vincent Siveton [mailto:vincent.siveton@gmail.com]
> > >> Sent: samedi 22 octobre 2005 17:04
> > >> To: 'Maven Developers List'
> > >> Subject: RE: [M2] Database plugin?
> > >>
> > >> Hi Vincent,
> > >>
> > >>
> > >>> I'm looking for a m2 db plugin. Anyone working on one?
> > >>>
> > >>
> > >> Good idea!
> > >>
> > >>
> > >>> I'm currently working with Derby but ideally this plugin should
> > >>> probably
> > >>> be
> > >>> generic (with extensions) and allow to do things like:
> > >>>
> > >>> 1- create schema
> > >>> 2- load data in database
> > >>>
> > >>
> > >> Dbunit (as you know) could do that too.
> > >>
> > >
> > > Yeah... I had briefly thought about it and I had discarded it
> > > because DBUnit
> > > is about testing... but why not...
> > >
> > >
> > >>> 3- start/stop database (database dependent)
> > >>> 4- create db instance (database dependent and not always
> > >>> scriptable I
> > >>> guess)
> > >>>
> > >>
> > >> IMHO the 3 and 4 are maybe the more difficult points.
> > >>
> > >
> > > Yep
> > >
> > >
> > >> Maybe, it is possible to create a wrapper, something like Cargo.
> > >>
> > >
> > > Exactly my thought except I don't have the time to work on this as a
> > > standalone project! So either it exists or we can simply have
> > > extension
> > > points in the db plugin to plugin database-specific behaviors.
> > >
> > >
> > >>> Would someone know a Java framework for manipulating databases
> > >>> and that
> > >>> could be wrapped in a m2 plugin easily?
> > >>>
> > >>> I was thinking about DDLUtils (http://db.apache.org/ddlutils/) but I
> > >>>
> > >> have
> > >>
> > >>> no
> > >>> experience with it and I don't know how solid it is. Also it
> > >>> won't do
> > >>> points
> > >>> 3 and 4 above.
> > >>>
> > >>
> > >> Have a look to Ibatis project too.
> > >>
> > >
> > > I thought that IBatis was an O/R mapping framework in the same
> > > league as
> > > Hibernate and others... Does it offer features for features 3 and
> > > 4? I don't
> > > think so. Do you know what it would offer over DDLUtils for
> > > features 1 and
> > > 2?
> > >
> > > Thanks
> > > -Vincent
> > >
> > >
> > > ---------------------------------------------------------------------
> > > To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> > > For additional commands, e-mail: dev-help@maven.apache.org
> > >
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> > For additional commands, e-mail: dev-help@maven.apache.org
> >
> >
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> For additional commands, e-mail: dev-help@maven.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


Re: [M2] Database plugin?

Posted by Mark Hobson <ma...@gmail.com>.
It's also worth noting how ORM solutions can affect points (1) & (2). 
For example, Hibernate normally creates and executes the db script for
(1) - this is currently provided by the hibernate2/3 m2 plugin goals.

Regarding (2) with Hibernate, it normally makes sense to load data
using the objects themselves, since they are the native database
language in ORMs as opposed to SQL.  I did look for support for this
in DBUnit but couldn't find any.

So any generic solution would need to keep these points in mind.  I
certainly think there's a need for something like this as it would
eliminate proprietary db/orm plugins - almost Cargo for db's.. ;)

Mark

On 24/10/05, Eric Pugh <ep...@upstate.com> wrote:
> While DBUnit IS about testing, I think that maybe the most common use
> case for DBUnit isn't about testing datasets, but using it to load
> test data up, which revolves around #2 on your list!
>
> I've thought about pulling out some sort of core part of DBUnit to be
> called DBLoader or something....
>
> Eric
> On Oct 22, 2005, at 1:05 PM, Vincent Massol wrote:
>
> >
> >
> >
> >> -----Original Message-----
> >> From: Vincent Siveton [mailto:vincent.siveton@gmail.com]
> >> Sent: samedi 22 octobre 2005 17:04
> >> To: 'Maven Developers List'
> >> Subject: RE: [M2] Database plugin?
> >>
> >> Hi Vincent,
> >>
> >>
> >>> I'm looking for a m2 db plugin. Anyone working on one?
> >>>
> >>
> >> Good idea!
> >>
> >>
> >>> I'm currently working with Derby but ideally this plugin should
> >>> probably
> >>> be
> >>> generic (with extensions) and allow to do things like:
> >>>
> >>> 1- create schema
> >>> 2- load data in database
> >>>
> >>
> >> Dbunit (as you know) could do that too.
> >>
> >
> > Yeah... I had briefly thought about it and I had discarded it
> > because DBUnit
> > is about testing... but why not...
> >
> >
> >>> 3- start/stop database (database dependent)
> >>> 4- create db instance (database dependent and not always
> >>> scriptable I
> >>> guess)
> >>>
> >>
> >> IMHO the 3 and 4 are maybe the more difficult points.
> >>
> >
> > Yep
> >
> >
> >> Maybe, it is possible to create a wrapper, something like Cargo.
> >>
> >
> > Exactly my thought except I don't have the time to work on this as a
> > standalone project! So either it exists or we can simply have
> > extension
> > points in the db plugin to plugin database-specific behaviors.
> >
> >
> >>> Would someone know a Java framework for manipulating databases
> >>> and that
> >>> could be wrapped in a m2 plugin easily?
> >>>
> >>> I was thinking about DDLUtils (http://db.apache.org/ddlutils/) but I
> >>>
> >> have
> >>
> >>> no
> >>> experience with it and I don't know how solid it is. Also it
> >>> won't do
> >>> points
> >>> 3 and 4 above.
> >>>
> >>
> >> Have a look to Ibatis project too.
> >>
> >
> > I thought that IBatis was an O/R mapping framework in the same
> > league as
> > Hibernate and others... Does it offer features for features 3 and
> > 4? I don't
> > think so. Do you know what it would offer over DDLUtils for
> > features 1 and
> > 2?
> >
> > Thanks
> > -Vincent
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> > For additional commands, e-mail: dev-help@maven.apache.org
> >
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> For additional commands, e-mail: dev-help@maven.apache.org
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


RE: [M2] Database plugin?

Posted by Vincent Massol <vm...@pivolis.com>.
Hi Eric,

> -----Original Message-----
> From: Eric Pugh [mailto:epugh@upstate.com]
> Sent: lundi 24 octobre 2005 06:35
> To: Maven Developers List
> Subject: Re: [M2] Database plugin?
> 
> While DBUnit IS about testing, I think that maybe the most common use
> case for DBUnit isn't about testing datasets, but using it to load
> test data up, which revolves around #2 on your list!

Thanks for the precision. Actually I've used DBUnit in the past for doing
exactly this!
 
> I've thought about pulling out some sort of core part of DBUnit to be
> called DBLoader or something....

That would be a good idea I think.

Thanks
-Vincent

> >> -----Original Message-----
> >> From: Vincent Siveton [mailto:vincent.siveton@gmail.com]
> >> Sent: samedi 22 octobre 2005 17:04
> >> To: 'Maven Developers List'
> >> Subject: RE: [M2] Database plugin?
> >>
> >> Hi Vincent,
> >>
> >>
> >>> I'm looking for a m2 db plugin. Anyone working on one?
> >>>
> >>
> >> Good idea!
> >>
> >>
> >>> I'm currently working with Derby but ideally this plugin should
> >>> probably
> >>> be
> >>> generic (with extensions) and allow to do things like:
> >>>
> >>> 1- create schema
> >>> 2- load data in database
> >>>
> >>
> >> Dbunit (as you know) could do that too.
> >>
> >
> > Yeah... I had briefly thought about it and I had discarded it
> > because DBUnit
> > is about testing... but why not...
> >
> >
> >>> 3- start/stop database (database dependent)
> >>> 4- create db instance (database dependent and not always
> >>> scriptable I
> >>> guess)
> >>>
> >>
> >> IMHO the 3 and 4 are maybe the more difficult points.
> >>
> >
> > Yep
> >
> >
> >> Maybe, it is possible to create a wrapper, something like Cargo.
> >>
> >
> > Exactly my thought except I don't have the time to work on this as a
> > standalone project! So either it exists or we can simply have
> > extension
> > points in the db plugin to plugin database-specific behaviors.
> >
> >
> >>> Would someone know a Java framework for manipulating databases
> >>> and that
> >>> could be wrapped in a m2 plugin easily?
> >>>
> >>> I was thinking about DDLUtils (http://db.apache.org/ddlutils/) but I
> >>>
> >> have
> >>
> >>> no
> >>> experience with it and I don't know how solid it is. Also it
> >>> won't do
> >>> points
> >>> 3 and 4 above.
> >>>
> >>
> >> Have a look to Ibatis project too.
> >>
> >
> > I thought that IBatis was an O/R mapping framework in the same
> > league as
> > Hibernate and others... Does it offer features for features 3 and
> > 4? I don't
> > think so. Do you know what it would offer over DDLUtils for
> > features 1 and
> > 2?
> >
> > Thanks
> > -Vincent
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> > For additional commands, e-mail: dev-help@maven.apache.org
> >
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> For additional commands, e-mail: dev-help@maven.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


Re: [M2] Database plugin?

Posted by Eric Pugh <ep...@upstate.com>.
While DBUnit IS about testing, I think that maybe the most common use  
case for DBUnit isn't about testing datasets, but using it to load  
test data up, which revolves around #2 on your list!

I've thought about pulling out some sort of core part of DBUnit to be  
called DBLoader or something....

Eric
On Oct 22, 2005, at 1:05 PM, Vincent Massol wrote:

>
>
>
>> -----Original Message-----
>> From: Vincent Siveton [mailto:vincent.siveton@gmail.com]
>> Sent: samedi 22 octobre 2005 17:04
>> To: 'Maven Developers List'
>> Subject: RE: [M2] Database plugin?
>>
>> Hi Vincent,
>>
>>
>>> I'm looking for a m2 db plugin. Anyone working on one?
>>>
>>
>> Good idea!
>>
>>
>>> I'm currently working with Derby but ideally this plugin should  
>>> probably
>>> be
>>> generic (with extensions) and allow to do things like:
>>>
>>> 1- create schema
>>> 2- load data in database
>>>
>>
>> Dbunit (as you know) could do that too.
>>
>
> Yeah... I had briefly thought about it and I had discarded it  
> because DBUnit
> is about testing... but why not...
>
>
>>> 3- start/stop database (database dependent)
>>> 4- create db instance (database dependent and not always  
>>> scriptable I
>>> guess)
>>>
>>
>> IMHO the 3 and 4 are maybe the more difficult points.
>>
>
> Yep
>
>
>> Maybe, it is possible to create a wrapper, something like Cargo.
>>
>
> Exactly my thought except I don't have the time to work on this as a
> standalone project! So either it exists or we can simply have  
> extension
> points in the db plugin to plugin database-specific behaviors.
>
>
>>> Would someone know a Java framework for manipulating databases  
>>> and that
>>> could be wrapped in a m2 plugin easily?
>>>
>>> I was thinking about DDLUtils (http://db.apache.org/ddlutils/) but I
>>>
>> have
>>
>>> no
>>> experience with it and I don't know how solid it is. Also it  
>>> won't do
>>> points
>>> 3 and 4 above.
>>>
>>
>> Have a look to Ibatis project too.
>>
>
> I thought that IBatis was an O/R mapping framework in the same  
> league as
> Hibernate and others... Does it offer features for features 3 and  
> 4? I don't
> think so. Do you know what it would offer over DDLUtils for  
> features 1 and
> 2?
>
> Thanks
> -Vincent
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> For additional commands, e-mail: dev-help@maven.apache.org
>


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


RE: [M2] Database plugin?

Posted by Vincent Massol <vm...@pivolis.com>.

> -----Original Message-----
> From: Vincent Siveton [mailto:vincent.siveton@gmail.com]
> Sent: samedi 22 octobre 2005 17:04
> To: 'Maven Developers List'
> Subject: RE: [M2] Database plugin?
> 
> Hi Vincent,
> 
> > I'm looking for a m2 db plugin. Anyone working on one?
> 
> Good idea!
> 
> > I'm currently working with Derby but ideally this plugin should probably
> > be
> > generic (with extensions) and allow to do things like:
> >
> > 1- create schema
> > 2- load data in database
> 
> Dbunit (as you know) could do that too.

Yeah... I had briefly thought about it and I had discarded it because DBUnit
is about testing... but why not...
 
> > 3- start/stop database (database dependent)
> > 4- create db instance (database dependent and not always scriptable I
> > guess)
> 
> IMHO the 3 and 4 are maybe the more difficult points.

Yep

> Maybe, it is possible to create a wrapper, something like Cargo.

Exactly my thought except I don't have the time to work on this as a
standalone project! So either it exists or we can simply have extension
points in the db plugin to plugin database-specific behaviors.
 
> > Would someone know a Java framework for manipulating databases and that
> > could be wrapped in a m2 plugin easily?
> >
> > I was thinking about DDLUtils (http://db.apache.org/ddlutils/) but I
> have
> > no
> > experience with it and I don't know how solid it is. Also it won't do
> > points
> > 3 and 4 above.
> 
> Have a look to Ibatis project too.

I thought that IBatis was an O/R mapping framework in the same league as
Hibernate and others... Does it offer features for features 3 and 4? I don't
think so. Do you know what it would offer over DDLUtils for features 1 and
2?

Thanks
-Vincent


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


RE: [M2] Database plugin?

Posted by Vincent Siveton <vi...@gmail.com>.
Hi Vincent,

> I'm looking for a m2 db plugin. Anyone working on one?

Good idea!

> I'm currently working with Derby but ideally this plugin should probably
> be
> generic (with extensions) and allow to do things like:
> 
> 1- create schema
> 2- load data in database

Dbunit (as you know) could do that too.

> 3- start/stop database (database dependent)
> 4- create db instance (database dependent and not always scriptable I
> guess)

IMHO the 3 and 4 are maybe the more difficult points. 
Maybe, it is possible to create a wrapper, something like Cargo.

> Would someone know a Java framework for manipulating databases and that
> could be wrapped in a m2 plugin easily?
> 
> I was thinking about DDLUtils (http://db.apache.org/ddlutils/) but I have
> no
> experience with it and I don't know how solid it is. Also it won't do
> points
> 3 and 4 above. 

Have a look to Ibatis project too.

Cheers,

Vincent


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org