Welcome to the InfoQ Software Architects’ Newsletter! Each month, we bring you essential news and experience from industry peers on emerging patterns and technologies.
This month, we focus on the topic of "Event-Driven Architecture". As identified in the recent Architecture and Design InfoQ Trends Report, event-driven architecture patterns and technologies are becoming increasingly popular, particularly in cloud-based systems. However, key challenges remain for architects designing such systems, including understandability and observability.
A quick reminder: we are seeking your feedback on how we could improve InfoQ for you. Can we ask you to spend 2 minutes sharing your views in our short survey, please?
Change Data Capture for Distributed Databases @Netflix
In this recording of a QCon Plus 2020 talk, Raghuram Onti Srinivasan covers the challenges associated with capturing Change Data Capture (CDC) events from Cassandra and discusses the Flink ecosystem and the use of RocksDB.
Netflix has microservices that use different kinds of databases based on the capabilities provided by each database. For example, when a new movie is added, the information is written to a Cassandra database. However, it may also be required by the user interface services, accessed with Elasticsearch, or be used within analytics engines. This talk focuses on the challenges involved in keeping the data synced from Cassandra, which is a distributed NoSQL database, to other databases using CDC.
Unified Event-Driven Architecture for the Cloud Native Enterprise
In this recent TNS article, Chris Latimer, VP of Product Management at DataStax, presents a "unified" event-driven architecture (EDA) pattern that he suggests has various names, including "unified event fabric", "enterprise messaging backbone", and "digital nervous system".
Latimer begins by arguing that one of the most common challenges enterprise architects are struggling with in the EDA space is the proliferation of messaging and streaming technologies. He also posits that platforms such as Apache Kafka were built for streaming and pub/sub, leaving traditional queuing use cases out of scope. The answer, he believes, lies within Apaches Pulsar, a "cloud-native, distributed messaging and streaming platform originally created at Yahoo!"
How to Build an Event-Driven ASP.NET Core Microservice Architecture
In a recently published guide, Christian Zink provides a detailed walkthrough to create two C# ASP.NET Core Microservices that communicate using a simple event-driven architecture (EDA) pattern. Both microservices have their own bounded context and domain model, and one microservice publishes integration events that the other consumes. The complete code for the example project is provided.
Event-Based Architecture: What Do You Mean by "Event"?
In a recent article and YouTube presentation, Derek Comartin argues that the term "Event" is really overloaded. There are many different utilities that leverage events. Event Sourcing, Event Carried State Transfer, and Event Notifications. None of these are for the same purpose. When talking about an Event-Based Architecture, realize which one is being used and for what purpose.
Effectful Effects—Unifying Bidirectional Communication between Software Components
Yizhou Zhang, assistant professor at the University of Waterloo, presented bidirectional algebraic effects, a new programming abstraction that subsumes current control flow patterns (e.g., exceptions, promises, generators) while supporting bidirectional flows of control. The new typed abstraction guarantees that all declared effects are handled, and no effects are accidentally handled (e.g., by the wrong handler).
Zhang then explained:
Software [has] become increasingly event-driven. Callback functions are a conventional pattern for event-driven programming, but unconstrained callbacks become complex and hard to reason about as applications grow. Hence, it is currently in vogue for programming languages to build in support for advanced control-flow transfer features like generators and async-await. These features support more structured programming of asynchronous, event-driven code.
Algebraic effects have emerged as a powerful alternative that allows programmers to define their own control effects; […] subsumes a wide range of features including exceptions, generators, and async-await; [… provides] a nice separation between the syntax (i.e., a set of effect operations) and the semantics (i.e., handling of those operations).
However, even with these advanced language features at hand, programmers today still find certain complex control-flow patterns painful to manage.
After describing the existing tradeoffs with existing control flow constructs, Zhang then described a possible solution that generalizes algebraic effects, called bidirectional algebraic effects. Bidirectional algebraic effects statically guarantee that there are no unhandled or accidentally handled effects while allowing for bidirectional control flows.
In a related paper, Zhang proved that bidirectional algebraic effects guarantee that all declared effects are handled, and no effects are accidentally handled (e.g., by the wrong handler). The full talk of Prof. Yizhou Zhang is available online and contains additional details, examples, and illustrations.
This content is an excerpt from a recent InfoQ news item written by Bruno Couriol, "Effectful Effects—Unifying Bidirectional Communication between Software Components".
Missed a newsletter? You can find all of the previous issues on InfoQ.
|This edition of The Software Architects' Newsletter is brought to you by:
Easy Scaling for Applications and Clusters
Concretely, when you need to scale your service, the immutable, declarative nature of Kubernetes makes this scaling trivial to implement. Because your containers are immutable, and the number of replicas is merely a number in a declarative config, scaling your service upward is simply a matter of changing a number in a configuration file, asserting this new declarative state to Kubernetes, and letting it take care of the rest. Alternatively, you can set up autoscaling and let Kubernetes take care of it for you.
Deep-dive into a specific topic at InfoQ Live events:
InfoQ Live - June 22: Prevent Cloud and Serverless Security Challenges. Learn from world-class Security Practitioners.
If you want to take full advantage of a DevOps approach to agility and responsiveness, IT security must play an integrated role in your application’s full life-cycle.
Learn practical advice from world-class DevSecOps & Modernizing Application Security Professionals, Liz Rice, Chief Open Source Officer @isovalent and Mario Platt, Head of Information Security @CloudMargin & CISO/Exec advisor. Register for InfoQ Live on June 22nd.
InfoQ Live - July 20: How can modern DevOps practices accelerate your software delivery without the quality issues?
Every development team needs to improve the speed of software delivery to meet business needs. But traditional approaches tend to impact quality, introduce bugs and technical debt, creating more work for software engineering teams.
Learn how automation, continuous testing, and supply management techniques can improve software quality and speed of delivery. Register for InfoQ Live on July 20th.
*If you register you'll get exclusive access to all talks on-demand after the event so you can revisit any of the sessions or watch any of the talks you missed.
Senior software developers rely on the InfoQ community to keep ahead of the adoption curve. One of the main reasons software architects and engineers tell us they keep coming back to InfoQ is because they trust the information provided and selected by their peers.
We’ve been helping software development teams adopt new technologies and practices for over 15 years through InfoQ articles, news items, podcasts, tech talks, trends reports, and QCon software development conferences.
We hope you find this newsletter useful. If not, you can unsubscribe using the link below.
Forwarded email? Subscribe and get your own copy.