Implementing a master/slave architecture for a data synchronization service
Baychenko, Nikolay (2018)
Julkaisun pysyvä osoite on
https://urn.fi/URN:NBN:fi:amk-201804245326
https://urn.fi/URN:NBN:fi:amk-201804245326
Tiivistelmä
A data synchronization service called “Tehden connector” is an application developed by Codaone Ltd to synchronize data between online stores and Tehden Ltd. The application is being used by a certain number of customers and supports a variety of E-commerce platforms.
The purpose of this thesis was to implement optimization of the “Tehden connector” in a master/slave architecture to make the application more scalable, robust, and decentralized.
The application operates on the Ubuntu operating system, implemented via the PHP framework – Symfony and supported by the MySQL database management system. The optimization was conducted as a refactoring of the current application, with the addition of using HTTP as data transfer protocol and JSON as data structure for an internal communication within the master/slave structure.
The logic of the optimization is implemented in a way that instead of storing and operating all tasks on one machine, it stores settings and customer data on a master machine and the master assigns executable tasks to slave machines.
The database of the application was extended with different structure both for the master and the slaves in a way that the master stores settings and connections between customers and slave, and the slaves store credentials necessary for communicating with the master.
The refracturing of the code was implemented as an addition of the current application with master/slave communication features and creation of relations between the main code and the communication features.
The tests revealed that optimization was implemented successfully and that the “Tehden connector” can work within a master/slave communication structure. However, the optimization was not released into the production environment due to the missing features that are out of the scope of the thesis.
The implementation of the optimization within the scope of this thesis has proven that the “Tehden connector” is able to work within a master/slave communication architecture. However, to provide production ready solution, more work will be performed by Codaone Oy in the future.
The purpose of this thesis was to implement optimization of the “Tehden connector” in a master/slave architecture to make the application more scalable, robust, and decentralized.
The application operates on the Ubuntu operating system, implemented via the PHP framework – Symfony and supported by the MySQL database management system. The optimization was conducted as a refactoring of the current application, with the addition of using HTTP as data transfer protocol and JSON as data structure for an internal communication within the master/slave structure.
The logic of the optimization is implemented in a way that instead of storing and operating all tasks on one machine, it stores settings and customer data on a master machine and the master assigns executable tasks to slave machines.
The database of the application was extended with different structure both for the master and the slaves in a way that the master stores settings and connections between customers and slave, and the slaves store credentials necessary for communicating with the master.
The refracturing of the code was implemented as an addition of the current application with master/slave communication features and creation of relations between the main code and the communication features.
The tests revealed that optimization was implemented successfully and that the “Tehden connector” can work within a master/slave communication structure. However, the optimization was not released into the production environment due to the missing features that are out of the scope of the thesis.
The implementation of the optimization within the scope of this thesis has proven that the “Tehden connector” is able to work within a master/slave communication architecture. However, to provide production ready solution, more work will be performed by Codaone Oy in the future.