Home > On-Demand Archives > Talks >

ActiveCpp: Active Objects for Modern C++

Amir Alavi - Watch Now - EOC 2025 - Duration: 31:58

ActiveCpp: Active Objects for Modern C++
Amir Alavi

The Active Object design pattern is a concurrency pattern that decouples method execution from method invocation to enhance the responsiveness and scalability of an application. This pattern is particularly useful in scenarios where multiple operations need to be performed concurrently without blocking the main thread of execution.

This talk presents modern methods for the Active Object design pattern, also known as Actor objects, in C++ and introduces activecpp (https://github.com/samiralavi/activecpp), a useful single-header templated library to implement this pattern effectively. Key features of the Active Object design pattern, alongside best practices for low-power embedded systems, are discussed, and the activecpp library is showcased for a typical IoT application on an ESP32-S3 SoC-based devkit.

M↓ MARKDOWN HELP
italicssurround text with
*asterisks*
boldsurround text with
**two asterisks**
hyperlink
[hyperlink](https://example.com)
or just a bare URL
code
surround text with
`backticks`
strikethroughsurround text with
~~two tilde characters~~
quote
prefix with
>

datamstr
Score: 0 | 2 weeks ago | no reply

Excellent presentation!

Miro
Score: 0 | 2 weeks ago | no reply

Thank you for your presentation of the Active Object model of computation and the ActiveCpp framework. Having worked with Active Objects for a very long time, I'm really glad to see the interest and appreciation for Active Objects/Actors, especially in embedded systems.

One great benefit of Active Objects that I would add to your summary is the non-blocking, RTC (run-to-completion) event processing model. This is perhaps the most consequential departure from the traditional "shared-state concurrency with blocking" based on the traditional RTOS because blocking is technical debt.

Also, have you considered adding explicit support fo state machines to the ActiveCpp framework? Active Objects and state machines beautifully complement each other. Without state machines, the event-driven code inside Active Objects tends to quickly degenerate into "spaghetti code". At the same time, event-driven state machines precisely need the RTC model of execution.

OUR SPONSORS & PARTNERS