module which provides a decorator to create thread-safe singleton classes