Performance Efficiency - Design Principles and Tradeoffs Flashcards
1
Q
Design Principles
A
- Go Global
- Think serverless
- Use new technologies
- Experiment often
- Use the right tool for the task
2
Q
Tradeoffs
A
- Always it depends
- Characteristics that affect each other: processing / maintenance / request time, cost, complexity, memory, and efficiency
3
Q
Implementing tradeoffs - SQS
A
- Tradeoff: requests processing time vs efficiency (resource utilization)
- Decouples different parts of the application
- Both sides can scale independently
- Determine the acceptable delay
4
Q
Implementing tradeoffs - Data partitioning
A
- Tradeoff: complexity and consistency vs processing / maintenance time
- In a RDBMS it’s usually not directly implemented by the database, which increases complexity vs NoSQL which offers less complexity and consistency
- Data distribution across various partition keys
- Increases the maintenance depending on database. For example DynamoDB needs less maintenance
5
Q
Implementing tradeoffs - Caching
A
- Tradeoff: memory (increased), consistency (reduced) vs fastest request times
- Use cache to increase performance
- Utilize database read replicas to reduce workload of primary servers
- Employ CloudFront as CDN to reduce latency
6
Q
Compression
A
- Tradeoff: time to compress / decompress vs memory (reduced because of size)
- Compress code assets such as CSS or Javascript
- Compress files to reduce storage and transmission time