Different set of databases?

Forum to discuss the new web client version of Servoy.

Different set of databases?

Postby rieder » Thu Nov 10, 2016 1:01 pm

Hi

In the Servoy Wiki Documentation about WAR deployment, I read

make sure each Servoy Application Server ... use a different set of databases


Can someone please explain to me, what this means and why?

I assume, two WARs should not use the same database. But we do have two applications, which read and write to the same database. But the two applications write to a different set of tables. One application fills valuelist tables and reads from those tables, the other application writes to. Will we run into problems? Why?

Thanks for any help and kind regards
Birgit Rieder
7r AG, Switzerland
SAN Developer
http://www.seven-r.ch
User avatar
rieder
 
Posts: 177
Joined: Thu Jan 26, 2012 5:18 pm

Re: Different set of databases?

Postby ROCLASI » Thu Nov 10, 2016 6:43 pm

Hi Birgit,

As far I can tell there are 2 reasons for this:

  • You use Servoy Sequences and these are managed by the Servoy Server instance, so 2 (or more) Servoy Server instances will cause new PK values (eventually) to collide.
    Of course when you don't use Servoy Sequences but UUID's or let the database handle the sequences you should be fine.
  • Servoy server does a lot of caching of data it already fetched from the database, and when you manually (or by another Servoy instance) add/update/delete any of this data then the other instance(s) will not see it without some way of broadcasting this change. Now if you use a single DB and your data is partitioned in some way (for example using a tenant ID) and each instance will never access the other instance's data then you don't have any issues.
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: Different set of databases?

Postby rieder » Fri Nov 11, 2016 9:21 am

Dear Robert

Thank you for the answer. So you say, if we are aware of the fact, that two Servoy application servers do not know of each others sequences, and that data broadcasting is not possible, we'll not run into problems. Everything else will just work fine. That's good to hear.

Thank you and best regards
Birgit Rieder
7r AG, Switzerland
SAN Developer
http://www.seven-r.ch
User avatar
rieder
 
Posts: 177
Joined: Thu Jan 26, 2012 5:18 pm

Re: Different set of databases?

Postby ROCLASI » Fri Nov 11, 2016 12:10 pm

Hi Birgit,

If you are not inserting new records in the same table that the other instance is inserting records into (when using Servoy sequences) then yes, you should be fine.
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: Different set of databases?

Postby rieder » Sat Nov 12, 2016 11:23 am

Thank you, Robert, for clarifying this.
Best regards
Birgit Rieder
7r AG, Switzerland
SAN Developer
http://www.seven-r.ch
User avatar
rieder
 
Posts: 177
Joined: Thu Jan 26, 2012 5:18 pm


Return to Servoy NGClient

Who is online

Users browsing this forum: No registered users and 8 guests