Permalink
Find file
Fetching contributors…
Cannot retrieve contributors at this time
13 lines (9 sloc) 244 Bytes
#include "handler.h"
namespace {
bool SqlHandler(Handler* handler) {
Json json = MySQL::SelectAll("SHOW PROCESSLIST");
handler->Print(JsonEncode(json));
return true;
}
REGISTER_HANDLER(SqlHandler, "/sql$", SqlHandler);
} // namespace