Welcome to the new week!
The essence of modelling in Event Sourcing is keeping streams short. Thanks to that, our streams don’t grow infinitely, and we can run our system efficiently, benefiting from the loosely coupled capabilities.
One of the biggest enablers for that is the Closing the Books pattern. The term is taken from accounting. There instead of keeping a whole log of our finances, we’re breaking it into periods, e.g. accounting month. In Event Sourcing, we can do the same, marking the lifetime of our stream by the start and end events (e.g. AccountingMonthOpened and AccountingMonthClosed)
This time I wrote how to implement this pattern in practice using Marten as a tooling example:
I believe that this should take you far enough and, together with my other works, help you join both Event Sourcing modelling techniques and use them in practice in your projects.
I’d like to invite you to the upcoming webinar with a special guest, Andrea Magnorsky: Introducing Bytesize Architecture Sessions!
If your team suffers from inconsistent views of your systems or is producing incohesive solutions, this may be a good choice to spend next Monday (February 26th, at 6 PM CET (UTC+1).
Bytesize Sessions is a workshop format that enables collaborative and iterative knowledge sharing. I’m thrilled that Andrea agreed to share her experience and her method to facilitate better architecture discussions with us. I saw multiple recommendations about it; now we’ll get the chance to see that live and have a Q&A.
See more on the webinar page to join us live!
Understanding the system use cases is critical for the proper system design, but what’s actually a use case? Some time ago, I linked the video where Ivar Jacobson and Alistair Cockburn, pioneers of Agile and Software, joined forces to discuss what are actually use cases.
As an appendix to that, they joined forces to write their conclusion about this bloated system. They started it with a phrase:
To get to the heart of what a system must do, focus on who or what will use it, and then look at what the system must do for them to help them achieve their goals.
A use case is all the ways of using a system to achieve a goal of a particular user.
I’m not sure if they managed to clarify all the misconceptions around it, but at least they tried; check more:
The other aspect of good design is defining and analysing the pros and cons of solutions. And here’s the deal: reality is not always so black and white. Michael Nygard (the inventor of Architecture Decision Record) wrote:
I’ve noticed a pattern in much business writing, including technical writing. People feel compelled to label every effect as “pro” or “con”. I think this springs from our primary-school training in persuasive writing. As a result, what should be an engineering analysis often reads like marketing copy.
And I can only second that; read more in his article on how to avoid that trap:
Check also a nice article from Gergely Orosz on the importance of the critical thinking:
Moving on from the general discussion to something more real:
WhatsApp popularized end-to-end encryption, a technique that allows various clients to communicate without the server being able to read the content of the communication.
The idea is to encrypt the content before sending it to the server. The server would just store the encrypted blob and send it back to the client.
The biggest challenge with this architecture is how to distribute the key to encrypt the message in such a way that the server cannot see it.
Thankfully, in the context of a website, we can exploit the hash part of the URL. Anything that’s added after the # doesn’t get sent to the server, but is readable from the client-side JavaScript code.
This is the quote from an article written by the vjeux, the author of Excalidraw, where he explains how the tool is dealing with the end-to-end encryption of the user input data. This is essential for the privacy-first tooling and non-trivial architecture concept. Read more in:
See also an interesting article from Mateusz Jendza, where he describes his approach of keeping authentication passwordless:
And if you missed it, check the webinar he gave for our community:
Speaking about End-to-End, it sounds like NVidia wants to provide such a solution for AI. They don’t want to just benefit from the AI trend by selling the chips, but they also want to deliver AI solutions so as not to be dependent on the software vendors. That’s an interesting to observe. Will we get back to the old trend where we have processors built for specific solutions instead of general ones?
Check also a discussion between Eric Evans, and Dave Farley on how AI may change our industry:
Ending with a past and future. I’m not into stuff like Metaverse, but I respect a lot of methodic approaches and doing homework before releasing something. Read an interesting essay from Matthew Ball. Great, thorough write-up:
The other article on the unusual topic is:
In emerging gamification, making everything interactive, especially through chatbots and AI-based integration, we should not forget about the humane aspect of our systems.
Check also other links!
Cheers
Oskar
p.s. I invite you to join the paid version of Architecture Weekly. It already contains the exclusive Discord channel for subscribers (and my GitHub sponsors), monthly webinars, etc. It is a vibrant space for knowledge sharing. Don’t wait to be a part of it!
p.s.2. Ukraine is still under brutal Russian invasion. A lot of Ukrainian people are hurt, without shelter and need help. You can help in various ways, for instance, directly helping refugees, spreading awareness, and putting pressure on your local government or companies. You can also support Ukraine by donating, e.g. to the Ukraine humanitarian organisation, Ambulances for Ukraine or Red Cross.
Architecture
Eric Evans, Dave Farley - How AI Will Change Software Development In The Next 10 Years
The Serverless Edge - SCORP – the well-architected tool for Architecture Reviews
DevOps
Databases
AI
AWS
Azure
Java
.NET
Microsoft - Introducing ASP.NET Core metrics and Grafana dashboards in .NET 8
Andrew Lock - 8 ways to set the URLs for an ASP.NET Core app
Node.js
Windows
Coding Life
Management
Matthew Roche - Being a PM at Microsoft: Thriving in ambiguity
Forbes - CEOs Are Using Return To Office Mandates To Mask Poor Management
The Register - Dell said to be preparing broad Return To Office order this Monday