Database design of space exchanging time

Source: Internet
Author: User

Our system is often used to send SMS, email and so on, in our design will usually create a tb_outbox table, when the data generated, inserted into the Tb_outbox table, by the timer to read the Tb_outbox data to send, and then modify Tb_ The sending status of the Outbox. Yes, this is the usual practice, but when our SMS, email send frequency and number of large enough, our system will appear performance, table locked and so on. So what are we going to do?

One idea of the following design is as described in the title: space to change time. Personally, I feel that this description is more appropriate: separation of objects ' responsibilities, insert, Update, delete, and so on in different tables. Don't say much nonsense, let's take a look at this design chart:

Diagram: Logic diagram

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.