Try CoAkka Runtime when you use Dapr
Pick an internal call such as basket pricing. Follow the call, identify what Dapr handles today, and decide whether to try CoAkka Runtime for that call.
Two paths for one pricing request
- Dapr Service Invocation
- Checkout → checkout Dapr sidecar → pricing Dapr sidecar → pricing API
- CoAkka Runtime · Peer
- Checkout → CoAkka Runtime sends to
samples.order.quote→ pricing CoAkka Runtime peer → pricing handler
Both paths send the same basket and return the same quote on success. A Dapr sidecar is a process that runs alongside an app and forwards the request to the destination API. Each CoAkka Runtime participant embeds the runtime in its own process. CoAkka Runtime delivers directly between the two peers using the configured route.
| Criteria | Dapr Service Invocation | CoAkka Runtime |
|---|---|---|
| Destination and contract | Checkout addresses the pricing app, for example through the HTTP API POST /quote. Dapr forwards the call to the service endpoint. |
Checkout sends to samples.order.quote. The pricing app registers a handler under that target name. The apps agree on request and reply formats. |
| Discovery and instance selection | Dapr resolves the destination using its app ID and the deployment’s name resolution mechanism. Instance selection depends on the mechanism in use. | The app or platform supplies route addresses. CoAkka Runtime selects an eligible peer under the configured routing policy. |
| Results and diagnostics | The caller receives an HTTP or gRPC outcome. Dapr logs, traces, and metrics can help locate a failure along the path. | The caller distinguishes business replies, admission refusals, Deadletters, and timeouts. An admitted request with no route yields a Deadletter with the reason and original payload. |
| Deadlines and retries | Dapr timeout and retry policies can apply to a call. Record the effective policy before changing the path. | If an endpoint failure is known to have prevented delivery, CoAkka Runtime can try another peer within the remaining deadline. After a terminal outcome, the app decides whether to submit again. |
| Security | Dapr can use mTLS between sidecars and enforce access policies on service calls. | Peer connections can use TLS/mTLS. The platform provisions and distributes credentials. The app still authorizes business actions. |
When to keep Dapr
- Keep Dapr where the app uses its building blocks. Examples include state stores, pub/sub, secrets, configuration, bindings, and workflows. The pricing call can move while those components continue using the sidecar.
- Keep the call on Dapr when it still relies on sidecar policies. Check access rules, peer authentication, certificate rotation, deadlines, retries, and traces. Change the path after verifying how it will meet those requirements.
- Try CoAkka Runtime when one team controls both ends. Choose a read-only call with a result you can compare, such as pricing. Keep the Dapr path available for rollback.
Check policies before removing a sidecar
Review incoming and outgoing calls and the Dapr components the app uses. Record how participants will authenticate and how operators will trace errors after a switch. Remove that app’s sidecar only after checking all those dependencies.
Try switching one internal call
- Record outcomes on the existing Dapr path. Use a fixed basket. Record the quote, the result when the service is unavailable, and the number of attempts when a reply is slow.
- Run the CoAkka Runtime path on a development machine. The existing sample calls Python from Node.js. Its sample basket returns USD 48.00. Use the same input on both paths when testing your own system.
- Compare outcomes in staging. Check the quote, a missing route or stopped peer, a late reply, and a call rejected by access policy. Compare attempt counts and how you trace failures before switching.
A request can reach the handler even if the caller times out. For a write, reconcile the outcome before resending and use a stable business ID to handle duplicates. Handle timeouts and retries.