Skip to content

Commit 3445d7a

Browse files
committed
mgmt: Update state to Up when mgmt server writes heartbeat to db
1 parent 483bab1 commit 3445d7a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

framework/cluster/src/main/java/com/cloud/cluster/dao/ManagementServerHostDaoImpl.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,7 @@ public void update(long id, long runid, Date lastUpdate) {
130130
try {
131131
txn.start();
132132

133-
pstmt = txn.prepareAutoCloseStatement("update mshost set last_update=?, removed=null, alert_count=0 where id=? and runid=?");
133+
pstmt = txn.prepareAutoCloseStatement("update mshost set last_update=?, removed=null, alert_count=0, state='Up' where id=? and runid=?");
134134
pstmt.setString(1, DateUtil.getDateDisplayString(TimeZone.getTimeZone("GMT"), lastUpdate));
135135
pstmt.setLong(2, id);
136136
pstmt.setLong(3, runid);

0 commit comments

Comments
 (0)