log.onEvent("Session " + this.sessionID + " is not configured to be active now.");
log.onEvent("Session state is not current; resetting " + this.sessionID);
    Session(Application application, MessageStoreFactory messageStoreFactory, SessionID sessionID,            DataDictionary dataDictionary, SessionSchedule sessionSchedule, LogFactory logFactory,            MessageFactory messageFactory, int heartbeatInterval) {        Log log = logFactory.create(sessionID);        try {            this.application = application;            this.sessionID = sessionID;            this.sessionSchedule = sessionSchedule;            enabled = true;            checkLatency = true;            maxLatency = 120;            resetOnLogout = false;            resetOnDisconnect = false;            resetWhenInitiatingLogon = false;            millisecondsInTimeStamp = true;            this.dataDictionary = dataDictionary;            state.setHeartBeatInterval(heartbeatInterval);            state.setInitiator(heartbeatInterval != 0);            state.setMessageStore(messageStoreFactory.create(sessionID));            this.messageFactory = messageFactory;            if (logFactory != null) {                state.setLog(log);            }            log.onEvent("Session " + this.sessionID + " schedule is " + sessionSchedule);            if (!checkSessionTime()) {                log.onEvent("Session " + this.sessionID + " is not configured to be active now.");                reset();            }            sessions.put(sessionID, this);            application.onCreate(sessionID);            log.onEvent("Created session: " + sessionID);        } catch (IOException e) {            LogUtil.logThrowable(log, "error during session construction", e);        }    }