Status

Background

ACS makes use of Loki and ACE libraries to implement singleton functionalities. Loki is an old library providing support for singleton; on the other hand ACE is a maintained middleware for portability which also offers singleton implementation because it was not officially offered by C++ or Boost years ago. The problem is that the support for Loki library was discontinued and it is becoming a legacy software in ACS. These days the standard C++ library provides a mechanism for clean and thread-safe singleton implementations based on static variables, hence it would make sense to migrate the existing singletons to one of the two clean mechanisms available depending on the requirements.

Alternatives

Implementation

The implementation is ultimately based on the first and third alternatives depending on the requirements. The three alternatives are correct options depending on the requirements, and we chose the simpler ones when possible. The implementation is marked for 2022JUN release. Details can be found in the ticket: