Unlock the 5 Key Architecture Metrics for High‑Performance Systems
This guide outlines the five essential architecture metrics—performance, availability, scalability, extensibility, and security—detailing practical optimization techniques for front‑end resources, server‑side caching, database tuning, load balancing, and security layers to build resilient, high‑performing web systems.
1. Performance
Performance is a core element of architecture design. Optimizing website performance involves many techniques:
(1) Web Front‑end Performance Optimization:
Browser access optimization (cache, compression, layout, reduce cookie transmission)
Reduce HTTP requests, combine JS/CSS/images, design backend requests efficiently.
Use browser caching with Cache‑Control, Expires, versioned filenames.
Compress static resources.
Place CSS at top, JS at bottom to avoid blocking rendering.
Reduce cookie transmission; serve static resources from a separate domain.
2. CDN Acceleration: cache images, files, CSS, scripts; CDN works better on PC than mobile.
Cache static assets; mobile “last‑mile” latency reduces CDN effectiveness.
3. Reverse Proxy: provides layer‑7 load balancing, static caching, request forwarding, attack protection; e.g., Nginx.
(2) Application Server Performance Optimization:
If static pages are fast but dynamic data is slow, MySQL may be overloaded; use local and distributed caches, asynchronous processing, and clustering to improve performance.
1. Distributed Cache (first law of website performance: prioritize caching)
Cache read/write ratio should be >2:1; cache hot data.
Consider data inconsistency and overhead of real‑time cache updates.
Avoid cache miss storms by clustering cache nodes.
Pre‑warm cache with hot data before peak traffic.
Cache negative lookups to prevent DB overload from malicious queries.
Design cache as decentralized yet centrally managed for scalability.
2. Asynchrony: defer non‑critical work, use distributed message queues to smooth spikes (e.g., 12306 queue).
3. Clustering: avoid single points of failure, improve availability and performance.
4. Code Optimization:
Thread count: CPU‑bound ≤ cores; I/O‑bound = tasks/(tasks‑IO wait) * cores. Use stateless, local objects, fine‑grained locks.
Resource reuse: singleton, connection pools.
Set JVM parameters to minimize full GC.
5. Storage Performance Optimization:
Relational DB indexes use B+ trees; many NoSQL use LSM trees, which excel for write‑heavy, recent‑read workloads. HDFS + MapReduce provides scalable, reliable storage similar to RAID.
(3) Database Layer Optimization:
Database layer is fragile; intercept requests upstream, use queues and caches to protect it. When MySQL becomes a bottleneck, apply indexes, caching, SQL tuning, or switch to NoSQL for better data models.
(4) Measuring Website Performance:
Response time.
Concurrent users (estimate peak concurrency as average QPS × 3).
Throughput: QPS, HPS, TPS.
Performance counters: load, threads, CPU, memory (use top, free, /proc/cpuinfo). Optimal load ≈ 0.7 × logical CPUs.
2. Security
The internet is open; website security protects against malicious access and data theft.
Five security elements: confidentiality, integrity, availability, controllability, auditability.
1. Security System Architecture
Security services include authentication, access control, confidentiality, integrity, and non‑repudiation.
Security mechanisms: encryption, digital signatures, access control, integrity checks, authentication exchange, traffic padding, routing control, notarization.
General security mechanisms: trusted functions, security tags, event detection, audit tracing, recovery.
2. Security Protection Levels
User‑controlled protection
System audit protection
Security tag protection
Structured protection
Access verification protection
Security architecture is measured by its ability to counter existing and potential attacks.
3. Availability
High availability means the system remains functional despite server failures or unexpected issues.
Key methods: redundancy, clustering, distribution.
Redundancy deploys applications on multiple servers and replicates data, often using load balancers to form a cluster.
4. Extensibility
Extensibility is the ability to add or enhance functionality with minimal impact on existing systems, relying on stable infrastructure, low coupling, and good architectural design.
Event‑driven architecture and distributed services are primary means.
Event‑driven uses message queues to separate production and processing.
Service‑oriented design separates business logic from reusable services; new products call existing services without affecting others.
The Scalability Cube model defines X‑axis (horizontal scaling), Y‑axis (functional decomposition), Z‑axis (service/data priority, e.g., geographic).
X‑axis: horizontal data/service cloning.
Y‑axis: division of responsibilities.
Z‑axis: prioritization across regions.
5. Scalability
Design services to be homogeneous; plan DB and cache scaling in advance, using NoSQL, Memcached, HBase, etc.
(1) Horizontal separation: deploy different business modules separately to achieve scalability.
(2) Vertical separation: separate different stages of business processing to achieve scalability.
Signed-in readers can open the original source through BestHub's protected redirect.
This article has been distilled and summarized from source material, then republished for learning and reference. If you believe it infringes your rights, please contactand we will review it promptly.
ITFLY8 Architecture Home
ITFLY8 Architecture Home - focused on architecture knowledge sharing and exchange, covering project management and product design. Includes large-scale distributed website architecture (high performance, high availability, caching, message queues...), design patterns, architecture patterns, big data, project management (SCRUM, PMP, Prince2), product design, and more.
How this landed with the community
Was this worth your time?
0 Comments
Thoughtful readers leave field notes, pushback, and hard-won operational detail here.
