Chapter 10 — Parallel Execution and Service Call Costs¶
© 2026 S++ project contributors. All rights reserved. Book copyright.
Fine-grained business services improve the precision of modeling, but treating each service as a remote endpoint can multiply communication, encoding, queueing and coordination costs. SPP separates the business decomposition from the execution plan so that independent waits can overlap and unnecessary calls can be avoided.
Latency and the Critical Path¶
Suppose buyer and goods queries take 40 and 70 milliseconds respectively, followed by a 10-millisecond quotation. With independent queries and sufficient execution resources:
Serial: 40 + 70 + 10 = 120 ms
Concurrent: max(40, 70) + 10 + overhead = 80 ms + overhead
These are illustrative durations, not benchmark results. The ideal saving is 40 milliseconds before scheduling and join overhead. The total work is not reduced merely by overlapping it.
More generally, for a dependency graph with operation durations tᵢ, serial execution takes their sum; the longest dependency path gives a lower bound on parallel completion time. Actual latency also depends on resource contention, communication and coordination. Parallel execution is beneficial only when the avoided waiting exceeds its added costs.
Three Complementary Mechanisms¶
| Mechanism | Effect |
|---|---|
| Concurrent independent services | Overlap database or network waits |
| Merged quantum requests | Reduce repeated transport and protocol overhead while retaining settlement semantics |
| Local calculations and validations | Avoid remote calls for prepared-data rules |
Independent ordinary saves can also overlap after the quantum phase and required preparation. The dependencies and admission conditions of Chapters 6, 7 and 9 remain binding; neither merging nor concurrency permits arbitrary reordering.
Performance Is Not Availability¶
Traditional microservices may justify separate deployment through isolation, independent scaling or ownership. However, more required remote dependencies can increase the opportunities for a scenario to fail. Overlapping calls reduces waiting, not the number of required successful dependencies.
A saturated database, limited connection pool or shared executor can eliminate parallel gains or increase tail latency. Evaluate equivalent business rules and commit guarantees using response-time distributions, throughput and resource consumption. Appendix C develops the performance models and experimental conditions. Chapter 11 addresses the deployment choices that determine these costs.
Part Contents · Full Book Contents · Previous Chapter · Next Chapter