You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@rocketmq.apache.org by "Mark Yang (JIRA)" <ji...@apache.org> on 2017/08/16 08:51:00 UTC
[jira] [Created] (ROCKETMQ-269) don’t need cal.setTimeInMillis(System.currentTimeMillis()) after Calendar.getInstance()
Mark Yang created ROCKETMQ-269:
----------------------------------
Summary: don’t need cal.setTimeInMillis(System.currentTimeMillis()) after Calendar.getInstance()
Key: ROCKETMQ-269
URL: https://issues.apache.org/jira/browse/ROCKETMQ-269
Project: Apache RocketMQ
Issue Type: Improvement
Components: rocketmq-commons
Reporter: Mark Yang
Assignee: Jixiang Jin
don’t need cal.setTimeInMillis(System.currentTimeMillis()) after Calendar.getInstance()
In JDK’s source code, innermost constructor for Calendar.getInstance() is:
public GregorianCalendar(TimeZone zone, Locale aLocale) {
super(zone, aLocale); gdate = (BaseCalendar.Date) gcal.newCalendarDate(zone);
setTimeInMillis(System.currentTimeMillis());
}
--
This message was sent by Atlassian JIRA
(v6.4.14#64029)