chore: sync content to repo (#9255)

Co-authored-by: kamranahmedse <4921183+kamranahmedse@users.noreply.github.com>
This commit is contained in:
github-actions[bot]
2025-10-20 11:30:20 +05:00
committed by GitHub
co-authored by kamranahmedse
parent df3dca4882
commit ef63bce224
147 changed files with 525 additions and 506 deletions
@@ -4,6 +4,6 @@ Create helper services that send network requests on behalf of a consumer servic
This pattern can be useful for offloading common client connectivity tasks such as monitoring, logging, routing, security (such as TLS), and resiliency patterns in a language agnostic way. It is often used with legacy applications, or other applications that are difficult to modify, in order to extend their networking capabilities. It can also enable a specialized team to implement those features.
To learn more, visit the following links:
Visit the following resources to learn more:
- [@article@Ambassador pattern](https://learn.microsoft.com/en-us/azure/architecture/patterns/ambassador)
- [@article@Ambassador pattern](https://learn.microsoft.com/en-us/azure/architecture/patterns/ambassador)
@@ -2,6 +2,6 @@
Implement a facade or adapter layer between different subsystems that don't share the same semantics. This layer translates requests that one subsystem makes to the other subsystem. Use this pattern to ensure that an application's design is not limited by dependencies on outside subsystems. This pattern was first described by Eric Evans in Domain-Driven Design.
To learn more, visit the following links:
Visit the following resources to learn more:
- [@article@Anti-corruption Layer pattern](https://learn.microsoft.com/en-us/azure/architecture/patterns/anti-corruption-layer)
- [@article@Anti-corruption Layer pattern](https://learn.microsoft.com/en-us/azure/architecture/patterns/anti-corruption-layer)
@@ -1,14 +1,14 @@
# Application Caching
In-memory caches such as Memcached and Redis are key-value stores between your application and your data storage. Since the data is held in RAM, it is much faster than typical databases where data is stored on disk. RAM is more limited than disk, so [cache invalidation](https://en.wikipedia.org/wiki/Cache_algorithms) algorithms such as [least recently used (LRU)](<https://en.wikipedia.org/wiki/Cache_replacement_policies#Least_recently_used_(LRU)>) can help invalidate 'cold' entries and keep 'hot' data in RAM.
In-memory caches such as Memcached and Redis are key-value stores between your application and your data storage. Since the data is held in RAM, it is much faster than typical databases where data is stored on disk. RAM is more limited than disk, so [cache invalidation](https://en.wikipedia.org/wiki/Cache_algorithms) algorithms such as [least recently used (LRU)](https://en.wikipedia.org/wiki/Cache_replacement_policies#Least_recently_used_\(LRU\)) can help invalidate 'cold' entries and keep 'hot' data in RAM.
Redis has the following additional features:
- Persistence option
- Built-in data structures such as sorted sets and lists
* Persistence option
* Built-in data structures such as sorted sets and lists
Generally, you should try to avoid file-based caching, as it makes cloning and auto-scaling more difficult.
Visit the following links to learn more:
Visit the following resources to learn more:
- [@opensource@Intro to Application Caching](https://github.com/donnemartin/system-design-primer#application-caching)
- [@opensource@Intro to Application Caching](https://github.com/donnemartin/system-design-primer#application-caching)
@@ -4,11 +4,12 @@ Separating out the web layer from the application layer (also known as platform
![](https://i.imgur.com/F0cjurv.png)
## Disadvantages
Disadvantages
-------------
- Adding an application layer with loosely coupled services requires a different approach from an architectural, operations, and process viewpoint (vs a monolithic system).
- Microservices can add complexity in terms of deployments and operations.
* Adding an application layer with loosely coupled services requires a different approach from an architectural, operations, and process viewpoint (vs a monolithic system).
* Microservices can add complexity in terms of deployments and operations.
For more resources, visit the following links:
Visit the following resources to learn more:
- [@article@Intro to architecting systems for scale](http://lethain.com/introduction-to-architecting-systems-for-scale/#platform_layer)
- [@article@Intro to architecting systems for scale](http://lethain.com/introduction-to-architecting-systems-for-scale/#platform_layer)
@@ -2,6 +2,6 @@
Decouple backend processing from a frontend host, where backend processing needs to be asynchronous, but the frontend still needs a clear response.
Learn more from the following links:
Visit the following resources to learn more:
- [@article@Asynchronous Request-Reply pattern](https://learn.microsoft.com/en-us/azure/architecture/patterns/async-request-reply)
- [@article@Asynchronous Request-Reply pattern](https://learn.microsoft.com/en-us/azure/architecture/patterns/async-request-reply)
@@ -2,10 +2,10 @@
Asynchronous workflows help reduce request times for expensive operations that would otherwise be performed in-line. They can also help by doing time-consuming work in advance, such as periodic aggregation of data.
To learn more, visit the following links:
Visit the following resources to learn more:
- [@article@Patterns for microservices - Sync vs Async](https://medium.com/inspiredbrilliance/patterns-for-microservices-e57a2d71ff9e)
- [@video@It's all a numbers game](https://www.youtube.com/watch?v=1KRYH75wgy4)
- [@article@Applying back pressure when overloaded](http://mechanical-sympathy.blogspot.com/2012/05/apply-back-pressure-when-overloaded.html)
- [@article@Little's law](https://en.wikipedia.org/wiki/Little%27s_law)
- [@article@What is the difference between a message queue and a task queue?](https://www.quora.com/What-is-the-difference-between-a-message-queue-and-a-task-queue-Why-would-a-task-queue-require-a-message-broker-like-RabbitMQ-Redis-Celery-or-IronMQ-to-function)
- [@video@It's all a numbers game](https://www.youtube.com/watch?v=1KRYH75wgy4)
@@ -2,29 +2,30 @@
Availability is often quantified by uptime (or downtime) as a percentage of time the service is available. Availability is generally measured in number of 9s--a service with 99.99% availability is described as having four 9s.
## 99.9% Availability - Three 9s:
99.9% Availability - Three 9s:
------------------------------
```
Duration | Acceptable downtime
------------- | -------------
Downtime per year | 8h 41min 38s
Downtime per month | 43m 28s
Downtime per week | 10m 4.8s
Downtime per day | 1m 26s
```
Duration | Acceptable downtime
------------- | -------------
Downtime per year | 8h 41min 38s
Downtime per month | 43m 28s
Downtime per week | 10m 4.8s
Downtime per day | 1m 26s
## 99.99% Availability - Four 9s
99.99% Availability - Four 9s
-----------------------------
```
Duration | Acceptable downtime
------------- | -------------
Downtime per year | 52min 9.8s
Downtime per month | 4m 21s
Downtime per week | 1m 0.5s
Downtime per day | 8.6s
```
Duration | Acceptable downtime
------------- | -------------
Downtime per year | 52min 9.8s
Downtime per month | 4m 21s
Downtime per week | 1m 0.5s
Downtime per day | 8.6s
## Availability in parallel vs in sequence
Availability in parallel vs in sequence
---------------------------------------
If a service consists of multiple components prone to failure, the service's overall availability depends on whether the components are in sequence or in parallel.
@@ -32,9 +33,8 @@ If a service consists of multiple components prone to failure, the service's ove
Overall availability decreases when two components with availability < 100% are in sequence:
```
Availability (Total) = Availability (Foo) * Availability (Bar)
```
Availability (Total) = Availability (Foo) * Availability (Bar)
If both `Foo` and `Bar` each had 99.9% availability, their total availability in sequence would be 99.8%.
@@ -42,13 +42,12 @@ If both `Foo` and `Bar` each had 99.9% availability, their total availability in
Overall availability increases when two components with availability < 100% are in parallel:
```
Availability (Total) = 1 - (1 - Availability (Foo)) * (1 - Availability (Bar))
```
Availability (Total) = 1 - (1 - Availability (Foo)) * (1 - Availability (Bar))
If both `Foo` and `Bar` each had 99.9% availability, their total availability in parallel would be 99.9999%.
To learn more, visit the following links:
Visit the following resources to learn more:
- [@article@Availability in System Design](https://www.enjoyalgorithms.com/blog/availability-system-design-concept/)
- [@article@Uptime calculator: How much downtime corresponds to 99.9 % uptime](https://uptime.is/)
- [@article@Uptime calculator: How much downtime corresponds to 99.9 % uptime](https://uptime.is/)
@@ -2,7 +2,7 @@
A truly healthy system requires that the components and subsystems that compose the system are available. Availability monitoring is closely related to health monitoring. But whereas health monitoring provides an immediate view of the current health of the system, availability monitoring is concerned with tracking the availability of the system and its components to generate statistics about the uptime of the system.
Learn more from the following:
Visit the following resources to learn more:
- [@article@Availability Monitoring](https://learn.microsoft.com/en-us/azure/architecture/best-practices/monitoring#availability-monitoring)
- [@feed@Explore top posts about Monitoring](https://app.daily.dev/tags/monitoring?ref=roadmapsh)
- [@feed@Explore top posts about Monitoring](https://app.daily.dev/tags/monitoring?ref=roadmapsh)
@@ -1,5 +1,9 @@
# Availability Patterns
Availability is measured as a percentage of uptime, and defines the proportion of time that a system is functional and working. Availability is affected by system errors, infrastructure problems, malicious attacks, and system load. Cloud applications typically provide users with a service level agreement (SLA), which means that applications must be designed and implemented to maximize availability.
Availability patterns are established architectural approaches used to ensure a system remains operational and accessible to users, even in the face of failures or unexpected events. These patterns focus on minimizing downtime and maintaining a consistent level of service by incorporating redundancy, fault tolerance, and recovery mechanisms into the system's design. They provide a structured way to address potential points of failure and ensure business continuity.
- [@article@Availability Patterns](https://learn.microsoft.com/en-us/azure/architecture/framework/resiliency/reliability-patterns#availability)
Visit the following resources to learn more:
- [@article@High Availability in System Design – 15 Strategies for Always-On Systems](https://www.designgurus.io/blog/high-availability-system-design-basics)
- [@article@System Design: Availability Patterns](https://dev.to/decoders_lord/system-design-availability-patterns-104i)
- [@video@Design Patterns for High Availability: What gets you 99.999% uptime?](https://www.youtube.com/watch?v=LdvduBxZRLs)
@@ -6,9 +6,9 @@ Consistency, on the other hand, refers to the property that all clients see the
In distributed systems, it is often a trade-off between availability and consistency. Systems that prioritize high availability may sacrifice consistency, while systems that prioritize consistency may sacrifice availability. Different distributed systems use different approaches to balance the trade-off between availability and consistency, such as using replication or consensus algorithms.
Have a look at the following resources to learn more:
Visit the following resources to learn more:
- [@video@CAP Theorem](https://www.youtube.com/watch?v=_RbsFXWRZ10&t=1s)
- [@opensource@CAP FAQ](https://github.com/henryr/cap-faq)
- [@article@CAP Theorem Revisited](https://robertgreiner.com/cap-theorem-revisited/)
- [@article@A plain english introduction to CAP Theorem](http://ksat.me/a-plain-english-introduction-to-cap-theorem)
- [@opensource@CAP FAQ](https://github.com/henryr/cap-faq)
- [@video@CAP Theorem](https://www.youtube.com/watch?v=_RbsFXWRZ10&t=1s)
@@ -2,6 +2,6 @@
Availability is measured as a percentage of uptime, and defines the proportion of time that a system is functional and working. Availability is affected by system errors, infrastructure problems, malicious attacks, and system load. Cloud applications typically provide users with a service level agreement (SLA), which means that applications must be designed and implemented to maximize availability.
To learn more visit the following links:
Visit the following resources to learn more:
- [@article@Availability Patterns](https://learn.microsoft.com/en-us/azure/architecture/framework/resiliency/reliability-patterns#availability)
- [@article@Availability Patterns](https://learn.microsoft.com/en-us/azure/architecture/framework/resiliency/reliability-patterns#availability)
@@ -1,3 +1,3 @@
# Back Pressure
If queues start to grow significantly, the queue size can become larger than memory, resulting in cache misses, disk reads, and even slower performance. [Back pressure](http://mechanical-sympathy.blogspot.com/2012/05/apply-back-pressure-when-overloaded.html) can help by limiting the queue size, thereby maintaining a high throughput rate and good response times for jobs already in the queue. Once the queue fills up, clients get a server busy or HTTP 503 status code to try again later. Clients can retry the request at a later time, perhaps with [exponential backoff](https://en.wikipedia.org/wiki/Exponential_backoff).
If queues start to grow significantly, the queue size can become larger than memory, resulting in cache misses, disk reads, and even slower performance. [Back pressure](http://mechanical-sympathy.blogspot.com/2012/05/apply-back-pressure-when-overloaded.html) can help by limiting the queue size, thereby maintaining a high throughput rate and good response times for jobs already in the queue. Once the queue fills up, clients get a server busy or HTTP 503 status code to try again later. Clients can retry the request at a later time, perhaps with [exponential backoff](https://en.wikipedia.org/wiki/Exponential_backoff).
@@ -2,7 +2,7 @@
Create separate backend services to be consumed by specific frontend applications or interfaces. This pattern is useful when you want to avoid customizing a single backend for multiple interfaces. This pattern was first described by Sam Newman.
To learn more, visit the following links:
Visit the following resources to learn more:
- [@article@Backends for Frontends pattern](https://learn.microsoft.com/en-us/azure/architecture/patterns/backends-for-frontends)
- [@feed@Explore top posts about Frontend Development](https://app.daily.dev/tags/frontend?ref=roadmapsh)
- [@feed@Explore top posts about Frontend Development](https://app.daily.dev/tags/frontend?ref=roadmapsh)
@@ -4,11 +4,11 @@ Background jobs in system design refer to tasks that are executed in the backgro
Background jobs can be used for a variety of purposes, such as:
- Performing maintenance tasks: such as cleaning up old data, generating reports, or backing up the database.
- Processing large volumes of data: such as data import, data export, or data transformation.
- Sending notifications or messages: such as sending email notifications or push notifications to users.
- Performing long-running computations: such as machine learning or data analysis.
* Performing maintenance tasks: such as cleaning up old data, generating reports, or backing up the database.
* Processing large volumes of data: such as data import, data export, or data transformation.
* Sending notifications or messages: such as sending email notifications or push notifications to users.
* Performing long-running computations: such as machine learning or data analysis.
Learn more from the following links:
Visit the following resources to learn more:
- [@article@Background Jobs - Best Practices](https://learn.microsoft.com/en-us/azure/architecture/best-practices/background-jobs)
- [@article@Background Jobs - Best Practices](https://learn.microsoft.com/en-us/azure/architecture/best-practices/background-jobs)
@@ -2,7 +2,7 @@
The Bulkhead pattern is a type of application design that is tolerant of failure. In a bulkhead architecture, elements of an application are isolated into pools so that if one fails, the others will continue to function. It's named after the sectioned partitions (bulkheads) of a ship's hull. If the hull of a ship is compromised, only the damaged section fills with water, which prevents the ship from sinking.
Learn more from the following links:
Visit the following resources to learn more:
- [@article@Bulkhead pattern](https://learn.microsoft.com/en-us/azure/architecture/patterns/bulkhead)
- [@article@Get started with Bulkhead](https://dzone.com/articles/resilient-microservices-pattern-bulkhead-pattern)
@@ -2,7 +2,7 @@
The Bulkhead pattern is a type of application design that is tolerant of failure. In a bulkhead architecture, elements of an application are isolated into pools so that if one fails, the others will continue to function. It's named after the sectioned partitions (bulkheads) of a ship's hull. If the hull of a ship is compromised, only the damaged section fills with water, which prevents the ship from sinking.
Learn more from the following links:
Visit the following resources to learn more:
- [@article@Bulkhead pattern](https://learn.microsoft.com/en-us/azure/architecture/patterns/bulkhead)
- [@article@Get started with Bulkhead](https://dzone.com/articles/resilient-microservices-pattern-bulkhead-pattern)
@@ -2,7 +2,7 @@
A busy database in system design refers to a database that is handling a high volume of requests or transactions, this can occur when a system is experiencing high traffic or when a database is not properly optimized for the workload it is handling. This can lead to Performance degradation, Increased resource utilization, Deadlocks and contention, Data inconsistencies. To address a busy database, a number of approaches can be taken such as Scaling out, Optimizing the schema, Caching, and Indexing.
To learn more, visit the following links:
Visit the following resources to learn more:
- [@article@Busy Database antipattern](https://learn.microsoft.com/en-us/azure/architecture/antipatterns/busy-database/)
- [@feed@Explore top posts about Database](https://app.daily.dev/tags/database?ref=roadmapsh)
- [@feed@Explore top posts about Database](https://app.daily.dev/tags/database?ref=roadmapsh)
@@ -6,7 +6,7 @@ Resource-intensive tasks can increase the response times for user requests and c
This problem typically occurs when an application is developed as monolithic piece of code, with all of the business logic combined into a single tier shared with the presentation layer.
To learn more about this and how to fix this pattern, visit the following link:
Visit the following resources to learn more:
- [@article@Busy Front End antipattern](https://learn.microsoft.com/en-us/azure/architecture/antipatterns/busy-front-end/)
- [@feed@Explore top posts about Frontend Development](https://app.daily.dev/tags/frontend?ref=roadmapsh)
- [@feed@Explore top posts about Frontend Development](https://app.daily.dev/tags/frontend?ref=roadmapsh)
@@ -2,6 +2,6 @@
Load data on demand into a cache from a data store. This can improve performance and also helps to maintain consistency between data held in the cache and data in the underlying data store.
Learn more from the following links:
Visit the following resources to learn more:
- [@article@Cache-Aside pattern](https://learn.microsoft.com/en-us/azure/architecture/patterns/cache-aside)
- [@article@Cache-Aside pattern](https://learn.microsoft.com/en-us/azure/architecture/patterns/cache-aside)
@@ -2,26 +2,25 @@
The application is responsible for reading and writing from storage. The cache does not interact with storage directly. The application does the following:
- Look for entry in cache, resulting in a cache miss
- Load entry from the database
- Add entry to cache
- Return entry
* Look for entry in cache, resulting in a cache miss
* Load entry from the database
* Add entry to cache
* Return entry
```python
def get_user(self, user_id):
user = cache.get("user.{0}", user_id)
if user is None:
user = db.query("SELECT * FROM users WHERE user_id = {0}", user_id)
if user is not None:
key = "user.{0}".format(user_id)
cache.set(key, json.dumps(user))
return user
```
def get_user(self, user_id):
user = cache.get("user.{0}", user_id)
if user is None:
user = db.query("SELECT * FROM users WHERE user_id = {0}", user_id)
if user is not None:
key = "user.{0}".format(user_id)
cache.set(key, json.dumps(user))
return user
[Memcached](https://memcached.org/) is generally used in this manner. Subsequent reads of data added to cache are fast. Cache-aside is also referred to as lazy loading. Only requested data is cached, which avoids filling up the cache with data that isn't requested.
![Cache Aside](https://i.imgur.com/Ujf0awN.png)
To learn more, have a look at the following resources:
Visit the following resources to learn more:
- [@article@From cache to in-memory data grid](https://www.slideshare.net/tmatyashovsky/from-cache-to-in-memory-data-grid-introduction-to-hazelcast)
- [@article@From cache to in-memory data grid](https://www.slideshare.net/tmatyashovsky/from-cache-to-in-memory-data-grid-introduction-to-hazelcast)
@@ -4,19 +4,19 @@ Caching is the process of storing frequently accessed data in a temporary storag
There are several caching strategies:
- Refresh Ahead
- Write-Behind
- Write-through
- Cache Aside
* Refresh Ahead
* Write-Behind
* Write-through
* Cache Aside
Also, you can have the cache in several places, examples include:
- Client Caching
- CDN Caching
- Web Server Caching
- Database Caching
- Application Caching
* Client Caching
* CDN Caching
* Web Server Caching
* Database Caching
* Application Caching
To learn more, visit the following links:
Visit the following resources to learn more:
- [@article@Caching Strategies](https://medium.com/@mmoshikoo/cache-strategies-996e91c80303)
- [@article@Caching Strategies](https://medium.com/@mmoshikoo/cache-strategies-996e91c80303)
@@ -2,25 +2,27 @@
According to CAP theorem, in a distributed system, you can only support two of the following guarantees:
- **Consistency** - Every read receives the most recent write or an error
- **Availability** - Every request receives a response, without guarantee that it contains the most recent version of the information
- **Partition Tolerance** - The system continues to operate despite arbitrary partitioning due to network failures
* **Consistency** - Every read receives the most recent write or an error
* **Availability** - Every request receives a response, without guarantee that it contains the most recent version of the information
* **Partition Tolerance** - The system continues to operate despite arbitrary partitioning due to network failures
Networks aren't reliable, so you'll need to support partition tolerance. You'll need to make a software tradeoff between consistency and availability.
## CP - consistency and partition tolerance
CP - consistency and partition tolerance
----------------------------------------
Waiting for a response from the partitioned node might result in a timeout error. CP is a good choice if your business needs require atomic reads and writes.
## AP - availability and partition tolerance
AP - availability and partition tolerance
-----------------------------------------
Responses return the most readily available version of the data available on any node, which might not be the latest. Writes might take some time to propagate when the partition is resolved.
AP is a good choice if the business needs to allow for [eventual consistency](https://github.com/donnemartin/system-design-primer#eventual-consistency) or when the system needs to continue working despite external errors.
For more information, have a look at the following resources:
Visit the following resources to learn more:
- [@opensource@CAP FAQ](https://github.com/henryr/cap-faq)
- [@article@CAP theorem revisited](http://robertgreiner.com/2014/08/cap-theorem-revisited/)
- [@article@A plain english introduction to CAP theorem](http://ksat.me/a-plain-english-introduction-to-cap-theorem)
- [@opensource@CAP FAQ](https://github.com/henryr/cap-faq)
- [@video@The CAP theorem](https://www.youtube.com/watch?v=k-Yaq8AHlFA)
- [@video@The CAP theorem](https://www.youtube.com/watch?v=k-Yaq8AHlFA)
@@ -4,4 +4,4 @@ A Content Delivery Network (CDN) is a distributed network of servers that are st
When a user requests content from a website that is using a CDN, the CDN will first check if the requested content is available in the cache of a nearby server. If the content is found in the cache, it is served to the user from the nearby server. If the content is not found in the cache, it is requested from the origin server (the original source of the content) and then cached on the nearby server for future requests.
CDN caching can significantly improve the performance and availability of a website by reducing the distance that data needs to travel, reducing the load on the origin server, and allowing for faster delivery of content to end-users.
CDN caching can significantly improve the performance and availability of a website by reducing the distance that data needs to travel, reducing the load on the origin server, and allowing for faster delivery of content to end-users.
@@ -4,10 +4,10 @@ The cumulative effect of a large number of I/O requests can have a significant i
Network calls and other I/O operations are inherently slow compared to compute tasks. Each I/O request typically has significant overhead, and the cumulative effect of numerous I/O operations can slow down the system. Here are some common causes of chatty I/O.
- Reading and writing individual records to a database as distinct requests
- Implementing a single logical operation as a series of HTTP requests
- Reading and writing to a file on disk
* Reading and writing individual records to a database as distinct requests
* Implementing a single logical operation as a series of HTTP requests
* Reading and writing to a file on disk
To learn more, visit the following links:
Visit the following resources to learn more:
- [@article@Chatty I/O antipattern](https://learn.microsoft.com/en-us/azure/architecture/antipatterns/chatty-io/)
- [@article@Chatty I/O antipattern](https://learn.microsoft.com/en-us/azure/architecture/antipatterns/chatty-io/)
@@ -2,6 +2,6 @@
Have each component of the system participate in the decision-making process about the workflow of a business transaction, instead of relying on a central point of control.
Learn more from the following links:
Visit the following resources to learn more:
- [@article@Choreography pattern](https://learn.microsoft.com/en-us/azure/architecture/patterns/choreography)
- [@article@Choreography pattern](https://learn.microsoft.com/en-us/azure/architecture/patterns/choreography)
@@ -2,7 +2,7 @@
Handle faults that might take a variable amount of time to recover from, when connecting to a remote service or resource. This can improve the stability and resiliency of an application.
Learn more from the following links:
Visit the following resources to learn more:
- [@article@Circuit breaker design pattern](https://en.wikipedia.org/wiki/Circuit_breaker_design_pattern)
- [@article@Overview of Circuit Breaker](https://medium.com/geekculture/design-patterns-for-microservices-circuit-breaker-pattern-276249ffab33)
@@ -2,7 +2,7 @@
Handle faults that might take a variable amount of time to recover from, when connecting to a remote service or resource. This can improve the stability and resiliency of an application.
Learn more from the following links:
Visit the following resources to learn more:
- [@article@Circuit breaker design pattern](https://en.wikipedia.org/wiki/Circuit_breaker_design_pattern)
- [@article@Overview of Circuit Breaker](https://medium.com/geekculture/design-patterns-for-microservices-circuit-breaker-pattern-276249ffab33)
@@ -2,6 +2,6 @@
Split a large message into a claim check and a payload. Send the claim check to the messaging platform and store the payload to an external service. This pattern allows large messages to be processed, while protecting the message bus and the client from being overwhelmed or slowed down. This pattern also helps to reduce costs, as storage is usually cheaper than resource units used by the messaging platform.
Learn more from the following links:
Visit the following resources to learn more:
- [@article@Claim Check - Cloud Design patterns](https://learn.microsoft.com/en-us/azure/architecture/patterns/claim-check)
- [@article@Claim Check - Cloud Design patterns](https://learn.microsoft.com/en-us/azure/architecture/patterns/claim-check)
@@ -8,6 +8,6 @@ Another example of client-side caching is application-level caching. Some applic
Client side caching has some advantages like reducing server load, faster page load times, and reducing network traffic. However, it also has some drawbacks like the potential for stale data if the client-side cache is not properly managed, or consuming memory or disk space on the client's device.
Learn more from the following links:
Visit the following resources to learn more:
- [@article@HTTP Caching](https://developer.mozilla.org/en-US/docs/Web/HTTP/Caching)
- [@article@HTTP Caching](https://developer.mozilla.org/en-US/docs/Web/HTTP/Caching)
@@ -2,7 +2,7 @@
Cloud design patterns are solutions to common problems that arise when building systems that run on a cloud platform. These patterns provide a way to design and implement systems that can take advantage of the unique characteristics of the cloud, such as scalability, elasticity, and pay-per-use pricing. Some common cloud design patterns include Scalability, Elasticity, Fault Tolerance, Microservices, Serverless, Data Management, Front-end and Back-end separation and Hybrid.
To learn more, visit the following links:
Visit the following resources to learn more:
- [@article@Cloud Design Patterns](https://learn.microsoft.com/en-us/azure/architecture/patterns/)
- [@feed@Explore top posts about Cloud](https://app.daily.dev/tags/cloud?ref=roadmapsh)
- [@feed@Explore top posts about Cloud](https://app.daily.dev/tags/cloud?ref=roadmapsh)
@@ -1,3 +1,3 @@
# Communication
Network protocols are a key part of systems today, as no system can exist in isolation - they all need to communicate with each other. You should learn about the networking protocols such as HTTP, TCP, UDP. Also, learn about the architectural styles such as RPC, REST, GraphQL and gRPC.
Network protocols are a key part of systems today, as no system can exist in isolation - they all need to communicate with each other. You should learn about the networking protocols such as HTTP, TCP, UDP. Also, learn about the architectural styles such as RPC, REST, GraphQL and gRPC.
@@ -2,7 +2,7 @@
Undo the work performed by a series of steps, which together define an eventually consistent operation, if one or more of the steps fail. Operations that follow the eventual consistency model are commonly found in cloud-hosted applications that implement complex business processes and workflows.
Learn more from the following resources:
Visit the following resources to learn more:
- [@article@Compensating Transaction pattern](https://learn.microsoft.com/en-us/azure/architecture/patterns/compensating-transaction)
- [@article@Intro to Compensation Transaction](https://en.wikipedia.org/wiki/Compensating_transaction)
@@ -2,6 +2,6 @@
Enable multiple concurrent consumers to process messages received on the same messaging channel. With multiple concurrent consumers, a system can process multiple messages concurrently to optimize throughput, to improve scalability and availability, and to balance the workload.
Learn more from the following links:
Visit the following resources to learn more:
- [@article@Competing Consumers pattern](https://learn.microsoft.com/en-us/azure/architecture/patterns/competing-consumers)
- [@article@Competing Consumers pattern](https://learn.microsoft.com/en-us/azure/architecture/patterns/competing-consumers)
@@ -2,6 +2,6 @@
Consolidate multiple tasks or operations into a single computational unit. This can increase compute resource utilization, and reduce the costs and management overhead associated with performing compute processing in cloud-hosted applications.
To learn more, visit the following links:
Visit the following resources to learn more:
- [@article@Compute Resource Consolidation pattern](https://learn.microsoft.com/en-us/azure/architecture/patterns/compute-resource-consolidation)
- [@article@Compute Resource Consolidation pattern](https://learn.microsoft.com/en-us/azure/architecture/patterns/compute-resource-consolidation)
@@ -2,12 +2,12 @@
Consistency patterns refer to the ways in which data is stored and managed in a distributed system, and how that data is made available to users and applications. There are three main types of consistency patterns:
- Strong consistency
- Weak consistency
- Eventual Consistency
* Strong consistency
* Weak consistency
* Eventual Consistency
Each of these patterns has its own advantages and disadvantages, and the choice of which pattern to use will depend on the specific requirements of the application or system.
Have a look at the following resources to learn more:
Visit the following resources to learn more:
- [@article@Consistency Patterns in Distributed Systems](https://cs.fyi/guide/consistency-patterns-week-strong-eventual/)
- [@article@Consistency Patterns in Distributed Systems](https://cs.fyi/guide/consistency-patterns-week-strong-eventual/)
@@ -4,11 +4,11 @@ A content delivery network (CDN) is a globally distributed network of proxy serv
Serving content from CDNs can significantly improve performance in two ways:
- Users receive content from data centers close to them
- Your servers do not have to serve requests that the CDN fulfills
* Users receive content from data centers close to them
* Your servers do not have to serve requests that the CDN fulfills
Learn more about CDNs from the following links:
Visit the following resources to learn more:
- [@opensource@Introduction to CDNs](https://github.com/donnemartin/system-design-primer#content-delivery-network)
- [@article@The Differences Between Push And Pull CDNs](http://www.travelblogadvice.com/technical/the-differences-between-push-and-pull-cdns/)
- [@article@Brief about Content delivery network](https://en.wikipedia.org/wiki/Content_delivery_network)
- [@article@Brief about Content delivery network](https://en.wikipedia.org/wiki/Content_delivery_network)
@@ -2,6 +2,6 @@
CQRS stands for Command and Query Responsibility Segregation, a pattern that separates read and update operations for a data store. Implementing CQRS in your application can maximize its performance, scalability, and security. The flexibility created by migrating to CQRS allows a system to better evolve over time and prevents update commands from causing merge conflicts at the domain level.
Learn more from the following links:
Visit the following resources to learn more:
- [@article@CQRS pattern](https://learn.microsoft.com/en-us/azure/architecture/patterns/cqrs)
- [@article@CQRS pattern](https://learn.microsoft.com/en-us/azure/architecture/patterns/cqrs)
@@ -2,6 +2,6 @@
CQRS stands for Command and Query Responsibility Segregation, a pattern that separates read and update operations for a data store. Implementing CQRS in your application can maximize its performance, scalability, and security. The flexibility created by migrating to CQRS allows a system to better evolve over time and prevents update commands from causing merge conflicts at the domain level.
Learn more from the following links:
Visit the following resources to learn more:
- [@article@CQRS pattern](https://learn.microsoft.com/en-us/azure/architecture/patterns/cqrs)
- [@article@CQRS pattern](https://learn.microsoft.com/en-us/azure/architecture/patterns/cqrs)
@@ -2,7 +2,7 @@
Data management is the key element of cloud applications, and influences most of the quality attributes. Data is typically hosted in different locations and across multiple servers for reasons such as performance, scalability or availability, and this can present a range of challenges. For example, data consistency must be maintained, and data will typically need to be synchronized across different locations.
Learn more from the following links:
Visit the following resources to learn more:
- [@article@Data management patterns](https://learn.microsoft.com/en-us/azure/architecture/patterns/category/data-management)
- [@feed@Explore top posts about Data Management](https://app.daily.dev/tags/data-management?ref=roadmapsh)
- [@feed@Explore top posts about Data Management](https://app.daily.dev/tags/data-management?ref=roadmapsh)
@@ -2,14 +2,15 @@
Your database usually includes some level of caching in a default configuration, optimized for a generic use case. Tweaking these settings for specific usage patterns can further boost performance. it's like having a quick-access memory for frequently used data in applications. Here's a simplified explanation:
1. **Quick Access**: Imagine you're looking up information in a big library (the database). Instead of going to the library every time you need the same book (data), you keep a copy of it on your desk (cache).
1. **Quick Access**: Imagine you're looking up information in a big library (the database). Instead of going to the library every time you need the same book (data), you keep a copy of it on your desk (cache).
2. **Faster Retrieval**: When you need that book again, you first check your desk (cache). If it's there, great! You get it right away without going to the library (database) again.
3. **Saving Time**: If the book isn't on your desk (cache miss), you go to the library (database) to get it. But you make sure to put a copy on your desk for next time, so you won't have to go to the library again if you need it soon.
4. **Different Types**: There are different ways to do this caching. You can cache the results of searches (like bookmarking), whole pieces of information (like keeping a paper copy), or even entire web pages (like saving a snapshot).
5. **Benefits**: By keeping frequently used data close by, you save time and reduce the strain on the library (database). It's like having your most-used books right at your fingertips, making your work faster and more efficient.
2. **Faster Retrieval**: When you need that book again, you first check your desk (cache). If it's there, great! You get it right away without going to the library (database) again.
3. **Saving Time**: If the book isn't on your desk (cache miss), you go to the library (database) to get it. But you make sure to put a copy on your desk for next time, so you won't have to go to the library again if you need it soon.
4. **Different Types**: There are different ways to do this caching. You can cache the results of searches (like bookmarking), whole pieces of information (like keeping a paper copy), or even entire web pages (like saving a snapshot).
5. **Benefits**: By keeping frequently used data close by, you save time and reduce the strain on the library (database). It's like having your most-used books right at your fingertips, making your work faster and more efficient.
However, it's important to keep the cached data up to date. Otherwise, you might end up with outdated information, like using an old edition of a book instead of the latest one. So, managing this cache properly is key to keeping things running smoothly.
However, it's important to keep the cached data up to date. Otherwise, you might end up with outdated information, like using an old edition of a book instead of the latest one. So, managing this cache properly is key to keeping things running smoothly.
@@ -2,13 +2,13 @@
Picking the right database for a system is an important decision, as it can have a significant impact on the performance, scalability, and overall success of the system. Some of the key reasons why it's important to pick the right database include:
- Performance: Different databases have different performance characteristics, and choosing the wrong one can lead to poor performance and slow response times.
- Scalability: As the system grows and the volume of data increases, the database needs to be able to scale accordingly. Some databases are better suited for handling large amounts of data than others.
- Data Modeling: Different databases have different data modeling capabilities and choosing the right one can help to keep the data consistent and organized.
- Data Integrity: Different databases have different capabilities for maintaining data integrity, such as enforcing constraints, and can have different levels of data security.
- Support and maintenance: Some databases have more active communities and better documentation, making it easier to find help and resources.
* Performance: Different databases have different performance characteristics, and choosing the wrong one can lead to poor performance and slow response times.
* Scalability: As the system grows and the volume of data increases, the database needs to be able to scale accordingly. Some databases are better suited for handling large amounts of data than others.
* Data Modeling: Different databases have different data modeling capabilities and choosing the right one can help to keep the data consistent and organized.
* Data Integrity: Different databases have different capabilities for maintaining data integrity, such as enforcing constraints, and can have different levels of data security.
* Support and maintenance: Some databases have more active communities and better documentation, making it easier to find help and resources.
Overall, by choosing the right database, you can ensure that your system will perform well, scale as needed, and be maintainable in the long run.
Visit the following resources to learn more:
- [@video@Scaling up to your first 10 million users](https://www.youtube.com/watch?v=kKjm4ehYiMs)
- [@feed@Explore top posts about Backend Development](https://app.daily.dev/tags/backend?ref=roadmapsh)
- [@feed@Explore top posts about Backend Development](https://app.daily.dev/tags/backend?ref=roadmapsh)
@@ -4,6 +4,6 @@ Denormalization attempts to improve read performance at the expense of some writ
Once data becomes distributed with techniques such as federation and sharding, managing joins across data centers further increases complexity. Denormalization might circumvent the need for such complex joins.
To learn more, visit the following links:
Visit the following resources to learn more:
- [@article@Denormalization](https://en.wikipedia.org/wiki/Denormalization)
- [@article@Denormalization](https://en.wikipedia.org/wiki/Denormalization)
@@ -2,7 +2,7 @@
The deployment stamp pattern involves provisioning, managing, and monitoring a heterogeneous group of resources to host and operate multiple workloads or tenants. Each individual copy is called a stamp, or sometimes a service unit, scale unit, or cell. In a multi-tenant environment, every stamp or scale unit can serve a predefined number of tenants. Multiple stamps can be deployed to scale the solution almost linearly and serve an increasing number of tenants. This approach can improve the scalability of your solution, allow you to deploy instances across multiple regions, and separate your customer data.
To learn more visit the following links:
Visit the following resources to learn more:
- [@article@Deployment Stamps pattern](https://learn.microsoft.com/en-us/azure/architecture/patterns/deployment-stamp)
- [@article@Deployment Stamps 101](https://blog.devgenius.io/deployment-stamps-101-7c04a6f704a2)
@@ -2,7 +2,7 @@
The deployment stamp pattern involves provisioning, managing, and monitoring a heterogeneous group of resources to host and operate multiple workloads or tenants. Each individual copy is called a stamp, or sometimes a service unit, scale unit, or cell. In a multi-tenant environment, every stamp or scale unit can serve a predefined number of tenants. Multiple stamps can be deployed to scale the solution almost linearly and serve an increasing number of tenants. This approach can improve the scalability of your solution, allow you to deploy instances across multiple regions, and separate your customer data.
To learn more visit the following links:
Visit the following resources to learn more:
- [@article@Deployment Stamps pattern](https://learn.microsoft.com/en-us/azure/architecture/patterns/deployment-stamp)
- [@article@Deployment Stamps 101](https://blog.devgenius.io/deployment-stamps-101-7c04a6f704a2)
@@ -2,6 +2,6 @@
Good design encompasses factors such as consistency and coherence in component design and deployment, maintainability to simplify administration and development, and reusability to allow components and subsystems to be used in other applications and in other scenarios. Decisions made during the design and implementation phase have a huge impact on the quality and the total cost of ownership of cloud hosted applications and services.
To learn more, visit the following links:
Visit the following resources to learn more:
- [@article@Design and implementation patterns](https://learn.microsoft.com/en-us/azure/architecture/patterns/category/design-implementation)
- [@article@Design and implementation patterns](https://learn.microsoft.com/en-us/azure/architecture/patterns/category/design-implementation)
@@ -4,6 +4,6 @@ A document store is centered around documents (XML, JSON, binary, etc), where a
Based on the underlying implementation, documents are organized by collections, tags, metadata, or directories. Although documents can be organized or grouped together, documents may have fields that are completely different from each other.
To learn more, visit the following links:
Visit the following resources to learn more:
- [@article@Document-oriented database](https://en.wikipedia.org/wiki/Document-oriented_database)
- [@article@Document-oriented database](https://en.wikipedia.org/wiki/Document-oriented_database)
@@ -1,24 +1,24 @@
# Domain Name System
A Domain Name System (DNS) translates a domain name such as www.example.com to an IP address.
A Domain Name System (DNS) translates a domain name such as [www.example.com](http://www.example.com) to an IP address.
DNS is hierarchical, with a few authoritative servers at the top level. Your router or ISP provides information about which DNS server(s) to contact when doing a lookup. Lower level DNS servers cache mappings, which could become stale due to DNS propagation delays. DNS results can also be cached by your browser or OS for a certain period of time, determined by the time to live (TTL).
- NS record (name server) - Specifies the DNS servers for your domain/subdomain.
- MX record (mail exchange) - Specifies the mail servers for accepting messages.
- A record (address) - Points a name to an IP address.
- CNAME (canonical) - Points a name to another name or CNAME (example.com to www.example.com) or to an A record.
* NS record (name server) - Specifies the DNS servers for your domain/subdomain.
* MX record (mail exchange) - Specifies the mail servers for accepting messages.
* A record (address) - Points a name to an IP address.
* CNAME (canonical) - Points a name to another name or CNAME ([example.com](http://example.com) to [www.example.com](http://www.example.com)) or to an A record.
Services such as [CloudFlare](https://www.cloudflare.com/dns/) and [Route53](https://aws.amazon.com/route53/) provide managed DNS services. Some DNS services can route traffic through various methods:
- [@article@Weighted Round Robin](https://www.jscape.com/blog/load-balancing-algorithms)
- Prevent traffic from going to servers under maintenance
- Balance between varying cluster sizes
- A/B testing
- [@article@Latency Based](https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/routing-policy.html#routing-policy-latency)
- [@article@Geolocation Based](https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/routing-policy.html#routing-policy-geo)
* [@article@Weighted Round Robin](https://www.jscape.com/blog/load-balancing-algorithms)
* Prevent traffic from going to servers under maintenance
* Balance between varying cluster sizes
* A/B testing
* [@article@Latency Based](https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/routing-policy.html#routing-policy-latency)
* [@article@Geolocation Based](https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/routing-policy.html#routing-policy-geo)
To learn more, visit the following links:
Visit the following resources to learn more:
- [@opensource@Getting started with Domain Name System](https://github.com/donnemartin/system-design-primer#domain-name-system)
- [@article@What is DNS?](https://www.cloudflare.com/learning/dns/what-is-dns/)
- [@article@What is DNS?](https://www.cloudflare.com/learning/dns/what-is-dns/)
@@ -2,10 +2,10 @@
Event-driven invocation uses a trigger to start the background task. Examples of using event-driven triggers include:
- The UI or another job places a message in a queue. The message contains data about an action that has taken place, such as the user placing an order. The background task listens on this queue and detects the arrival of a new message. It reads the message and uses the data in it as the input to the background job. This pattern is known as asynchronous message-based communication.
- The UI or another job saves or updates a value in storage. The background task monitors the storage and detects changes. It reads the data and uses it as the input to the background job.
- The UI or another job makes a request to an endpoint, such as an HTTPS URI, or an API that is exposed as a web service. It passes the data that is required to complete the background task as part of the request. The endpoint or web service invokes the background task, which uses the data as its input.
* The UI or another job places a message in a queue. The message contains data about an action that has taken place, such as the user placing an order. The background task listens on this queue and detects the arrival of a new message. It reads the message and uses the data in it as the input to the background job. This pattern is known as asynchronous message-based communication.
* The UI or another job saves or updates a value in storage. The background task monitors the storage and detects changes. It reads the data and uses it as the input to the background job.
* The UI or another job makes a request to an endpoint, such as an HTTPS URI, or an API that is exposed as a web service. It passes the data that is required to complete the background task as part of the request. The endpoint or web service invokes the background task, which uses the data as its input.
Learn more from the following links:
Visit the following resources to learn more:
- [@article@Background Jobs - Event Driven Triggers](https://learn.microsoft.com/en-us/azure/architecture/best-practices/background-jobs#event-driven-triggers)
- [@article@Background Jobs - Event Driven Triggers](https://learn.microsoft.com/en-us/azure/architecture/best-practices/background-jobs#event-driven-triggers)
@@ -2,7 +2,7 @@
Instead of storing just the current state of the data in a domain, use an append-only store to record the full series of actions taken on that data. The store acts as the system of record and can be used to materialize the domain objects. This can simplify tasks in complex domains, by avoiding the need to synchronize the data model and the business domain, while improving performance, scalability, and responsiveness. It can also provide consistency for transactional data, and maintain full audit trails and history that can enable compensating actions.
Learn more from the following links:
Visit the following resources to learn more:
- [@article@Event Sourcing pattern](https://learn.microsoft.com/en-us/azure/architecture/patterns/event-sourcing)
- [@feed@Explore top posts about Architecture](https://app.daily.dev/tags/architecture?ref=roadmapsh)
- [@feed@Explore top posts about Architecture](https://app.daily.dev/tags/architecture?ref=roadmapsh)
@@ -2,6 +2,6 @@
Eventual consistency is a form of Weak Consistency. After an update is made to the data, it will be eventually visible to any subsequent read operations. The data is replicated in an asynchronous manner, ensuring that all copies of the data are eventually updated.
To learn more, visit the following links:
Visit the following resources to learn more:
- [@article@Consistency Patterns in Distributed Systems](https://cs.fyi/guide/consistency-patterns-week-strong-eventual/)
- [@article@Consistency Patterns in Distributed Systems](https://cs.fyi/guide/consistency-patterns-week-strong-eventual/)
@@ -2,6 +2,6 @@
Move configuration information out of the application deployment package to a centralized location. This can provide opportunities for easier management and control of configuration data, and for sharing configuration data across applications and application instances.
To learn more, visit the following links:
Visit the following resources to learn more:
- [@article@External Configuration Store pattern](https://learn.microsoft.com/en-us/azure/architecture/patterns/external-configuration-store)
- [@article@External Configuration Store pattern](https://learn.microsoft.com/en-us/azure/architecture/patterns/external-configuration-store)
@@ -4,11 +4,11 @@ Extraneous fetching in system design refers to the practice of retrieving more d
Extraneous fetching can lead to a number of issues, such as:
- Performance degradation
- Increased resource utilization
- Increased network traffic
- Poor user experience
* Performance degradation
* Increased resource utilization
* Increased network traffic
* Poor user experience
Visit the following links to learn more:
Visit the following resources to learn more:
- [@article@Extraneous Fetching antipattern](https://learn.microsoft.com/en-us/azure/architecture/antipatterns/extraneous-fetching/)
- [@article@Extraneous Fetching antipattern](https://learn.microsoft.com/en-us/azure/architecture/antipatterns/extraneous-fetching/)
@@ -6,7 +6,8 @@ In a failover system, there is a primary component that is responsible for handl
Failover can be implemented in various ways, such as active-passive, active-active, and hot-standby.
## Active-passive
Active-passive
--------------
With active-passive fail-over, heartbeats are sent between the active and the passive server on standby. If the heartbeat is interrupted, the passive server takes over the active's IP address and resumes service.
@@ -14,7 +15,8 @@ The length of downtime is determined by whether the passive server is already ru
Active-passive failover can also be referred to as master-slave failover.
## Active-active
Active-active
-------------
In active-active, both servers are managing traffic, spreading the load between them.
@@ -22,11 +24,12 @@ If the servers are public-facing, the DNS would need to know about the public IP
Active-active failover can also be referred to as master-master failover.
## Disadvantages of Failover
Disadvantages of Failover
-------------------------
- Fail-over adds more hardware and additional complexity.
- There is a potential for loss of data if the active system fails before any newly written data can be replicated to the passive.
* Fail-over adds more hardware and additional complexity.
* There is a potential for loss of data if the active system fails before any newly written data can be replicated to the passive.
To learn more visit the following links:
Visit the following resources to learn more:
- [@article@Fail Over Pattern - High Availability](https://www.filecloud.com/blog/2015/12/architectural-patterns-for-high-availability/)
- [@article@Fail Over Pattern - High Availability](https://www.filecloud.com/blog/2015/12/architectural-patterns-for-high-availability/)
@@ -2,6 +2,6 @@
Delegate authentication to an external identity provider. This can simplify development, minimize the requirement for user administration, and improve the user experience of the application.
To learn more, visit the following links:
Visit the following resources to learn more:
- [@article@Federated Identity pattern](https://learn.microsoft.com/en-us/azure/architecture/patterns/federated-identity)
@@ -1,3 +1,3 @@
# Federation
Federation (or functional partitioning) splits up databases by function. For example, instead of a single, monolithic database, you could have three databases: forums, users, and products, resulting in less read and write traffic to each database and therefore less replication lag. Smaller databases result in more data that can fit in memory, which in turn results in more cache hits due to improved cache locality. With no single central master serializing writes you can write in parallel, increasing throughput.
Federation (or functional partitioning) splits up databases by function. For example, instead of a single, monolithic database, you could have three databases: forums, users, and products, resulting in less read and write traffic to each database and therefore less replication lag. Smaller databases result in more data that can fit in memory, which in turn results in more cache hits due to improved cache locality. With no single central master serializing writes you can write in parallel, increasing throughput.
@@ -2,6 +2,6 @@
Protect applications and services using a dedicated host instance that acts as a broker between clients and the application or service, validates and sanitizes requests, and passes requests and data between them. This can provide an additional layer of security and limit the system's attack surface.
Learn more from the following resources:
Visit the following resources to learn more:
- [@article@Gatekeeper pattern](https://learn.microsoft.com/en-us/azure/architecture/patterns/gatekeeper)
@@ -2,6 +2,6 @@
Use a gateway to aggregate multiple individual requests into a single request. This pattern is useful when a client must make multiple calls to different backend systems to perform an operation.
To learn more, visit the following links:
Visit the following resources to learn more:
- [@article@Gateway Aggregation pattern](https://learn.microsoft.com/en-us/azure/architecture/patterns/gateway-aggregation)
- [@article@Gateway Aggregation pattern](https://learn.microsoft.com/en-us/azure/architecture/patterns/gateway-aggregation)
@@ -2,6 +2,6 @@
Offload shared or specialized service functionality to a gateway proxy. This pattern can simplify application development by moving shared service functionality, such as the use of SSL certificates, from other parts of the application into the gateway.
To learn more, visit the following links:
Visit the following resources to learn more:
- [@article@Gateway Offloading pattern](https://learn.microsoft.com/en-us/azure/architecture/patterns/gateway-offloading)
- [@article@Gateway Offloading pattern](https://learn.microsoft.com/en-us/azure/architecture/patterns/gateway-offloading)
@@ -2,10 +2,10 @@
Route requests to multiple services or multiple service instances using a single endpoint. The pattern is useful when you want to:
- Expose multiple services on a single endpoint and route to the appropriate service based on the request
- Expose multiple instances of the same service on a single endpoint for load balancing or availability purposes
- Expose differing versions of the same service on a single endpoint and route traffic across the different versions
* Expose multiple services on a single endpoint and route to the appropriate service based on the request
* Expose multiple instances of the same service on a single endpoint for load balancing or availability purposes
* Expose differing versions of the same service on a single endpoint and route traffic across the different versions
To learn more, visit the following links:
Visit the following resources to learn more:
- [@article@Gateway Routing pattern](https://learn.microsoft.com/en-us/azure/architecture/patterns/gateway-routing)
- [@article@Gateway Routing pattern](https://learn.microsoft.com/en-us/azure/architecture/patterns/gateway-routing)
@@ -2,6 +2,6 @@
The Geode pattern involves deploying a collection of backend services into a set of geographical nodes, each of which can service any request for any client in any region. This pattern allows serving requests in an active-active style, improving latency and increasing availability by distributing request processing around the globe.
To learn more visit the following links:
Visit the following resources to learn more:
- [@article@Geode pattern](https://learn.microsoft.com/en-us/azure/architecture/patterns/geodes)
- [@article@Geode pattern](https://learn.microsoft.com/en-us/azure/architecture/patterns/geodes)
@@ -2,7 +2,7 @@
The Geode pattern involves deploying a collection of backend services into a set of geographical nodes, each of which can service any request for any client in any region. This pattern allows serving requests in an active-active style, improving latency and increasing availability by distributing request processing around the globe.
To learn more visit the following links:
Visit the following resources to learn more:
- [@article@Geode pattern](https://learn.microsoft.com/en-us/azure/architecture/patterns/geodes)
- [@article@Geode Formation, Types & Appearance | What is a Geode?](https://study.com/academy/lesson/geode-formation-types-appearance.html)
@@ -4,8 +4,8 @@ In a graph database, each node is a record and each arc is a relationship betwee
Graphs databases offer high performance for data models with complex relationships, such as a social network. They are relatively new and are not yet widely-used; it might be more difficult to find development tools and resources. Many graphs can only be accessed with REST APIs.
Learn more from the following links:
Visit the following resources to learn more:
- [@article@Graph database](https://en.wikipedia.org/wiki/Graph_database)
- [@video@Introduction to NoSQL](https://www.youtube.com/watch?v=qI_g07C_Q5I)
- [@feed@Explore top posts about Backend Development](https://app.daily.dev/tags/backend?ref=roadmapsh)
- [@feed@Explore top posts about Backend Development](https://app.daily.dev/tags/backend?ref=roadmapsh)
@@ -2,8 +2,8 @@
GraphQL is a query language and runtime for building APIs. It allows clients to define the structure of the data they need and the server will return exactly that. This is in contrast to traditional REST APIs, where the server exposes a fixed set of endpoints and the client must work with the data as it is returned.
To learn more, visit the following links:
Visit the following resources to learn more:
- [@article@GraphQL Server](https://www.howtographql.com/basics/3-big-picture/)
- [@article@What is GraphQL?](https://www.redhat.com/en/topics/api/what-is-graphql)
- [@feed@Explore top posts about GraphQL](https://app.daily.dev/tags/graphql?ref=roadmapsh)
- [@feed@Explore top posts about GraphQL](https://app.daily.dev/tags/graphql?ref=roadmapsh)
@@ -2,7 +2,7 @@
gRPC is a high-performance, open-source framework for building remote procedure call (RPC) APIs. It is based on the Protocol Buffers data serialization format and supports a variety of programming languages, including C#, Java, and Python.
Learn more from the following links:
Visit the following resources to learn more:
- [@article@What Is gRPC?](https://www.wallarm.com/what/the-concept-of-grpc)
- [@feed@Explore top posts about gRPC](https://app.daily.dev/tags/grpc?ref=roadmapsh)
- [@feed@Explore top posts about gRPC](https://app.daily.dev/tags/grpc?ref=roadmapsh)
@@ -2,7 +2,7 @@
Implement functional checks in an application that external tools can access through exposed endpoints at regular intervals. This can help to verify that applications and services are performing correctly.
To learn more visit the following links:
Visit the following resources to learn more:
- [@article@Health Endpoint Monitoring pattern](https://learn.microsoft.com/en-us/azure/architecture/patterns/health-endpoint-monitoring)
- [@article@Explaining the health endpoint monitoring pattern](https://www.oreilly.com/library/view/java-ee-8/9781788830621/5012c01e-90ca-4809-a210-d3736574f5b3.xhtml)
@@ -2,7 +2,7 @@
Implement functional checks in an application that external tools can access through exposed endpoints at regular intervals. This can help to verify that applications and services are performing correctly.
To learn more visit the following links:
Visit the following resources to learn more:
- [@article@Health Endpoint Monitoring pattern](https://learn.microsoft.com/en-us/azure/architecture/patterns/health-endpoint-monitoring)
- [@article@Explaining the health endpoint monitoring pattern](https://www.oreilly.com/library/view/java-ee-8/9781788830621/5012c01e-90ca-4809-a210-d3736574f5b3.xhtml)
@@ -2,7 +2,7 @@
Implement functional checks in an application that external tools can access through exposed endpoints at regular intervals. This can help to verify that applications and services are performing correctly.
To learn more visit the following links:
Visit the following resources to learn more:
- [@article@Health Endpoint Monitoring pattern](https://learn.microsoft.com/en-us/azure/architecture/patterns/health-endpoint-monitoring)
- [@article@Explaining the health endpoint monitoring pattern](https://www.oreilly.com/library/view/java-ee-8/9781788830621/5012c01e-90ca-4809-a210-d3736574f5b3.xhtml)
@@ -2,7 +2,7 @@
A system is healthy if it is running and capable of processing requests. The purpose of health monitoring is to generate a snapshot of the current health of the system so that you can verify that all components of the system are functioning as expected.
Learn more from the following:
Visit the following resources to learn more:
- [@article@Health Monitoring of a System](https://learn.microsoft.com/en-us/azure/architecture/best-practices/monitoring#health-monitoring)
- [@feed@Explore top posts about Monitoring](https://app.daily.dev/tags/monitoring?ref=roadmapsh)
- [@feed@Explore top posts about Monitoring](https://app.daily.dev/tags/monitoring?ref=roadmapsh)
@@ -2,6 +2,6 @@
Azure infrastructure is composed of geographies, regions, and Availability Zones, which limit the blast radius of a failure and therefore limit potential impact to customer applications and data. The Azure Availability Zones construct was developed to provide a software and networking solution to protect against datacenter failures and to provide increased high availability (HA) to our customers. With HA architecture there is a balance between high resilience, low latency, and cost.
Learn more from the following links:
Visit the following resources to learn more:
- [@article@High availability Patterns](https://learn.microsoft.com/en-us/azure/architecture/framework/resiliency/reliability-patterns#high-availability)
- [@article@High availability Patterns](https://learn.microsoft.com/en-us/azure/architecture/framework/resiliency/reliability-patterns#high-availability)
@@ -2,9 +2,10 @@
Load balancers can also help with horizontal scaling, improving performance and availability. Scaling out using commodity machines is more cost efficient and results in higher availability than scaling up a single server on more expensive hardware, called Vertical Scaling. It is also easier to hire for talent working on commodity hardware than it is for specialized enterprise systems.
## Disadvantages of horizontal scaling
Disadvantages of horizontal scaling
-----------------------------------
- Scaling horizontally introduces complexity and involves cloning servers
- Servers should be stateless: they should not contain any user-related data like sessions or profile pictures
- Sessions can be stored in a centralized data store such as a database (SQL, NoSQL) or a persistent cache (Redis, Memcached)
- Downstream servers such as caches and databases need to handle more simultaneous connections as upstream servers scale out.
* Scaling horizontally introduces complexity and involves cloning servers
* Servers should be stateless: they should not contain any user-related data like sessions or profile pictures
* Sessions can be stored in a centralized data store such as a database (SQL, NoSQL) or a persistent cache (Redis, Memcached)
* Downstream servers such as caches and databases need to handle more simultaneous connections as upstream servers scale out.
@@ -2,17 +2,17 @@
There are several steps that can be taken when approaching a system design:
- **Understand the problem**: Gather information about the problem you are trying to solve and the requirements of the system. Identify the users and their needs, as well as any constraints or limitations of the system.
- **Identify the scope of the system:** Define the boundaries of the system, including what the system will do and what it will not do.
- **Research and analyze existing systems:** Look at similar systems that have been built in the past and identify what worked well and what didn't. Use this information to inform your design decisions.
- **Create a high-level design:** Outline the main components of the system and how they will interact with each other. This can include a rough diagram of the system's architecture, or a flowchart outlining the process the system will follow.
- **Refine the design:** As you work on the details of the design, iterate and refine it until you have a complete and detailed design that meets all the requirements.
- **Document the design:** Create detailed documentation of your design for future reference and maintenance.
- **Continuously monitor and improve the system:** The system design is not a one-time process, it needs to be continuously monitored and improved to meet the changing requirements.
* **Understand the problem**: Gather information about the problem you are trying to solve and the requirements of the system. Identify the users and their needs, as well as any constraints or limitations of the system.
* **Identify the scope of the system:** Define the boundaries of the system, including what the system will do and what it will not do.
* **Research and analyze existing systems:** Look at similar systems that have been built in the past and identify what worked well and what didn't. Use this information to inform your design decisions.
* **Create a high-level design:** Outline the main components of the system and how they will interact with each other. This can include a rough diagram of the system's architecture, or a flowchart outlining the process the system will follow.
* **Refine the design:** As you work on the details of the design, iterate and refine it until you have a complete and detailed design that meets all the requirements.
* **Document the design:** Create detailed documentation of your design for future reference and maintenance.
* **Continuously monitor and improve the system:** The system design is not a one-time process, it needs to be continuously monitored and improved to meet the changing requirements.
Note that this is a general approach to System Design. For interview specific answers, see the following resources:
Visit the following resources to learn more:
- [@opensource@How to approach System Design?](https://github.com/donnemartin/system-design-primer#how-to-approach-a-system-design-interview-question)
- [@article@What are system design questions?](https://www.hiredintech.com/system-design)
- [@video@Intro to Architecture and Systems Design Interviews](https://www.youtube.com/watch?v=ZgdS0EUmn70)
- [@article@My System Design Template](https://leetcode.com/discuss/career/229177/My-System-Design-Template)
- [@video@Intro to Architecture and Systems Design Interviews](https://www.youtube.com/watch?v=ZgdS0EUmn70)
@@ -4,19 +4,16 @@ HTTP is a method for encoding and transporting data between a client and a serve
A basic HTTP request consists of a verb (method) and a resource (endpoint). Below are common HTTP verbs:
```
Verb | Description | Idempotent* | Safe | Cacheable |
-------|-------------------------------|-------------|------|-----------------------------------------|
GET | Reads a resource | Yes | Yes | Yes |
POST | Creates a resource or trigger | No | No | Yes if response contains freshness info |
PUT | Creates or replace a resource | Yes | No | No |
PATCH | Partially updates a resource | No | No | Yes if response contains freshness info |
DELETE | Deletes a resource | Yes | No | No |
Verb | Description | Idempotent* | Safe | Cacheable |
-------|-------------------------------|-------------|------|-----------------------------------------|
GET | Reads a resource | Yes | Yes | Yes |
POST | Creates a resource or trigger | No | No | Yes if response contains freshness info |
PUT | Creates or replace a resource | Yes | No | No |
PATCH | Partially updates a resource | No | No | Yes if response contains freshness info |
DELETE | Deletes a resource | Yes | No | No |
```
HTTP is an application layer protocol relying on lower-level protocols such as TCP and UDP.
Visit the following resources to learn more:
- [@article@Everything you need to know about HTTP](https://cs.fyi/guide/http-in-depth)
- [@article@What Is HTTP?](https://www.nginx.com/resources/glossary/http/)
- [@article@What is the difference between HTTP protocol and TCP protocol?](https://www.quora.com/What-is-the-difference-between-HTTP-protocol-and-TCP-protocol)
- [@article@What is the difference between HTTP protocol and TCP protocol?](https://www.quora.com/What-is-the-difference-between-HTTP-protocol-and-TCP-protocol)
@@ -4,7 +4,7 @@ Idempotent operations are operations that can be applied multiple times without
It is also important to understand the benefits of [idempotent](https://en.wikipedia.org/wiki/Idempotence#Computer_science_meaning) operations, especially when using message or task queues that do not guarantee _exactly once_ processing. Many queueing systems guarantee _at least once_ message delivery or processing. These systems are not completely synchronized, for instance, across geographic regions, which simplifies some aspects of their implementation or design. Designing the operations that a task queue executes to be idempotent allows one to use a queueing system that has accepted this design trade-off.
To learn more, visit the following links:
Visit the following resources to learn more:
- [@article@What is an idempotent operation?](https://stackoverflow.com/questions/1077412/what-is-an-idempotent-operation)
- [@article@Overview of Idempotent Operation](https://www.baeldung.com/cs/idempotent-operations)
- [@article@Overview of Idempotent Operation](https://www.baeldung.com/cs/idempotent-operations)
@@ -2,6 +2,6 @@
Improper instantiation in system design refers to the practice of creating unnecessary instances of an object, class or service, which can lead to performance and scalability issues. This can happen when the system is not properly designed, when the code is not written in an efficient way, or when the code is not optimized for the specific use case.
Learn more from the following links:
Visit the following resources to learn more:
- [@article@Improper Instantiation antipattern](https://learn.microsoft.com/en-us/azure/architecture/antipatterns/improper-instantiation/)
- [@article@Improper Instantiation antipattern](https://learn.microsoft.com/en-us/azure/architecture/antipatterns/improper-instantiation/)
@@ -2,6 +2,6 @@
Create indexes over the fields in data stores that are frequently referenced by queries. This pattern can improve query performance by allowing applications to more quickly locate the data to retrieve from a data store.
Learn more from the following links:
Visit the following resources to learn more:
- [@article@Index Table pattern](https://learn.microsoft.com/en-us/azure/architecture/patterns/index-table)
- [@article@Index Table pattern](https://learn.microsoft.com/en-us/azure/architecture/patterns/index-table)
@@ -2,7 +2,7 @@
Instrumentation is a critical part of the monitoring process. You can make meaningful decisions about the performance and health of a system only if you first capture the data that enables you to make these decisions. The information that you gather by using instrumentation should be sufficient to enable you to assess performance, diagnose problems, and make decisions without requiring you to sign in to a remote production server to perform tracing (and debugging) manually. Instrumentation data typically comprises metrics and information that's written to trace logs.
Learn more from the following links:
Visit the following resources to learn more:
- [@article@Instrumenting an application](https://learn.microsoft.com/en-us/azure/architecture/best-practices/monitoring#instrumenting-an-application)
- [@article@Instrumenting using Open Telemetry](https://opentelemetry.io/docs/concepts/what-is-opentelemetry)
- [@article@Instrumenting using Open Telemetry](https://opentelemetry.io/docs/concepts/what-is-opentelemetry)
@@ -6,4 +6,4 @@ It involves taking a problem statement, breaking it down into smaller components
In software engineering, system design is a phase in the software development process that focuses on the high-level design of a software system, including the architecture and components.
It is also one of the important aspects of the interview process for software engineers. Most of the companies have a dedicated system design interview round, where they ask the candidates to design a system for a given problem statement. The candidates are expected to come up with a detailed design of the system, including the architecture, components, and their interactions. They are also expected to discuss the trade-offs involved in their design and the alternatives that they considered.
It is also one of the important aspects of the interview process for software engineers. Most of the companies have a dedicated system design interview round, where they ask the candidates to design a system for a given problem statement. The candidates are expected to come up with a detailed design of the system, including the architecture, components, and their interactions. They are also expected to discuss the trade-offs involved in their design and the alternatives that they considered.
@@ -4,7 +4,7 @@ A key-value store generally allows for `O(1)` reads and writes and is often back
Key-value stores provide high performance and are often used for simple data models or for rapidly-changing data, such as an in-memory cache layer. Since they offer only a limited set of operations, complexity is shifted to the application layer if additional operations are needed.
To learn more, visit the following links:
Visit the following resources to learn more:
- [@article@Key–value database](https://en.wikipedia.org/wiki/Key%E2%80%93value_database)
- [@article@What are the disadvantages of using a key/value table?](https://stackoverflow.com/questions/4056093/what-are-the-disadvantages-of-using-a-key-value-table-over-nullable-columns-or)
- [@article@What are the disadvantages of using a key/value table?](https://stackoverflow.com/questions/4056093/what-are-the-disadvantages-of-using-a-key-value-table-over-nullable-columns-or)
@@ -4,7 +4,7 @@ Latency and throughput are two important measures of a system's performance. **L
Generally, you should aim for maximal throughput with acceptable latency.
Learn more from the following links:
Visit the following resources to learn more:
- [@article@System Design: Latency vs Throughput](https://cs.fyi/guide/latency-vs-throughput/)
- [@article@Understanding Latency versus Throughput](https://community.cadence.com/cadence_blogs_8/b/fv/posts/understanding-latency-vs-throughput)
@@ -2,6 +2,6 @@
Layer 4 load balancers look at info at the transport layer to decide how to distribute requests. Generally, this involves the source, destination IP addresses, and ports in the header, but not the contents of the packet. Layer 4 load balancers forward network packets to and from the upstream server, performing Network Address Translation (NAT).
Learn more from the following links:
Visit the following resources to learn more:
- [@article@Layer 4 Load Balancing](https://www.f5.com/glossary/layer-4-load-balancing)
@@ -2,4 +2,4 @@
Layer 7 load balancers look at the application layer to decide how to distribute requests. This can involve contents of the header, message, and cookies. Layer 7 load balancers terminate network traffic, reads the message, makes a load-balancing decision, then opens a connection to the selected server. For example, a layer 7 load balancer can direct video traffic to servers that host videos while directing more sensitive user billing traffic to security-hardened servers.
At the cost of flexibility, layer 4 load balancing requires less time and computing resources than Layer 7, although the performance impact can be minimal on modern commodity hardware.
At the cost of flexibility, layer 4 load balancing requires less time and computing resources than Layer 7, although the performance impact can be minimal on modern commodity hardware.
@@ -1,17 +1,18 @@
# Load Balancer vs Reverse Proxy
- Deploying a load balancer is useful when you have multiple servers. Often, load balancers route traffic to a set of servers serving the same function.
- Reverse proxies can be useful even with just one web server or application server, opening up the benefits described in the previous section.
- Solutions such as NGINX and HAProxy can support both layer 7 reverse proxying and load balancing.
* Deploying a load balancer is useful when you have multiple servers. Often, load balancers route traffic to a set of servers serving the same function.
* Reverse proxies can be useful even with just one web server or application server, opening up the benefits described in the previous section.
* Solutions such as NGINX and HAProxy can support both layer 7 reverse proxying and load balancing.
## Disadvantages of Reverse Proxy:
Disadvantages of Reverse Proxy:
-------------------------------
- Introducing a reverse proxy results in increased complexity.
- A single reverse proxy is a single point of failure, configuring multiple reverse proxies (ie a failover) further increases complexity.
* Introducing a reverse proxy results in increased complexity.
* A single reverse proxy is a single point of failure, configuring multiple reverse proxies (ie a failover) further increases complexity.
To learn more visit the following links:
Visit the following resources to learn more:
- [@article@Reverse Proxy vs Load Balancer](https://www.nginx.com/resources/glossary/reverse-proxy-vs-load-balancer/)
- [@article@NGINX Architecture](https://www.nginx.com/blog/inside-nginx-how-we-designed-for-performance-scale/)
- [@article@HAProxy Architecture Guide](http://www.haproxy.org/download/1.2/doc/architecture.txt)
- [@article@Reverse Proxy](https://en.wikipedia.org/wiki/Reverse_proxy)
- [@article@Reverse Proxy](https://en.wikipedia.org/wiki/Reverse_proxy)
@@ -2,6 +2,6 @@
Coordinate the actions performed by a collection of collaborating instances in a distributed application by electing one instance as the leader that assumes responsibility for managing the others. This can help to ensure that instances don't conflict with each other, cause contention for shared resources, or inadvertently interfere with the work that other instances are performing.
To learn more, visit the following links:
Visit the following resources to learn more:
- [@article@Leader Election Pattern](https://learn.microsoft.com/en-us/azure/architecture/patterns/leader-election)
@@ -2,6 +2,6 @@
Coordinate the actions performed by a collection of collaborating instances in a distributed application by electing one instance as the leader that assumes responsibility for managing the others. This can help to ensure that instances don't conflict with each other, cause contention for shared resources, or inadvertently interfere with the work that other instances are performing.
To learn more, visit the following links:
Visit the following resources to learn more:
- [@article@Leader Election Pattern](https://learn.microsoft.com/en-us/azure/architecture/patterns/leader-election)
@@ -2,24 +2,25 @@
Load balancers distribute incoming client requests to computing resources such as application servers and databases. In each case, the load balancer returns the response from the computing resource to the appropriate client. Load balancers are effective at:
- Preventing requests from going to unhealthy servers
- Preventing overloading resources
- Helping to eliminate a single point of failure
* Preventing requests from going to unhealthy servers
* Preventing overloading resources
* Helping to eliminate a single point of failure
Load balancers can be implemented with hardware (expensive) or with software such as HAProxy. Additional benefits include:
- **SSL termination** - Decrypt incoming requests and encrypt server responses so backend servers do not have to perform these potentially expensive operations
- Removes the need to install X.509 certificates on each server
- **Session persistence** - Issue cookies and route a specific client's requests to same instance if the web apps do not keep track of sessions
* **SSL termination** - Decrypt incoming requests and encrypt server responses so backend servers do not have to perform these potentially expensive operations
* Removes the need to install X.509 certificates on each server
* **Session persistence** - Issue cookies and route a specific client's requests to same instance if the web apps do not keep track of sessions
## Disadvantages of load balancer
Disadvantages of load balancer
------------------------------
- The load balancer can become a performance bottleneck if it does not have enough resources or if it is not configured properly.
- Introducing a load balancer to help eliminate a single point of failure results in increased complexity.
- A single load balancer is a single point of failure, configuring multiple load balancers further increases complexity.
* The load balancer can become a performance bottleneck if it does not have enough resources or if it is not configured properly.
* Introducing a load balancer to help eliminate a single point of failure results in increased complexity.
* A single load balancer is a single point of failure, configuring multiple load balancers further increases complexity.
To learn more, visit the following links:
Visit the following resources to learn more:
- [@article@Scalability](https://cs.fyi/guide/scalability-for-dummies)
- [@article@NGINX Architecture](https://www.nginx.com/blog/inside-nginx-how-we-designed-for-performance-scale/)
- [@article@HAProxy Architecture Guide](http://www.haproxy.org/download/1.2/doc/architecture.txt)
- [@article@HAProxy Architecture Guide](http://www.haproxy.org/download/1.2/doc/architecture.txt)
@@ -4,7 +4,7 @@ A load balancer is a software or hardware device that keeps any one server from
There are two primary approaches to load balancing. Dynamic load balancing uses algorithms that take into account the current state of each server and distribute traffic accordingly. Static load balancing distributes traffic without making these adjustments. Some static algorithms send an equal amount of traffic to each server in a group, either in a specified order or at random.
To learn more, visit the following links:
Visit the following resources to learn more:
- [@article@Types of Load Balancing Algorithms](https://www.cloudflare.com/learning/performance/types-of-load-balancing-algorithms/)
- [@feed@Explore top posts about Algorithms](https://app.daily.dev/tags/algorithms?ref=roadmapsh)
- [@feed@Explore top posts about Algorithms](https://app.daily.dev/tags/algorithms?ref=roadmapsh)
@@ -2,6 +2,6 @@
Generate prepopulated views over the data in one or more data stores when the data isn't ideally formatted for required query operations. This can help support efficient querying and data extraction, and improve application performance.
Learn more from the following links:
Visit the following resources to learn more:
- [@article@Materialized View pattern](https://learn.microsoft.com/en-us/azure/architecture/patterns/materialized-view)
- [@article@Materialized View pattern](https://learn.microsoft.com/en-us/azure/architecture/patterns/materialized-view)
@@ -2,17 +2,17 @@
Message queues receive, hold, and deliver messages. If an operation is too slow to perform inline, you can use a message queue with the following workflow:
- An application publishes a job to the queue, then notifies the user of job status
- A worker picks up the job from the queue, processes it, then signals the job is complete
* An application publishes a job to the queue, then notifies the user of job status
* A worker picks up the job from the queue, processes it, then signals the job is complete
The user is not blocked and the job is processed in the background. During this time, the client might optionally do a small amount of processing to make it seem like the task has completed. For example, if posting a tweet, the tweet could be instantly posted to your timeline, but it could take some time before your tweet is actually delivered to all of your followers.
- [@article@Redis](https://redis.io/) is useful as a simple message broker but messages can be lost.
- [@article@RabbitMQ](https://www.rabbitmq.com/) is popular but requires you to adapt to the 'AMQP' protocol and manage your own nodes.
- [@article@AWS SQS](https://aws.amazon.com/sqs/) is hosted but can have high latency and has the possibility of messages being delivered twice.
- [@article@Apache Kafka](https://kafka.apache.org/) is a distributed event store and stream-processing platform.
* [@article@Redis](https://redis.io/) is useful as a simple message broker but messages can be lost.
* [@article@RabbitMQ](https://www.rabbitmq.com/) is popular but requires you to adapt to the 'AMQP' protocol and manage your own nodes.
* [@article@AWS SQS](https://aws.amazon.com/sqs/) is hosted but can have high latency and has the possibility of messages being delivered twice.
* [@article@Apache Kafka](https://kafka.apache.org/) is a distributed event store and stream-processing platform.
To learn more, visit the following links:
Visit the following resources to learn more:
- [@article@What is Redis?](https://redis.io/)
- [@article@RabbitMQ in Message Queues](https://www.rabbitmq.com/)
@@ -2,6 +2,6 @@
Messaging is a pattern that allows for the communication and coordination between different components or systems, using messaging technologies such as message queues, message brokers, and event buses. This pattern allows for decoupling of the sender and receiver, and can be used to build scalable and flexible systems.
Learn more from the following links:
Visit the following resources to learn more:
- [@article@Messaging Cloud Patterns](https://learn.microsoft.com/en-us/azure/architecture/patterns/category/messaging)
- [@article@Messaging Cloud Patterns](https://learn.microsoft.com/en-us/azure/architecture/patterns/category/messaging)
@@ -4,9 +4,9 @@ Related to the "Application Layer" discussion are microservices, which can be de
Pinterest, for example, could have the following microservices: user profile, follower, feed, search, photo upload, etc.
To learn more, visit the following links:
Visit the following resources to learn more:
- [@article@Introduction to Microservices](https://aws.amazon.com/microservices/)
- [@article@Microservices - Wikipedia](https://en.wikipedia.org/wiki/Microservices)
- [@article@Microservices](https://martinfowler.com/articles/microservices.html)
- [@feed@Explore top posts about Microservices](https://app.daily.dev/tags/microservices?ref=roadmapsh)
- [@feed@Explore top posts about Microservices](https://app.daily.dev/tags/microservices?ref=roadmapsh)
@@ -2,7 +2,7 @@
Distributed applications and services running in the cloud are, by their nature, complex pieces of software that comprise many moving parts. In a production environment, it's important to be able to track the way in which users use your system, trace resource utilization, and generally monitor the health and performance of your system. You can use this information as a diagnostic aid to detect and correct issues, and also to help spot potential problems and prevent them from occurring.
Visit the following to learn more:
Visit the following resources to learn more:
- [@article@Monitoring and Diagnostics Guidance](https://learn.microsoft.com/en-us/azure/architecture/best-practices/monitoring)
- [@feed@Explore top posts about Monitoring](https://app.daily.dev/tags/monitoring?ref=roadmapsh)
- [@feed@Explore top posts about Monitoring](https://app.daily.dev/tags/monitoring?ref=roadmapsh)
@@ -2,6 +2,6 @@
Monolithic Persistence refers to the use of a single, monolithic database to store all of the data for an application or system. This approach can be used for simple, small-scale systems but as the system grows and evolves it can become a bottleneck, resulting in poor scalability, limited flexibility, and increased complexity. To address these limitations, a number of approaches can be taken such as Microservices, Sharding, and NoSQL databases.
To learn more, visit the following links:
Visit the following resources to learn more:
- [@article@Monolithic Persistence antipattern](https://learn.microsoft.com/en-us/azure/architecture/antipatterns/monolithic-persistence/)
- [@article@Monolithic Persistence antipattern](https://learn.microsoft.com/en-us/azure/architecture/antipatterns/monolithic-persistence/)
@@ -4,10 +4,10 @@ No caching antipattern occurs when a cloud application that handles many concurr
When data is not cached, it can cause a number of undesirable behaviors, including:
- Repeatedly fetching the same information from a resource that is expensive to access, in terms of I/O overhead or latency.
- Repeatedly constructing the same objects or data structures for multiple requests.
- Making excessive calls to a remote service that has a service quota and throttles clients past a certain limit.
* Repeatedly fetching the same information from a resource that is expensive to access, in terms of I/O overhead or latency.
* Repeatedly constructing the same objects or data structures for multiple requests.
* Making excessive calls to a remote service that has a service quota and throttles clients past a certain limit.
In turn, these problems can lead to poor response times, increased contention in the data store, and poor scalability.
Visit the following resources to learn more:
- [@article@No Caching antipattern](https://learn.microsoft.com/en-us/azure/architecture/antipatterns/no-caching/)
- [@article@No Caching antipattern](https://learn.microsoft.com/en-us/azure/architecture/antipatterns/no-caching/)
@@ -4,10 +4,10 @@ Noisy neighbor refers to a situation in which one or more components of a system
Examples of noisy neighbor scenarios include:
- One user on a shared server utilizing a large amount of CPU or memory, leading to reduced performance for other users on the same server.
- One process on a shared server utilizing a large amount of I/O, causing other processes to experience slow I/O and increased latency.
- One application consuming a large amount of network bandwidth, causing other applications to experience reduced throughput.
* One user on a shared server utilizing a large amount of CPU or memory, leading to reduced performance for other users on the same server.
* One process on a shared server utilizing a large amount of I/O, causing other processes to experience slow I/O and increased latency.
* One application consuming a large amount of network bandwidth, causing other applications to experience reduced throughput.
Learn from the following links:
Visit the following resources to learn more:
- [@article@Noisy Neighbor antipattern](https://learn.microsoft.com/en-us/azure/architecture/antipatterns/noisy-neighbor/noisy-neighbor)
- [@article@Noisy Neighbor antipattern](https://learn.microsoft.com/en-us/azure/architecture/antipatterns/noisy-neighbor/noisy-neighbor)
@@ -4,12 +4,12 @@ Performance antipatterns in system design refer to common mistakes or suboptimal
Some of the examples of performance antipatterns include:
- **N+1 queries:** This occurs when a system makes multiple queries to a database to retrieve related data, instead of using a single query to retrieve all the necessary data.
- **Chatty interfaces:** This occurs when a system makes too many small and frequent requests to an external service or API, instead of making fewer, larger requests.
- **Unbounded data:** This occurs when a system retrieves or processes more data than is necessary for the task at hand, leading to increased resource usage and reduced performance.
- **Inefficient algorithms:** This occurs when a system uses an algorithm that is not well suited to the task at hand, leading to increased resource usage and reduced performance.
* **N+1 queries:** This occurs when a system makes multiple queries to a database to retrieve related data, instead of using a single query to retrieve all the necessary data.
* **Chatty interfaces:** This occurs when a system makes too many small and frequent requests to an external service or API, instead of making fewer, larger requests.
* **Unbounded data:** This occurs when a system retrieves or processes more data than is necessary for the task at hand, leading to increased resource usage and reduced performance.
* **Inefficient algorithms:** This occurs when a system uses an algorithm that is not well suited to the task at hand, leading to increased resource usage and reduced performance.
Learn more from the following links:
Visit the following resources to learn more:
- [@article@Performance antipatterns for cloud applications](https://learn.microsoft.com/en-us/azure/architecture/antipatterns/)
- [@feed@Explore top posts about Performance](https://app.daily.dev/tags/performance?ref=roadmapsh)
- [@feed@Explore top posts about Performance](https://app.daily.dev/tags/performance?ref=roadmapsh)
@@ -2,7 +2,7 @@
As the system is placed under more and more stress (by increasing the volume of users), the size of the datasets that these users access grows and the possibility of failure of one or more components becomes more likely. Frequently, component failure is preceded by a decrease in performance. If you're able detect such a decrease, you can take proactive steps to remedy the situation.
Learn more from following links:
Visit the following resources to learn more:
- [@article@Performance Monitoring](https://learn.microsoft.com/en-us/azure/architecture/best-practices/monitoring#performance-monitoring)
- [@feed@Explore top posts about Monitoring](https://app.daily.dev/tags/monitoring?ref=roadmapsh)
- [@feed@Explore top posts about Monitoring](https://app.daily.dev/tags/monitoring?ref=roadmapsh)
@@ -4,12 +4,12 @@ A service is **scalable** if it results in increased **performance** in a manner
Another way to look at performance vs scalability:
- If you have a **performance** problem, your system is slow for a single user.
- If you have a **scalability** problem, your system is fast for a single user but slow under heavy load.
* If you have a **performance** problem, your system is slow for a single user.
* If you have a **scalability** problem, your system is fast for a single user but slow under heavy load.
To learn more, visit the following links:
Visit the following resources to learn more:
- [@article@Scalability, Availability & Stability Patterns](https://www.slideshare.net/jboner/scalability-availability-stability-patterns/)
- [@article@A Word on Scalability](https://www.allthingsdistributed.com/2006/03/a_word_on_scalability.html)
- [@article@Performance vs Scalability](https://blog.professorbeekums.com/performance-vs-scalability/)
- [@feed@Explore top posts about Performance](https://app.daily.dev/tags/performance?ref=roadmapsh)
- [@feed@Explore top posts about Performance](https://app.daily.dev/tags/performance?ref=roadmapsh)
@@ -2,6 +2,6 @@
Decompose a task that performs complex processing into a series of separate elements that can be reused. This can improve performance, scalability, and reusability by allowing task elements that perform the processing to be deployed and scaled independently.
To learn more, visit the following links:
Visit the following resources to learn more:
- [@article@Pipe and Filter Architectural Style](https://learn.microsoft.com/en-us/azure/architecture/patterns/pipes-and-filters)
- [@article@Pipe and Filter Architectural Style](https://learn.microsoft.com/en-us/azure/architecture/patterns/pipes-and-filters)
@@ -2,6 +2,6 @@
Decompose a task that performs complex processing into a series of separate elements that can be reused. This can improve performance, scalability, and reusability by allowing task elements that perform the processing to be deployed and scaled independently.
Learn more from the following links:
Visit the following resources to learn more:
- [@article@Pipes and Filters pattern](https://learn.microsoft.com/en-us/azure/architecture/patterns/pipes-and-filters)
- [@article@Pipes and Filters pattern](https://learn.microsoft.com/en-us/azure/architecture/patterns/pipes-and-filters)
@@ -2,6 +2,6 @@
Prioritize requests sent to services so that requests with a higher priority are received and processed more quickly than those with a lower priority. This pattern is useful in applications that offer different service level guarantees to individual clients.
Learn more from the following links:
Visit the following resources to learn more:
- [@article@Priority Queue pattern](https://learn.microsoft.com/en-us/azure/architecture/patterns/priority-queue)
- [@article@Priority Queue pattern](https://learn.microsoft.com/en-us/azure/architecture/patterns/priority-queue)

Some files were not shown because too many files have changed in this diff Show More