Are there any generalisations of object and data and thread interactions given design pattern names?
Obviously what goes on a lot is synchronisation on an object, passing messages through a queue and also reference counts in memory management systems.
But are there any more OO-oriented names for multithreading design patterns and systems that cleanly embody best practice?
In software engineering, concurrency patterns are those types of design patterns that deal with the multi-threaded programming paradigm. Examples of this class of patterns include: Active Object. Balking pattern.
Multithreading is a Java feature that allows concurrent execution of two or more parts of a program for maximum utilization of CPU. Each part of such program is called a thread. So, threads are light-weight processes within a process. Threads can be created by using two mechanisms : Extending the Thread class.
As per the design pattern reference book Design Patterns - Elements of Reusable Object-Oriented Software , there are 23 design patterns which can be classified in three categories: Creational, Structural and Behavioral patterns.
Within a process or program, we can run multiple threads concurrently to improve the performance. Threads, unlike heavyweight process, are lightweight and run inside a single process – they share the same address space, the resources allocated and the environment of that process.
"Pattern-oriented Software Architecture Vol 2: Patterns for Concurrent and Networked Objects" by Schmidt, Stal, Rohnert and Buschmann lists some. Douglas Schmidt is also the author of the ACE C++ framework which brings those patterns into practice.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With