I have just been able to reproduce it like this when i change my time zone to his as below:
Date day = new Date();
DateTimeZone timeZone = DateTimeZone.forID("Europe/Moscow");
System.out.println(new DateMidnight(day, timeZone).toDate());
The output is: Mon Jan 30 23:00:00 EAT 2017 (with joda-time version 2.3)
While the output is: Tue Jan 31 00:00:00 EAT 2017 (with joda-time version 2.9.2)
The second output is the correct one because it is already after midnight (12:40 AM) and hence Tue instead of Mon.
The false output does not surprise me because DateMidnight is deprecated as of version 2.3 of joda-time, with the message: The time of midnight does not exist in some time zones where the daylight saving time forward shift skips the midnight hour....
I can see that this class is used in various modules with various versions of joda-time as below:
webservicesrest = joda-time version 2.9.2
emrapi = joda-time version 2.2
reporting = joda-time version 2.3
And possibly more...
So my recommendation is that we upgrade joda-time version to at least that used by webservicesrest
Any objections or alternative suggestion?
As to why each of these modules bundles joda-time, that is possibly for another day.