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
{{ message }}
Repository navigation
Commit 8068486
Browse filesBrowse the repository at this point in the historyBrowse files
Stringsql = "select h.id from host h left join cluster c on h.cluster_id=c.id where h.last_ping < ? and h.status in ('Up', 'Updating', 'Disconnected', 'Connecting') and h.type not in ('ExternalFirewall', 'ExternalLoadBalancer', 'TrafficMonitor', 'SecondaryStorage', 'LocalSecondaryStorage') and (h.cluster_id is null or c.managed_state = 'Managed') ;" ;
681
+
pstmt = txn.prepareStatement(sql);
682
+
pstmt.setLong(1, timeout);
683
+
rs = pstmt.executeQuery();
684
+
while (rs.next()) {
685
+
longid = rs.getLong(1); //ID column
686
+
result.add(findById(id));
687
+
}
688
+
} catch (Exceptione) {
689
+
s_logger.warn("Exception: ", e);
690
+
} finally {
691
+
try {
692
+
if (rs != null) {
693
+
rs.close();
694
+
}
695
+
if (pstmt != null) {
696
+
pstmt.close();
697
+
}
698
+
} catch (SQLExceptione) {
699
+
}
700
+
}
701
+
returnresult;
691
702
}
692
703
693
704
@Override
@@ -697,13 +708,7 @@ public List<HostVO> findHostsLike(String hostName) {
0 commit comments