You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Aside from the thread-safety issue (which in Xstream is circumvented via the use of thread-locals), SimpleDateFormat causes the JDK to initialize all possible timezones, resulting in a heap overhead of about 3.5MB (measured on x86_64).
It would be better to use DateTimeFormatter and avoiding the use of the z pattern (which also triggers the initialization of the timezones).
Aside from the thread-safety issue (which in Xstream is circumvented via the use of thread-locals),
SimpleDateFormat
causes the JDK to initialize all possible timezones, resulting in a heap overhead of about 3.5MB (measured on x86_64).It would be better to use
DateTimeFormatter
and avoiding the use of thez
pattern (which also triggers the initialization of the timezones).triggers the time-zone initialization, while
does not.
The following table summarizes the heap impact:
The text was updated successfully, but these errors were encountered: