mirror of
https://github.com/OpenNebula/one.git
synced 2025-03-21 14:50:08 +03:00
M #-: Sort hooks by execution id (#1262)
(cherry picked from commit 6a4417c4a79d6ab3efef9bc09ce9a2dea9f7160c)
This commit is contained in:
parent
c818a269ae
commit
e0855a22d3
@ -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);
|
||||
|
Loading…
x
Reference in New Issue
Block a user