03-sustainable software engineering Flashcards

(10 cards)

1
Q

⭐1

Identify and describe key sustainability drivers influencing software engineering practicesand decision-making.

A
  • Reduces environmental impact, e.g. through energy efficient code, resource optimization, and mindful infrastructure use.
  • Supports economic sustainability, e.g. by ensuring cost efficiency, scalability, and longevity of software systems.
  • Promotes social sustainability, e.g. by enabling accessibility, fairness, and positive societal outcomes.
  • Enhances technical sustainability, e.g. through maintainable, adaptable, and resilient architectures.
  • Respects individual sustainability, e.g. by considering developer well-being, ethical responsibility, and the long-term usability of the system
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

⭐2

Explain and compare concrete “green” software tactics and design patterns that promote energy efficiency and resource optimization.

CLUE
Cloud-native Sustainability Evaluator

A

Architecture Styles for Sustainability
Patterns for Sustainability
Implementation Strategies实现
Operational Strategies运维

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

⭐3

Critically evaluate trade-offs between sustainability goals and other software quality attributes such as reliability and maintainability.

Sustainability Tactic
Gain
Trade-off

A
| Sustainability Tactic | Gain                | Trade-off              |
| --------------------- | ------------------- | ---------------------- |
| Caching               | ↓ energy            | ↓ consistency          |
| Serverless            | ↓ idle energy       | ↑ latency (cold start) |
| Microservices         | ↓ over-provisioning | ↑ complexity           |
| Autoscaling           | ↓ waste             | ↓ spike performance    |
| Smaller ML models     | ↓ energy            | ↓ accuracy             |
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

2.1

Architecture Styles for Sustainability

A
  • Monolith vs Microservice,
    Monolith:internal network communication->能耗↓; ❌scaling,maintenance,ecolution↑
    Microservices:fine-grained scaling;❌network + orchestration overhead
  • Serverless, [低频请求 + 长 idle period]
    scale-to-zero,极低 idle energy;❌cold start,延迟
  • Edge/Fog Computing
    network traffic能耗↓->network energy & latency;
    ❌部署复杂度ollout of physical devices、
    运维成本Orchestration overhead编排开销
    observability可观测性more difficult

Serverless 降低了空闲资源消耗,Edge/Fog Computing 通过减少数据传输来节省网络能

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

2.3

Implementation Strategies实现

A
  • Energy-aware and Energy Efficient algorithms
    -sorting algorithms/- Image compression/- ML-model complexity
  • Runtime Improvement
    versions/ distributions/ libraries or frameworks
    new != more efficient; compatibility issues兼容
  • Choosing / Changing Language(1step->)
    Faster ≠ Greener
    code maintainability; ecosystem(框架,tools); developer productivity
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

2.2

Patterns for Sustainability

A
  • Caching of Read Requests(缓存
    节能来源:减少 DB / network I/O
    Trade-off:❌ Consistency ↓(–energy efficiency)
  • Adaptive Service Composition
    非必要服务在低负载时关闭
    ❌User experience ↓(–energy and cost efficiency)
    *Sharing Computing Infrastructure
    同一platfrom被不同组织的不同system用
    design cloud-native systems; introduces additional vendor-dependencies
  • Circuit BreakerPattern(熔断器
    避免 retry storm / cascading failures
    本质:resilience tactic → 间接降低无效计算
    Implemented in Proxy / Gateway
    Re-establishes circuit after some time
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

2.4

Operational Strategies运维

A
  • Temporal Load Shifting
    将 shiftable workload 安排到 renewable-rich periods 执行,以降低 carbon intensity,而非减少功能
  • Spatial Load Shifting
    通过将 workload 动态迁移到 regions with high renewable energy rates 来降低 carbon footprint,同时需权衡 latency 以及 regulatory and privacy related restrictions
  • Autoscaling & Right-Sizing
    Autoscaling:根据 workload 动态扩展或收缩资源实例数量,以减少 idle resources 并在负载变化时保持系统可用性。
    Right-Sizing:匹配 resource capacity 与实际需求,避免 over-provisioning (资源恰当配置)
  • LightSwitchOps
    在downtime periods自动switching off idle resources(VM),以直接降低 idle energy consumption 并减少浪费
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

idle

A

| PPT 术语 | 实际意思 |

——————– | —————– |
| idle resources | 分配了但没干活的算力 |
| scale-to-zero | 把 idle 压到 0 |
| over-provisioning | 主动制造 idle |
| right-sizing | 减少 idle |
| LightSwitchOps | 定时消灭 idle |
| cold start trade-off | 用 latency 换少 idle |

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

trade-off

A

第 29 页 (Monolith): 提到 Monolith 虽然能减少能源消耗,但其 Scaling, Maintenance and Evolution(扩展、维护和演进)可能耗时更长(即与可伸缩性和可维护性的权衡)。
第 36 页 (Caching): 明确指出 “We trade consistency for energy efficiency.”(我们用数据一致性换取能源效率)。
第 37 页 (Adaptive Service Composition): 明确指出 “Customer experience suffers for the sake of energy and cost efficiency.”(为了能源和成本效率,用户体验可能会受到影响)。
第 51 页 (Right-Sizing): 提到其风险在于如果工作负载或使用模式意外变化,可能影响 availability(可用性)和 stability(稳定性)。
第 61-62 页 (ADR 结果): 总结了迁移到微服务(为提高能效)的负面后果,包括 Increased Complexity(增加了复杂性)、Deployment Overhead(增加了部署开销)、Migration Cost(迁移成本),以及明确的 Energy Trade-off(能源权衡,指服务间通信和容器编排的能源增加)。

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

ADR

A

Context – Background and forces leading to
the decision
Decision – The option chosen
Alternatives – Rejected or deferred options
Consequences – Trade-offs, risks, and expected impacts
Status – Proposed / Accepted / Deprecated

How well did you know this?
1
Not at all
2
3
4
5
Perfectly