Data Sync with SVN??

Questions and answers regarding the use of eclipse environment as seen in Servoy Developer

Data Sync with SVN??

Postby Kahuna » Thu May 21, 2009 12:27 pm

Hi Folks - I'm now looking at the move to SVN with ProjectLocker and Subversion and was wondering what others are doing for table and data syncing for the back-end during development?

I was thinking that hosting the Db on a remote server for access by all developers might be a solution but that just adds more wrinkles and chances for slow connections etc. Second thoughts were simply to do a SQL Dump after any structural or data changes that might effect other developers - error prone though I fear!

BTW I'm looking at going to Sybase for the back-end now too - if that might influence how we'd do this syncing.

Any feedback would be appreciated.
(Servoy Version: 6.0.7 Win XP / 7 - SQL Server 2008 R2)
Ian Cordingley (Kahuna)
Kahuna
 
Posts: 1235
Joined: Thu Oct 26, 2006 1:39 am
Location: 1/2 NE UK 1/2 Olvera Spain

Re: Data Sync with SVN??

Postby jmeunier » Thu May 21, 2009 5:57 pm

Structure changes can be made using the Problems list and/or syncing with the database information (dbi) files after an update. Any structure changes will be identified after syncing the resources file. Since the dbi file will change after SVN update (if there is a db change, that is), you can right click on Database Server and select "Synchronize with DB server information".

Data changes are a different story, if the data changes are important, a sql dump or using a shared database connection will be required. If you are using SQL Anywhere and are interesting in keeping your developers in local databases, you may look into a Mobilink syncing solution as well. Sybase Central has wizards for setting up Mobilink.

Hope this helps.

Jason
Jason Meunier
Servoy USA
jmeunier
 
Posts: 79
Joined: Tue Jan 24, 2006 11:19 pm
Location: Thousand Oaks, CA

Re: Data Sync with SVN??

Postby ROCLASI » Thu May 21, 2009 6:29 pm

Just one gotcha...
When you DO use shared connections (i.e. a single DB) then you should keep in mind that when you use Servoy Sequences you are bound to get in a world of hurt. Why?
When you work in Developer you are in fact working from your workspace and not from any repository database (local or shared). All Servoy objects live in your workspace, including the tracking of your Servoy sequences. So when you have 2 or more developers then there are 2 or more places where sequences are kept.
So for instance when you use a shared i18n database with a bunch of developers you should change that database (and your Servoy table settings) to database managed sequences or agree that always 1 specific developer makes the changes (mainly the inserts).

Hope this helps.
Robert Ivens
SAN Developer / Servoy Valued Professional / Servoy Certified Developer

ROCLASI Software Solutions / JBS Group, Partner
Mastodon: @roclasi
--
ServoyForge - Building Open Source Software.
PostgreSQL - The world's most advanced open source database.
User avatar
ROCLASI
Servoy Expert
 
Posts: 5438
Joined: Thu Oct 02, 2003 9:49 am
Location: Netherlands/Belgium

Re: Data Sync with SVN??

Postby Kahuna » Fri May 22, 2009 11:29 am

jmeunier wrote:Structure changes can be made using the Problems list and/or syncing with the database information (dbi) files after an update. Any structure changes will be identified after syncing the resources file. Since the dbi file will change after SVN update (if there is a db change, that is), you can right click on Database Server and select "Synchronize with DB server information".

Data changes are a different story, if the data changes are important, a sql dump or using a shared database connection will be required. If you are using SQL Anywhere and are interesting in keeping your developers in local databases, you may look into a Mobilink syncing solution as well. Sybase Central has wizards for setting up Mobilink.

Hope this helps.

Jason


That's kind of what I was hoping to hear Jason thanks.
(Servoy Version: 6.0.7 Win XP / 7 - SQL Server 2008 R2)
Ian Cordingley (Kahuna)
Kahuna
 
Posts: 1235
Joined: Thu Oct 26, 2006 1:39 am
Location: 1/2 NE UK 1/2 Olvera Spain

Re: Data Sync with SVN??

Postby Kahuna » Fri May 22, 2009 11:34 am

ROCLASI wrote:Just one gotcha...
When you DO use shared connections (i.e. a single DB) then you should keep in mind that when you use Servoy Sequences you are bound to get in a world of hurt. Why?
When you work in Developer you are in fact working from your workspace and not from any repository database (local or shared). All Servoy objects live in your workspace, including the tracking of your Servoy sequences. So when you have 2 or more developers then there are 2 or more places where sequences are kept.
So for instance when you use a shared i18n database with a bunch of developers you should change that database (and your Servoy table settings) to database managed sequences or agree that always 1 specific developer makes the changes (mainly the inserts).

Hope this helps.


That's actually good and bad news Robert. Good in that we can remodel our solution tables to use Db specific sequences, but bad in the fact that I had originally intended that Servoy keep the sequences so we would be truly Db Agnostic.

I think we need to reconsider this. Jasons suggestions above seem like the correct direction, where we share structural updates through SVN and regularly use SQLDump for data updates (mainly 1 developer doing data changes but more than 1 may need to generate test data for development forms etc.).

Obviously this will still entail Db managed sequences.

Cheers Guys - good feedback.
(Servoy Version: 6.0.7 Win XP / 7 - SQL Server 2008 R2)
Ian Cordingley (Kahuna)
Kahuna
 
Posts: 1235
Joined: Thu Oct 26, 2006 1:39 am
Location: 1/2 NE UK 1/2 Olvera Spain

Re: Data Sync with SVN??

Postby ROCLASI » Fri May 22, 2009 12:14 pm

Kahuna wrote:Good in that we can remodel our solution tables to use Db specific sequences...

Well if you mean with solution tables the tables in the repository then you can't. Only tables outside the Servoy repository you can refractor to use db sequences like the i18n table I mentioned.

Kahuna wrote:I think we need to reconsider this. Jasons suggestions above seem like the correct direction, where we share structural updates through SVN and regularly use SQLDump for data updates (mainly 1 developer doing data changes but more than 1 may need to generate test data for development forms etc.).

Obviously this will still entail Db managed sequences.

You can still use servoy sequences with this scenario. You just need to sync your own sequences with the database after you restored the SQL dump.
(right-click on the connection name in the 'database servers' node and select 'update servoy sequences')

Hope this helps.
Robert Ivens
SAN Developer / Servoy Valued Professional / Servoy Certified Developer

ROCLASI Software Solutions / JBS Group, Partner
Mastodon: @roclasi
--
ServoyForge - Building Open Source Software.
PostgreSQL - The world's most advanced open source database.
User avatar
ROCLASI
Servoy Expert
 
Posts: 5438
Joined: Thu Oct 02, 2003 9:49 am
Location: Netherlands/Belgium

Re: Data Sync with SVN??

Postby Kahuna » Fri May 22, 2009 12:21 pm

ROCLASI wrote:
Kahuna wrote:Good in that we can remodel our solution tables to use Db specific sequences...

Well if you mean with solution tables the tables in the repository then you can't. Only tables outside the Servoy repository you can refractor to use db sequences like the i18n table I mentioned.

Kahuna wrote:I think we need to reconsider this. Jasons suggestions above seem like the correct direction, where we share structural updates through SVN and regularly use SQLDump for data updates (mainly 1 developer doing data changes but more than 1 may need to generate test data for development forms etc.).

Obviously this will still entail Db managed sequences.

You can still use servoy sequences with this scenario. You just need to sync your own sequences with the database after you restored the SQL dump.
(right-click on the connection name in the 'database servers' node and select 'update servoy sequences')

Hope this helps.


Excellent thanks Robert - great feedback as always.
(Servoy Version: 6.0.7 Win XP / 7 - SQL Server 2008 R2)
Ian Cordingley (Kahuna)
Kahuna
 
Posts: 1235
Joined: Thu Oct 26, 2006 1:39 am
Location: 1/2 NE UK 1/2 Olvera Spain


Return to Eclipse Environment

Who is online

Users browsing this forum: No registered users and 9 guests