Login Page - Create Account

Support Board


Date/Time: Sun, 19 May 2024 09:22:56 +0000



Post From: Connecting to external MySQL database server

[2013-11-05 12:01:55]
ChrisR - Posts: 7
I thought I'd update this thread in case anybody else wants to write to an external database.

I have now created a very stable and powerful solution that works really well. SC is awesome, once you get your head around using ACSIL.

This is my solution:

~~~~~~~~

SC is running on a Windows VPS. My SC indicator looks for events and then connects to an external exe file, also running on the VPS. SC sends parameters to the exe file.

The exe fie connects to a remote MYSQL database running on a Linux server and writes the data from SC into the database.

The exe file does error checking to ensure that the db connection is OK and that the db insert was successful. It returns a success/fail value back to the SC indicator.

If the exe file detects a db problem, it sends me an email stating the error.

If the exe file returns a fail to SC, the SC indicator does not send further requests to the exe file.

~~~~~~~~~~

Using one minute update intervals, there are no performance issues at all, and the system could easily cope with much shorter update intervals.

The Windows VPS only has 2GB RAM and will easily cope with multiple instances of SC and charts

I made sure there is a fast ping time (3ms) between the Windows VPS and Linux server.

Chris