AMQP Databroadcaster with different databases

Questions and Answers on installation, deployment, management, locking, tranasactions of Servoy Application Server

AMQP Databroadcaster with different databases

Postby sbutler » Tue Mar 28, 2023 5:34 pm

In the docs example they show the databroadcaster being used with a load balancer and multiple servers, assumingly hosting the exact same solutions and database servers. https://wiki.servoy.com/display/DOCS/AM ... t+messages

Can it also be used to broadcast between servers with some shared and some different databases or will it throw a bunch of errors? I have 1 Servoy server with 3 DB connections, and another Servoy server with 5 DB connections. They share ONLY 1 of the connections (same connection name and database). Will the databroadcaster plugin work in the situation? Also is there a way to configure the databroadcaster to only broadcast some db connections and not all?
Scott Butler
iTech Professionals, Inc.
SAN Partner

Servoy Consulting & Development
Servoy University- Training Videos
Servoy Components- Plugins, Beans, and Web Components
Servoy Guy- Tips & Resources
ServoyForge- Open Source Components
User avatar
sbutler
Servoy Expert
 
Posts: 759
Joined: Sun Jan 08, 2006 7:15 am
Location: Cincinnati, OH

Re: AMQP Databroadcaster with different databases

Postby steve1376656734 » Tue Mar 28, 2023 7:22 pm

Hi Scott,

Based on our experience, the data broadcaster will enable both servers to get the updates for the shared DB but each server will also write an entry in the log file for each data broadcast it receives for the DBs not present on that machine. If you're happy to ignore those messages then you should be fine.

Steve
Steve
SAN Developer
There are 10 types of people in the world - those that understand binary and those that don't
steve1376656734
 
Posts: 330
Joined: Fri Aug 16, 2013 2:38 pm
Location: Ashford, UK

Re: AMQP Databroadcaster with different databases

Postby steve1376656734 » Tue Mar 28, 2023 7:25 pm

Forgot to mention:

Our scenario is slightly different to yours in that we have two different applications deployed on the same server (in different Tomcat contexts) that share a common DB and we use the RabbitMQ to data broadcast between them. Not the exact same scenario as yours but in principle it is the same because the two Tomcat contexts might as well be on different servers as far as Servoy is concerned.
Steve
SAN Developer
There are 10 types of people in the world - those that understand binary and those that don't
steve1376656734
 
Posts: 330
Joined: Fri Aug 16, 2013 2:38 pm
Location: Ashford, UK

Re: AMQP Databroadcaster with different databases

Postby jcompagner » Wed Mar 29, 2023 1:12 pm

i looked at the code a bit and i think you will be hitting this:

else
{
Debug.error("Could not find server '" + server_name + "'");
}

besides that log i think it should work fine because we don't find any clients for that server/table
Johan Compagner
Servoy
User avatar
jcompagner
 
Posts: 8833
Joined: Tue May 27, 2003 7:26 pm
Location: The Internet

Re: AMQP Databroadcaster with different databases

Postby steve1376656734 » Wed Mar 29, 2023 1:24 pm

@jcompagner

Any chance you could downgrade that message to INFO - it would help a lot with our log file analysis.
Steve
SAN Developer
There are 10 types of people in the world - those that understand binary and those that don't
steve1376656734
 
Posts: 330
Joined: Fri Aug 16, 2013 2:38 pm
Location: Ashford, UK

Re: AMQP Databroadcaster with different databases

Postby sbutler » Thu Mar 30, 2023 10:25 pm

jcompagner wrote:i looked at the code a bit and i think you will be hitting this:

else
{
Debug.error("Could not find server '" + server_name + "'");
}

besides that log i think it should work fine because we don't find any clients for that server/table


Thanks. Would be nice if there was like a "amqpbroadcaster.broadcastServers" with a comma separated list of database server names to broadcast, and if not set, it does all like it currently does. That would save broadcasting the messages and the log issue. Looks like just a small tweak somewhere around here: https://github.com/Servoy/servoy-extens ... .java#L241
Scott Butler
iTech Professionals, Inc.
SAN Partner

Servoy Consulting & Development
Servoy University- Training Videos
Servoy Components- Plugins, Beans, and Web Components
Servoy Guy- Tips & Resources
ServoyForge- Open Source Components
User avatar
sbutler
Servoy Expert
 
Posts: 759
Joined: Sun Jan 08, 2006 7:15 am
Location: Cincinnati, OH

Re: AMQP Databroadcaster with different databases

Postby steve1376656734 » Fri Mar 31, 2023 12:27 pm

That is a MUCH better idea.

Are you going to create a ticket for it?
Steve
SAN Developer
There are 10 types of people in the world - those that understand binary and those that don't
steve1376656734
 
Posts: 330
Joined: Fri Aug 16, 2013 2:38 pm
Location: Ashford, UK


Return to Servoy Server

Who is online

Users browsing this forum: No registered users and 1 guest

cron