[aerogear-dev] database migration

classic Classic list List threaded Threaded
14 messages Options
Reply | Threaded
Open this post in threaded view
|

[aerogear-dev] database migration

Erik Jan de Wit
Hi,

Now that we have 2 versions out of the door, when we change stuff we need an easy upgrade path. Not only for the API but also for the database. Because we support a couple of them having something of a process would help.

I’ve have used liquibase in the past. You write ‘change sets’ in yaml, json or if you must in xml, it will create a migration table in the database and execute the changes needed to bring it up to date or you can create a sql script that will do the same. Cool thing about this approach is that it’s independent of the database


Another tool I’ve heard about, but also promising is Flyway. It’s supports writing migrations in sql and java comes with it’s own java api. Basically the same idea with regards to this migration table, but here you need to specify your own sql scripts. Or you can write migrations in java where having special named java class gets executed to update/migrate the data.


WDYT?

Cheers,
Erik Jan


_______________________________________________
aerogear-dev mailing list
[hidden email]
https://lists.jboss.org/mailman/listinfo/aerogear-dev
Reply | Threaded
Open this post in threaded view
|

Re: [aerogear-dev] database migration

Stian Thorgersen
We're looking at this for Keycloak atm as well, and those where the two that stood out at first glance. I haven't looked in depth or tried them out yet though.

----- Original Message -----

> From: "Erik Jan de Wit" <[hidden email]>
> To: "AeroGear Developer Mailing List" <[hidden email]>
> Sent: Monday, 6 October, 2014 5:48:53 PM
> Subject: [aerogear-dev] database migration
>
> Hi,
>
> Now that we have 2 versions out of the door, when we change stuff we need an
> easy upgrade path. Not only for the API but also for the database. Because
> we support a couple of them having something of a process would help.
>
> I’ve have used liquibase in the past. You write ‘change sets’ in yaml, json
> or if you must in xml, it will create a migration table in the database and
> execute the changes needed to bring it up to date or you can create a sql
> script that will do the same. Cool thing about this approach is that it’s
> independent of the database
>
> http://www.liquibase.org
>
> Another tool I’ve heard about, but also promising is Flyway. It’s supports
> writing migrations in sql and java comes with it’s own java api. Basically
> the same idea with regards to this migration table, but here you need to
> specify your own sql scripts. Or you can write migrations in java where
> having special named java class gets executed to update/migrate the data.
>
> http://flywaydb.org
>
> WDYT?
>
> Cheers,
> Erik Jan
>
>
> _______________________________________________
> aerogear-dev mailing list
> [hidden email]
> https://lists.jboss.org/mailman/listinfo/aerogear-dev

_______________________________________________
aerogear-dev mailing list
[hidden email]
https://lists.jboss.org/mailman/listinfo/aerogear-dev
Reply | Threaded
Open this post in threaded view
|

Re: [aerogear-dev] database migration

Daniel Passos-2
I've never played with liquibase. but +1 for start using migrations

-- Passos

On Mon, Oct 6, 2014 at 2:24 PM, Stian Thorgersen <[hidden email]> wrote:
We're looking at this for Keycloak atm as well, and those where the two that stood out at first glance. I haven't looked in depth or tried them out yet though.

----- Original Message -----
> From: "Erik Jan de Wit" <[hidden email]>
> To: "AeroGear Developer Mailing List" <[hidden email]>
> Sent: Monday, 6 October, 2014 5:48:53 PM
> Subject: [aerogear-dev] database migration
>
> Hi,
>
> Now that we have 2 versions out of the door, when we change stuff we need an
> easy upgrade path. Not only for the API but also for the database. Because
> we support a couple of them having something of a process would help.
>
> I’ve have used liquibase in the past. You write ‘change sets’ in yaml, json
> or if you must in xml, it will create a migration table in the database and
> execute the changes needed to bring it up to date or you can create a sql
> script that will do the same. Cool thing about this approach is that it’s
> independent of the database
>
> http://www.liquibase.org
>
> Another tool I’ve heard about, but also promising is Flyway. It’s supports
> writing migrations in sql and java comes with it’s own java api. Basically
> the same idea with regards to this migration table, but here you need to
> specify your own sql scripts. Or you can write migrations in java where
> having special named java class gets executed to update/migrate the data.
>
> http://flywaydb.org
>
> WDYT?
>
> Cheers,
> Erik Jan
>
>
> _______________________________________________
> aerogear-dev mailing list
> [hidden email]
> https://lists.jboss.org/mailman/listinfo/aerogear-dev

_______________________________________________
aerogear-dev mailing list
[hidden email]
https://lists.jboss.org/mailman/listinfo/aerogear-dev


_______________________________________________
aerogear-dev mailing list
[hidden email]
https://lists.jboss.org/mailman/listinfo/aerogear-dev
Reply | Threaded
Open this post in threaded view
|

Re: [aerogear-dev] database migration

cvasilak
In reply to this post by Erik Jan de Wit
sounds reasonable and if it eases the pain I am +1 on it.

let me know how can I help on it.


-
Christos

On Oct 6, 2014, at 6:48 PM, Erik Jan de Wit <[hidden email]> wrote:

Hi,

Now that we have 2 versions out of the door, when we change stuff we need an easy upgrade path. Not only for the API but also for the database. Because we support a couple of them having something of a process would help.

I’ve have used liquibase in the past. You write ‘change sets’ in yaml, json or if you must in xml, it will create a migration table in the database and execute the changes needed to bring it up to date or you can create a sql script that will do the same. Cool thing about this approach is that it’s independent of the database


Another tool I’ve heard about, but also promising is Flyway. It’s supports writing migrations in sql and java comes with it’s own java api. Basically the same idea with regards to this migration table, but here you need to specify your own sql scripts. Or you can write migrations in java where having special named java class gets executed to update/migrate the data.


WDYT?

Cheers,
Erik Jan

_______________________________________________
aerogear-dev mailing list
[hidden email]
https://lists.jboss.org/mailman/listinfo/aerogear-dev


_______________________________________________
aerogear-dev mailing list
[hidden email]
https://lists.jboss.org/mailman/listinfo/aerogear-dev
Reply | Threaded
Open this post in threaded view
|

Re: [aerogear-dev] database migration

danielbevenius
+1 Sounds good to me.

On 7 October 2014 08:32, Christos Vasilakis <[hidden email]> wrote:
sounds reasonable and if it eases the pain I am +1 on it.

let me know how can I help on it.


-
Christos

On Oct 6, 2014, at 6:48 PM, Erik Jan de Wit <[hidden email]> wrote:

Hi,

Now that we have 2 versions out of the door, when we change stuff we need an easy upgrade path. Not only for the API but also for the database. Because we support a couple of them having something of a process would help.

I’ve have used liquibase in the past. You write ‘change sets’ in yaml, json or if you must in xml, it will create a migration table in the database and execute the changes needed to bring it up to date or you can create a sql script that will do the same. Cool thing about this approach is that it’s independent of the database


Another tool I’ve heard about, but also promising is Flyway. It’s supports writing migrations in sql and java comes with it’s own java api. Basically the same idea with regards to this migration table, but here you need to specify your own sql scripts. Or you can write migrations in java where having special named java class gets executed to update/migrate the data.


WDYT?

Cheers,
Erik Jan

_______________________________________________
aerogear-dev mailing list
[hidden email]
https://lists.jboss.org/mailman/listinfo/aerogear-dev


_______________________________________________
aerogear-dev mailing list
[hidden email]
https://lists.jboss.org/mailman/listinfo/aerogear-dev


_______________________________________________
aerogear-dev mailing list
[hidden email]
https://lists.jboss.org/mailman/listinfo/aerogear-dev
Reply | Threaded
Open this post in threaded view
|

Re: [aerogear-dev] database migration

Matthias Wessendorf
In reply to this post by Erik Jan de Wit
I have heard about FlywayDB, but from your email liquibase sounds like a good idea!

Thanks for sharing, Erik!

On Mon, Oct 6, 2014 at 5:48 PM, Erik Jan de Wit <[hidden email]> wrote:
Hi,

Now that we have 2 versions out of the door, when we change stuff we need an easy upgrade path. Not only for the API but also for the database. Because we support a couple of them having something of a process would help.

I’ve have used liquibase in the past. You write ‘change sets’ in yaml, json or if you must in xml, it will create a migration table in the database and execute the changes needed to bring it up to date or you can create a sql script that will do the same. Cool thing about this approach is that it’s independent of the database


Another tool I’ve heard about, but also promising is Flyway. It’s supports writing migrations in sql and java comes with it’s own java api. Basically the same idea with regards to this migration table, but here you need to specify your own sql scripts. Or you can write migrations in java where having special named java class gets executed to update/migrate the data.


WDYT?

Cheers,
Erik Jan


_______________________________________________
aerogear-dev mailing list
[hidden email]
https://lists.jboss.org/mailman/listinfo/aerogear-dev



--
Matthias Wessendorf

blog: http://matthiaswessendorf.wordpress.com/
sessions: http://www.slideshare.net/mwessendorf
twitter: http://twitter.com/mwessendorf

_______________________________________________
aerogear-dev mailing list
[hidden email]
https://lists.jboss.org/mailman/listinfo/aerogear-dev
Reply | Threaded
Open this post in threaded view
|

Re: [aerogear-dev] database migration

Stian Thorgersen
I've been playing with Liquibase now and it's awesome!

That's what I'd like to use for Keycloak, but I'd also like to use the same as you guys do.

----- Original Message -----

> From: "Matthias Wessendorf" <[hidden email]>
> To: "AeroGear Developer Mailing List" <[hidden email]>
> Sent: Tuesday, 7 October, 2014 9:27:45 AM
> Subject: Re: [aerogear-dev] database migration
>
> I have heard about FlywayDB, but from your email liquibase sounds like a good
> idea!
>
> Thanks for sharing, Erik!
>
> On Mon, Oct 6, 2014 at 5:48 PM, Erik Jan de Wit < [hidden email] > wrote:
>
>
>
> Hi,
>
> Now that we have 2 versions out of the door, when we change stuff we need an
> easy upgrade path. Not only for the API but also for the database. Because
> we support a couple of them having something of a process would help.
>
> I’ve have used liquibase in the past. You write ‘change sets’ in yaml, json
> or if you must in xml, it will create a migration table in the database and
> execute the changes needed to bring it up to date or you can create a sql
> script that will do the same. Cool thing about this approach is that it’s
> independent of the database
>
> http://www.liquibase.org
>
> Another tool I’ve heard about, but also promising is Flyway. It’s supports
> writing migrations in sql and java comes with it’s own java api. Basically
> the same idea with regards to this migration table, but here you need to
> specify your own sql scripts. Or you can write migrations in java where
> having special named java class gets executed to update/migrate the data.
>
> http://flywaydb.org
>
> WDYT?
>
> Cheers,
> Erik Jan
>
>
> _______________________________________________
> aerogear-dev mailing list
> [hidden email]
> https://lists.jboss.org/mailman/listinfo/aerogear-dev
>
>
>
> --
> Matthias Wessendorf
>
> blog: http://matthiaswessendorf.wordpress.com/
> sessions: http://www.slideshare.net/mwessendorf
> twitter: http://twitter.com/mwessendorf
>
> _______________________________________________
> aerogear-dev mailing list
> [hidden email]
> https://lists.jboss.org/mailman/listinfo/aerogear-dev

_______________________________________________
aerogear-dev mailing list
[hidden email]
https://lists.jboss.org/mailman/listinfo/aerogear-dev
Reply | Threaded
Open this post in threaded view
|

Re: [aerogear-dev] database migration

Matthias Wessendorf


On Tuesday, October 7, 2014, Stian Thorgersen <[hidden email]> wrote:
I've been playing with Liquibase now and it's awesome!

That's what I'd like to use for Keycloak, but I'd also like to use the same as you guys do.

yes! would be great uf our projects use the same. 

looks like Liquibase is the way to go?
 

----- Original Message -----
> From: "Matthias Wessendorf" <<a href="javascript:;" onclick="_e(event, &#39;cvml&#39;, &#39;matzew@apache.org&#39;)">matzew@...>
> To: "AeroGear Developer Mailing List" <<a href="javascript:;" onclick="_e(event, &#39;cvml&#39;, &#39;aerogear-dev@lists.jboss.org&#39;)">aerogear-dev@...>
> Sent: Tuesday, 7 October, 2014 9:27:45 AM
> Subject: Re: [aerogear-dev] database migration
>
> I have heard about FlywayDB, but from your email liquibase sounds like a good
> idea!
>
> Thanks for sharing, Erik!
>
> On Mon, Oct 6, 2014 at 5:48 PM, Erik Jan de Wit < <a href="javascript:;" onclick="_e(event, &#39;cvml&#39;, &#39;edewit@redhat.com&#39;)">edewit@... > wrote:
>
>
>
> Hi,
>
> Now that we have 2 versions out of the door, when we change stuff we need an
> easy upgrade path. Not only for the API but also for the database. Because
> we support a couple of them having something of a process would help.
>
> I’ve have used liquibase in the past. You write ‘change sets’ in yaml, json
> or if you must in xml, it will create a migration table in the database and
> execute the changes needed to bring it up to date or you can create a sql
> script that will do the same. Cool thing about this approach is that it’s
> independent of the database
>
> http://www.liquibase.org
>
> Another tool I’ve heard about, but also promising is Flyway. It’s supports
> writing migrations in sql and java comes with it’s own java api. Basically
> the same idea with regards to this migration table, but here you need to
> specify your own sql scripts. Or you can write migrations in java where
> having special named java class gets executed to update/migrate the data.
>
> http://flywaydb.org
>
> WDYT?
>
> Cheers,
> Erik Jan
>
>
> _______________________________________________
> aerogear-dev mailing list
> <a href="javascript:;" onclick="_e(event, &#39;cvml&#39;, &#39;aerogear-dev@lists.jboss.org&#39;)">aerogear-dev@...
> https://lists.jboss.org/mailman/listinfo/aerogear-dev
>
>
>
> --
> Matthias Wessendorf
>
> blog: http://matthiaswessendorf.wordpress.com/
> sessions: http://www.slideshare.net/mwessendorf
> twitter: http://twitter.com/mwessendorf
>
> _______________________________________________
> aerogear-dev mailing list
> <a href="javascript:;" onclick="_e(event, &#39;cvml&#39;, &#39;aerogear-dev@lists.jboss.org&#39;)">aerogear-dev@...
> https://lists.jboss.org/mailman/listinfo/aerogear-dev

_______________________________________________
aerogear-dev mailing list
<a href="javascript:;" onclick="_e(event, &#39;cvml&#39;, &#39;aerogear-dev@lists.jboss.org&#39;)">aerogear-dev@...
https://lists.jboss.org/mailman/listinfo/aerogear-dev


--
Sent from Gmail Mobile

_______________________________________________
aerogear-dev mailing list
[hidden email]
https://lists.jboss.org/mailman/listinfo/aerogear-dev
Reply | Threaded
Open this post in threaded view
|

Re: [aerogear-dev] database migration

Stian Thorgersen


----- Original Message -----

> From: "Matthias Wessendorf" <[hidden email]>
> To: "AeroGear Developer Mailing List" <[hidden email]>
> Sent: Tuesday, 7 October, 2014 10:58:41 AM
> Subject: Re: [aerogear-dev] database migration
>
>
>
> On Tuesday, October 7, 2014, Stian Thorgersen < [hidden email] > wrote:
>
>
> I've been playing with Liquibase now and it's awesome!
>
> That's what I'd like to use for Keycloak, but I'd also like to use the same
> as you guys do.
>
> yes! would be great uf our projects use the same.
>
> looks like Liquibase is the way to go?

+1

FlywayDB uses SQL directly, so we have to deal with differences between databases ourselves. IMO that renders it useless!

>
>
>
> ----- Original Message -----
> > From: "Matthias Wessendorf" < [hidden email] >
> > To: "AeroGear Developer Mailing List" < [hidden email] >
> > Sent: Tuesday, 7 October, 2014 9:27:45 AM
> > Subject: Re: [aerogear-dev] database migration
> >
> > I have heard about FlywayDB, but from your email liquibase sounds like a
> > good
> > idea!
> >
> > Thanks for sharing, Erik!
> >
> > On Mon, Oct 6, 2014 at 5:48 PM, Erik Jan de Wit < [hidden email] >
> > wrote:
> >
> >
> >
> > Hi,
> >
> > Now that we have 2 versions out of the door, when we change stuff we need
> > an
> > easy upgrade path. Not only for the API but also for the database. Because
> > we support a couple of them having something of a process would help.
> >
> > I’ve have used liquibase in the past. You write ‘change sets’ in yaml, json
> > or if you must in xml, it will create a migration table in the database and
> > execute the changes needed to bring it up to date or you can create a sql
> > script that will do the same. Cool thing about this approach is that it’s
> > independent of the database
> >
> > http://www.liquibase.org
> >
> > Another tool I’ve heard about, but also promising is Flyway. It’s supports
> > writing migrations in sql and java comes with it’s own java api. Basically
> > the same idea with regards to this migration table, but here you need to
> > specify your own sql scripts. Or you can write migrations in java where
> > having special named java class gets executed to update/migrate the data.
> >
> > http://flywaydb.org
> >
> > WDYT?
> >
> > Cheers,
> > Erik Jan
> >
> >
> > _______________________________________________
> > aerogear-dev mailing list
> > [hidden email]
> > https://lists.jboss.org/mailman/listinfo/aerogear-dev
> >
> >
> >
> > --
> > Matthias Wessendorf
> >
> > blog: http://matthiaswessendorf.wordpress.com/
> > sessions: http://www.slideshare.net/mwessendorf
> > twitter: http://twitter.com/mwessendorf
> >
> > _______________________________________________
> > aerogear-dev mailing list
> > [hidden email]
> > https://lists.jboss.org/mailman/listinfo/aerogear-dev
>
> _______________________________________________
> aerogear-dev mailing list
> [hidden email]
> https://lists.jboss.org/mailman/listinfo/aerogear-dev
>
> --
> Sent from Gmail Mobile
>
> _______________________________________________
> aerogear-dev mailing list
> [hidden email]
> https://lists.jboss.org/mailman/listinfo/aerogear-dev

_______________________________________________
aerogear-dev mailing list
[hidden email]
https://lists.jboss.org/mailman/listinfo/aerogear-dev
Reply | Threaded
Open this post in threaded view
|

Re: [aerogear-dev] database migration

Erik Jan de Wit

looks like Liquibase is the way to go?

+1

FlywayDB uses SQL directly, so we have to deal with differences between databases ourselves. IMO that renders it useless!

liquibase it is, and let’s not use xml for the change sets ;)

_______________________________________________
aerogear-dev mailing list
[hidden email]
https://lists.jboss.org/mailman/listinfo/aerogear-dev
Reply | Threaded
Open this post in threaded view
|

Re: [aerogear-dev] database migration

Stian Thorgersen


----- Original Message -----

> From: "Erik Jan de Wit" <[hidden email]>
> To: "AeroGear Developer Mailing List" <[hidden email]>
> Sent: Tuesday, 7 October, 2014 3:02:59 PM
> Subject: Re: [aerogear-dev] database migration
>
>
>
>
>
>
>
> looks like Liquibase is the way to go?
>
> +1
>
> FlywayDB uses SQL directly, so we have to deal with differences between
> databases ourselves. IMO that renders it useless!
>
> liquibase it is, and let’s not use xml for the change sets ;)

Why not XML?

>
> _______________________________________________
> aerogear-dev mailing list
> [hidden email]
> https://lists.jboss.org/mailman/listinfo/aerogear-dev

_______________________________________________
aerogear-dev mailing list
[hidden email]
https://lists.jboss.org/mailman/listinfo/aerogear-dev
Reply | Threaded
Open this post in threaded view
|

Re: [aerogear-dev] database migration

Erik Jan de Wit
On 7 Oct,2014, at 15:11 , Stian Thorgersen <[hidden email]> wrote:

>> FlywayDB uses SQL directly, so we have to deal with differences between
>> databases ourselves. IMO that renders it useless!
>>
>> liquibase it is, and let’s not use xml for the change sets ;)
>
> Why not XML?
>

We hate XML


_______________________________________________
aerogear-dev mailing list
[hidden email]
https://lists.jboss.org/mailman/listinfo/aerogear-dev
qmx
Reply | Threaded
Open this post in threaded view
|

Re: [aerogear-dev] database migration

qmx
Administrator
On Tue, Oct 07, 2014 at 03:20:19PM +0200, Erik Jan de Wit wrote:

> On 7 Oct,2014, at 15:11 , Stian Thorgersen <[hidden email]> wrote:
>
> >> FlywayDB uses SQL directly, so we have to deal with differences between
> >> databases ourselves. IMO that renders it useless!
> >>
> >> liquibase it is, and let’s not use xml for the change sets ;)
> >
> > Why not XML?
> >
>
> We hate XML
While I do hate XML too, in this case their xsd's are kickass on
validating stuff for us. (happy liquibase user here too)

I'd say "embrace the darkness^H^H^HXML unless we have a huge reason to
avoid it.

--
qmx
_______________________________________________
aerogear-dev mailing list
[hidden email]
https://lists.jboss.org/mailman/listinfo/aerogear-dev
Reply | Threaded
Open this post in threaded view
|

Re: [aerogear-dev] database migration

Luke Holmquist

> On Oct 13, 2014, at 12:31 AM, Douglas Campos <[hidden email]> wrote:
>
> On Tue, Oct 07, 2014 at 03:20:19PM +0200, Erik Jan de Wit wrote:
>> On 7 Oct,2014, at 15:11 , Stian Thorgersen <[hidden email]> wrote:
>>
>>>> FlywayDB uses SQL directly, so we have to deal with differences between
>>>> databases ourselves. IMO that renders it useless!
>>>>
>>>> liquibase it is, and let’s not use xml for the change sets ;)
>>>
>>> Why not XML?
>>>
>>
>> We hate XML
> While I do hate XML too, in this case their xsd's are kickass on
> validating stuff for us. (happy liquibase user here too)
>
> I'd say "embrace the darkness^H^H^HXML unless we have a huge reason to
> avoid it.
This reminds me of Luke asking Yoda if the Dark is Stronger.

“NO!,  quicker, more seductive"


>
> --
> qmx
> _______________________________________________
> aerogear-dev mailing list
> [hidden email]
> https://lists.jboss.org/mailman/listinfo/aerogear-dev


_______________________________________________
aerogear-dev mailing list
[hidden email]
https://lists.jboss.org/mailman/listinfo/aerogear-dev