mirror of
https://github.com/OpenNebula/one.git
synced 2026-12-03 21:52:31 +09:00
M #-: Sort hooks by execution id (#1262)
This commit is contained in:
1 parent
87a7c595d5
commit
6a4417c4a7
1 file changed
+3
-5
+3
-5
@@ -57,11 +57,7 @@ int HookLog::_dump_log(int hkid, int exec_id, std::string &xml_log)
|
||||
|
||||
cmd << "SELECT body FROM "<< one_db::hook_log_table;
|
||||
|
||||
if ( hkid == -1 )
|
||||
{
|
||||
cmd << " ORDER BY hkid DESC";
|
||||
}
|
||||
else
|
||||
if ( hkid != -1 )
|
||||
{
|
||||
cmd << " WHERE hkid = " << hkid;
|
||||
}
|
||||
@@ -71,6 +67,8 @@ int HookLog::_dump_log(int hkid, int exec_id, std::string &xml_log)
|
||||
cmd << " AND exeid = " << exec_id;
|
||||
}
|
||||
|
||||
cmd << " ORDER BY hkid DESC, exeid";
|
||||
|
||||
xml_log.append("<HOOKLOG>");
|
||||
|
||||
cb.set_callback(&xml_log);
|
||||
|
||||
Reference in new issue
Block a user