MXS-1220: Add JSON return value to diagnostics
entry points
The modules that implement a diagnostics entry point now return a JSON type object. This removes the need to format data inside the modules. The module implementations of these are not yet complete which means that MaxScale will fail to compile.
This commit is contained in:

committed by
Markus Mäkelä

parent
94ebef0703
commit
bbe0620944
@ -530,9 +530,13 @@ dprintSession(DCB *dcb, MXS_SESSION *print_session)
|
||||
{
|
||||
dcb_printf(dcb, "\tFilter: %s\n",
|
||||
print_session->filters[i].filter->name);
|
||||
print_session->filters[i].filter->obj->diagnostics(print_session->filters[i].instance,
|
||||
print_session->filters[i].session,
|
||||
dcb);
|
||||
json_t* json = print_session->filters[i].filter->obj->diagnostics(print_session->filters[i].instance,
|
||||
print_session->filters[i].session);
|
||||
|
||||
if (json)
|
||||
{
|
||||
json_decref(json);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user