some improvements to DateTimeProvider max timestamp