High expectation is probably one of the first thoughts that come to mind, with regard to the recent demands expressed by clients, developers and consumers of software and business solutions.
Non-functional requirements have certainly taken their place on the podium of top priorities for clients and consumers, as of late. Clients are asking for much greater levels of performance, with extreme reliability for a top-notch customer experience. Easy right?
To meet these customer demands, as well as increase the velocity of delivering these powerhouse solutions, the developer community has evolved their expectations as well. They have come to realize they must also demand more from their development tools in terms of power and performance, without sacrificing simplicity and expressiveness.
To meet the flow of demands and high expectations, software vendors are realizing that ease of development, understandability, explain-ability, testability, maintainability, and high performance at scale are important “language features.” Therefore, software vendors have made great strides in leveraging multi-core computing environments, by moving highly scalable and highly performant design patterns to actual features, fully integrated into software, services and programming languages. Though the implementations are different between the languages, you see features like concurrency built directly into languages such as NodeJS, Go, Java and C#. At the same time, software vendors are making it easier to achieve the new crop of non-functional goals related to performance and scalability.
For this discussion, I will be focusing on the dual features of simplicity and performance (through concurrency and parallelism). I will use C#9, Go and Python to discuss some of the finer points of these two highly expected features, simplicity and concurrency.
**For more details on C#9 features, check out the following link: https://devblogs.microsoft.com/dotnet/c-9-0-on-the-record/
In addition to simplicity, software vendors have embedded high performant capabilities into modern languages like Go, which uses “Go routines” to easily implement concurrency as feature. Generally speaking, creating highly concurrent thread-safe applications is made more achievable by the concept of immutable code (e.g. objects and data types that cannot change after initialization).
This is often tough to do with traditional object-oriented programming, due to the mutable (i.e. changeable) nature of data typically stored within objects. An example of this challenge becomes apparent when you have parallel processes or threads trying to update and read an objects data simultaneously, which can sometimes result in problems such as lost updates and inconsistent reads.
Since so much about the development of business solutions and data processing involves changing the state of data, it is not always intuitive as to how to maximize the benefits of immutable types. In the Martin Fowler book “Patterns of Enterprise Architecture” it is mentioned that it’s possible to design solutions with “immutable zones,” by identifying data that is immutable (all or most of the time). This concept becomes much easier to achieve now that languages like C#9 and Go have built in a number of immutable language features. Identifying and establishing isolated and immutable zones and leveraging pure functions (i.e. functions that do not change anything or depend on anything) is generally considered a good practice that can, in the right use cases, work well with concurrent workloads.
As software development practices are currently favoring immutable code, assignment-less programming and pure functions to better achieve concurrency; it’s important that they continue to implement simplicity as a feature in parallel to power and concurrency.