Here is the simplest code to reproduce the problem. Add the following code in the start() method of the app:
EasyThread et1 = EasyThread.start("et1");
et1.run(()->java.lang.System.out.println("************ EASYTHREAD1"));
EasyThread et2 = EasyThread.start("et2");
et2.run(()->java.lang.System.out.println("************ EASYTHREAD2"));
In the simulator in my case it only shows the following in the log:
The second one never shows. This could be different on different machines and you might need to add more threads for this to show however on my computer it always produces the same result.
Looking at the source for EasyThread the first thing I noticed was that "LOCK" is a static final. Why would lock be static? Why would each instance of EasyThread share the same LOCK?
However I don't think "LOCK" being static is what causes the issue.
Please let me know what is the issue and how it can be fixed.