Home Web Front-end HTML Tutorial 10 issues that must be considered when designing and producing large-scale website architecture_HTML/Xhtml_Web page production

10 issues that must be considered when designing and producing large-scale website architecture_HTML/Xhtml_Web page production

May 16, 2016 pm 04:37 PM
Large website Architecture design

We are not talking about PHP, JSP or .NET environment here. We look at the problem from the perspective of architecture. The implementation language is not a problem. The advantage of the language lies in the implementation rather than the quality. No matter which language you choose, the architecture is It must be faced.

 1. Processing of massive data

As we all know, for some relatively small sites, the amount of data is not very large. Select and update can solve the problems we face. The load itself is not very large, and it can be solved by adding a few indexes at most. For large websites, the amount of data every day may be in the millions. If a many-to-many relationship is poorly designed, there will be no problems in the early stage. However, as the number of users increases, the amount of data will increase geometrically. At this time, the cost of selecting and updating a table (not to mention joint query of multiple tables) is very high.

 2. Data concurrency processing

In some cases, 2.0 CTOs have a Shang Fang sword, which is caching. Caching is also a big problem when there is high concurrency and high processing. The cache is globally shared throughout the application. However, when we make modifications, if two or more requests request updates to the cache at the same time, the application will die directly. At this time, a good data concurrency processing strategy and caching strategy are needed.

In addition, there is the problem of deadlock in the database. We may not feel it at ordinary times. The probability of deadlock in high concurrency situations is very high. Disk caching is a big problem.

 3. Problems of file storage

For some 2.0 sites that support file upload, when we are fortunate that hard disk capacity is getting larger and larger, we should consider more about how files should be stored and effectively indexed. A common solution is to store files by date and type. But when the file volume is massive data, if a hard disk stores 500 G trivial files, then the Io of the disk will be a huge problem during maintenance and use. Even if your bandwidth is sufficient, but you The disk may not respond. If uploading is also involved at this time, the disk will easily become over.

Maybe using RAID and dedicated storage servers can solve the current problem, but there is still a problem of access from various places. Maybe our server is in Beijing, Yunnan or Xinzang. How to solve the access speed? If we do distribution formula, then how should we plan our file index and architecture.

So we have to admit that file storage is a very difficult problem

 4. Processing of data relationships

We can easily plan a database that conforms to the third paradigm, which is full of many-to-many relationships, and can also use GUID to replace INDENTIFY COLUMN. However, in the 2.0 era where many-to-many relationships are abundant, the third paradigm is The first one should be discarded. Multi-table joint queries must be effectively reduced to a minimum.

5. Data index problem

As we all know, indexing is the cheapest and easiest way to improve database query efficiency. However, in the case of high UPDATE, the cost of update and delete will be unimaginably high. The author encountered a situation where updating a focused index took 10 minutes to complete. So for the site, these basic It's unbearable.

Indexing and updating are natural enemies. Issues A, D, and E are issues that we have to consider when doing architecture, and they may also be the issues that take the most time.

 6. Distributed processing

For 2.0 websites due to their high interactivity, the effect of CDN is basically 0. The content is updated in real time and we handle it conventionally. In order to ensure the access speed in various places, we need to face a huge problem, which is how to effectively realize data synchronization and update. Real-time communication of servers in various places is an issue that must be considered.

7. Ajax pros and cons analysis

AJAX succeeds, and AJAX fails. AJAX has become the mainstream trend, and suddenly I found that post and get based on XMLHTTP are so easy. The client gets or posts data to the server, and the server returns it after receiving the data request. This is a normal AJAX request. But during AJAX processing, if we use a packet capture tool, the data return and processing will be clear at a glance. For some computationally intensive AJAX requests, we can construct a packet sending machine, which can easily kill a webserver.

8. Analysis of data security

For the HTTP protocol, data packets are transmitted in clear text. Maybe we can say that we can use encryption, but for the G problem, the encryption process may be in clear text (such as the QQ we know, You can easily judge its encryption and effectively write an encryption and decryption method similar to his). When your site traffic is not very large, no one will care about you, but when your traffic increases, so-called plug-ins and so-called mass messages will follow one after another (you can see the clues from the mass messages at the beginning of QQ). Perhaps we can safely say that we can use higher-level judgment or even HTTPS to implement it. Note that when you do these processes, you will pay massive database, IO and CPU costs. For some mass sending, it is basically impossible. The author has been able to achieve mass messaging for Baidu space and qq space. If you are willing to give it a try, it is actually not difficult.

 9. Data synchronization and cluster processing issues

When one of our database servers is overwhelmed, we need to do database-based load and clustering at this time. This may be the most troublesome problem at this time. Data is transmitted over the network. Depending on the design of the database, data delay is a terrible problem and an unavoidable problem. In this case, we need to use other means to solve the problem. Ensure that effective interaction is achieved within this delay of a few seconds or longer. Such as data hashing, segmentation, content processing and other issues.

 10. Data sharing channels and OPENAPI trends

Openapi has become an inevitable trend. From google, facebook, myspace to domestic schools, everyone is considering this issue. It can retain users more effectively, stimulate more interest in users, and attract more people. Help you do the most effective development. At this time, an effective data sharing platform and data open platform have become indispensable. Ensuring data security and performance in the case of open interfaces is another issue that we must seriously consider.

Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn

Hot AI Tools

Undresser.AI Undress

Undresser.AI Undress

AI-powered app for creating realistic nude photos

AI Clothes Remover

AI Clothes Remover

Online AI tool for removing clothes from photos.

Undress AI Tool

Undress AI Tool

Undress images for free

Clothoff.io

Clothoff.io

AI clothes remover

Video Face Swap

Video Face Swap

Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Tools

Notepad++7.3.1

Notepad++7.3.1

Easy-to-use and free code editor

SublimeText3 Chinese version

SublimeText3 Chinese version

Chinese version, very easy to use

Zend Studio 13.0.1

Zend Studio 13.0.1

Powerful PHP integrated development environment

Dreamweaver CS6

Dreamweaver CS6

Visual web development tools

SublimeText3 Mac version

SublimeText3 Mac version

God-level code editing software (SublimeText3)

Starting at 649 yuan, Kubi Cube Xiaoku Tablet 2 Lite is here: 11-inch eye-protecting large screen + 8000mAh large battery Starting at 649 yuan, Kubi Cube Xiaoku Tablet 2 Lite is here: 11-inch eye-protecting large screen + 8000mAh large battery Mar 05, 2024 pm 05:34 PM

According to news on March 4, Kubi Rubik's Cube will launch the "Xiaoku Tablet 2Lite" tablet computer on March 5, with an initial price of 649 yuan. It is reported that the new tablet is equipped with Unisoc’s T606 processor, which uses a 12nm process and consists of two 1.6GHz ArmCortex-A75 CPUs and six ArmCortex-A55 processors. The screen uses a 10.95-inch IPS eye-protection screen with a resolution of 1280x800 and a brightness as high as 350 nits. In terms of imaging, Xiaoku Tablet 2Lite has a 13-megapixel main camera on the rear and a 5-megapixel selfie lens on the front. It also supports 4G Internet access/calls, Bluetooth 5.0, and Wi-Fi5. In addition, the official claimed that this tablet&l

ZTE 5G portable Wi-Fi U50S goes on sale for NT$899 at first launch: top speed 500Mbps ZTE 5G portable Wi-Fi U50S goes on sale for NT$899 at first launch: top speed 500Mbps Apr 26, 2024 pm 03:46 PM

According to news on April 26, ZTE’s 5G portable Wi-Fi U50S is now officially on sale, starting at 899 yuan. In terms of appearance design, ZTE U50S Portable Wi-Fi is simple and stylish, easy to hold and pack. Its size is 159/73/18mm and is easy to carry, allowing you to enjoy 5G high-speed network anytime and anywhere, achieving an unimpeded mobile office and entertainment experience. ZTE 5G portable Wi-Fi U50S supports the advanced Wi-Fi 6 protocol with a peak rate of up to 1800Mbps. It relies on the Snapdragon X55 high-performance 5G platform to provide users with an extremely fast network experience. Not only does it support the 5G dual-mode SA+NSA network environment and Sub-6GHz frequency band, the measured network speed can even reach an astonishing 500Mbps, which is easily satisfactory.

Retro trend! HMD and Heineken jointly launch flip phone: transparent shell design Retro trend! HMD and Heineken jointly launch flip phone: transparent shell design Apr 17, 2024 pm 06:50 PM

According to news on April 17, HMD teamed up with the well-known beer brand Heineken and the creative company Bodega to launch a unique flip phone - The Boring Phone. This phone is not only full of innovation in design, but also returns to nature in terms of functionality, aiming to lead people back to real interpersonal interactions and enjoy the pure time of drinking with friends. Boring mobile phone adopts a unique transparent flip design, showing a simple yet elegant aesthetic. It is equipped with a 2.8-inch QVGA display inside and a 1.77-inch display outside, providing users with a basic visual interaction experience. In terms of photography, although it is only equipped with a 30-megapixel camera, it is enough to handle simple daily tasks.

What is the architecture and working principle of Spring Data JPA? What is the architecture and working principle of Spring Data JPA? Apr 17, 2024 pm 02:48 PM

SpringDataJPA is based on the JPA architecture and interacts with the database through mapping, ORM and transaction management. Its repository provides CRUD operations, and derived queries simplify database access. Additionally, it uses lazy loading to only retrieve data when necessary, thus improving performance.

Honor Magic V3 debuts AI defocus eye protection technology: effectively alleviates the development of myopia Honor Magic V3 debuts AI defocus eye protection technology: effectively alleviates the development of myopia Jul 18, 2024 am 09:27 AM

According to news on July 12, the Honor Magic V3 series was officially released today, equipped with the new Honor Vision Soothing Oasis eye protection screen. While the screen itself has high specifications and high quality, it also pioneered the introduction of AI active eye protection technology. It is reported that the traditional way to alleviate myopia is "myopia glasses". The power of myopia glasses is evenly distributed to ensure that the central area of ​​​​sight is imaged on the retina, but the peripheral area is imaged behind the retina. The retina senses that the image is behind, promoting the eye axis direction. grow later, thereby deepening the degree. At present, one of the main ways to alleviate the development of myopia is the "defocus lens". The central area has a normal power, and the peripheral area is adjusted through optical design partitions, so that the image in the peripheral area falls in front of the retina.

1.3ms takes 1.3ms! Tsinghua's latest open source mobile neural network architecture RepViT 1.3ms takes 1.3ms! Tsinghua's latest open source mobile neural network architecture RepViT Mar 11, 2024 pm 12:07 PM

Paper address: https://arxiv.org/abs/2307.09283 Code address: https://github.com/THU-MIG/RepViTRepViT performs well in the mobile ViT architecture and shows significant advantages. Next, we explore the contributions of this study. It is mentioned in the article that lightweight ViTs generally perform better than lightweight CNNs on visual tasks, mainly due to their multi-head self-attention module (MSHA) that allows the model to learn global representations. However, the architectural differences between lightweight ViTs and lightweight CNNs have not been fully studied. In this study, the authors integrated lightweight ViTs into the effective

Teclast M50 Mini tablet is here: 8.7-inch IPS screen, 5000mAh battery Teclast M50 Mini tablet is here: 8.7-inch IPS screen, 5000mAh battery Apr 04, 2024 am 08:31 AM

According to news on April 3, Taipower’s upcoming M50 Mini tablet computer is a device with rich functions and powerful performance. This new 8-inch small tablet is equipped with an 8.7-inch IPS screen, providing users with an excellent visual experience. Its metal body design is not only beautiful but also enhances the durability of the device. In terms of performance, the M50Mini is equipped with the Unisoc T606 eight-core processor, which has two A75 cores and six A55 cores, ensuring a smooth and efficient running experience. At the same time, the tablet is also equipped with a 6GB+128GB storage solution and supports 8GB memory expansion, which meets users’ needs for storage and multi-tasking. In terms of battery life, M50Mini is equipped with a 5000mAh battery and supports Ty

How to design the end page of ppt to be attractive enough How to design the end page of ppt to be attractive enough Mar 20, 2024 pm 12:30 PM

At work, ppt is an office software often used by professionals. A complete ppt must have a good ending page. Different professional requirements give different ppt production characteristics. Regarding the production of the end page, how can we design it more attractively? Let’s take a look at how to design the end page of ppt! The design of the ppt end page can be adjusted in terms of text and animation, and you can choose a simple or dazzling style according to your needs. Next, we will focus on how to use innovative expression methods to create a ppt end page that meets the requirements. So let’s start today’s tutorial. 1. For the production of the end page, any text in the picture can be used. The important thing about the end page is that it means that my presentation is over. 2. In addition to these words,

See all articles