//MyRepoSingletonNotThreadSafe -> run it 5 or 6 time to see random behaviour (write one or two messages) //MyRepoSingletonThreadSafe -> Always two messages private static MyRepoSingletonThreadSafe MyRepo() { return(MyRepoSingletonThreadSafe.GetInstance()); }