Fix heartbeat config logging

Description

heartbeat.interval is default 60s but is logged incorrectly:

2018-03-02 22:01:11,054 | INFO | CM Configuration Updater (Update: pid=org.opencastproject.serviceregistry.impl.ServiceRegistryJpaImpl) | (ServiceRegistryJpaImpl:778) - Dispatch interval set to 60 minutes

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 long heartbeatInterval = DEFAULT_HEART_BEAT; String heartbeatIntervalString = StringUtils.trimToNull((String) properties.get(OPT_HEARTBEATINTERVAL)); if (StringUtils.isNotBlank(heartbeatIntervalString)) { try { heartbeatInterval = Long.parseLong(heartbeatIntervalString); } catch (Exception e) { logger.warn("Heartbeat interval '{}' is malformed, setting to {}", heartbeatIntervalString, DEFAULT_HEART_BEAT); heartbeatInterval = DEFAULT_HEART_BEAT; } if (heartbeatInterval == 0) { logger.info("Heartbeat disabled"); } else if (heartbeatInterval < 0) { logger.warn("Heartbeat interval {} minutes too low, adjusting to {}", heartbeatInterval, DEFAULT_HEART_BEAT); heartbeatInterval = DEFAULT_HEART_BEAT; } else { logger.info("Dispatch interval set to {} minutes", heartbeatInterval); } }

Steps to reproduce

None

Status

Assignee

Unassigned

Reporter

Stephen Marquard

Criticality

None

Tags (folksonomy)

None

Components

Fix versions

Affects versions

4.1

Priority

Major