I want to build a web application with MySQL database.
When more users will visit my site, more database queries will be initiated and the response time will increase.
- Is there a limitation for the number of users who can query MySQL?
- What are the ways to handle heavy duty traffic to queries?
- How do think sites like Facebook handle this problem?
:icon_smile:

Recommended Answers

All 2 Replies

1. Number of connections are controlled by MySQL configuration parameter max_connections.
2. Use caching in your application and MySQL. Design your DB in such a way which requires minimum JOINs to fetch data. This is also known as denormalization. Write optimize queries, avoid SELECT * sort of quereis and properly index your data.
3. They adopt all the techniques which are mentioned above and as well as some others which is not mentioned here :)

They have multiple web servers and database servers, you can say server farms.

Read this article to optimize your application.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.