I have a master and slave DB in mysql. We have more than 1m orders per month, when we tried to pull the data using mysql views from master it slows down the application. So we had created a slave and we are dumping the data into sales report table
by mysql events (event runs on every 5 minutes and inserts new record to reports schema) . Whenever this event runs, replication started to fail.
I had some basic check, Is that issue because of mysql event but No
Is there any other better methods available to do this
Master
Order Schema
- order
- xxxx
- yyyy
Customer Schema
- customer info
Account Schema
- customer account
- xxxx
- yyyy
Slave
<All the Master DB schema tables & schema we have it in slave by replication and we had created one more schema for reporting purpose>
Order Schema
- order
- xxxx
- yyyy
Customer Schema
- customer info
Account Schema
- customer account
- xxxx
- yyyy
Reports Schema
- sales report