docs: add swagger error codes for /trace/:name/[log|download]
This commit is contained in:
parent
9100b13db6
commit
f8dd8d652d
|
@ -140,7 +140,8 @@ schema("/trace/:name/download") ->
|
||||||
'application/octet-stream' =>
|
'application/octet-stream' =>
|
||||||
#{schema => #{type => "string", format => "binary"}}
|
#{schema => #{type => "string", format => "binary"}}
|
||||||
}
|
}
|
||||||
}
|
},
|
||||||
|
404 => emqx_dashboard_swagger:error_codes(['NOT_FOUND'], <<"Trace Name Not Found">>)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -174,7 +175,10 @@ schema("/trace/:name/log") ->
|
||||||
[
|
[
|
||||||
{items, hoconsc:mk(binary(), #{example => "TEXT-LOG-ITEMS"})},
|
{items, hoconsc:mk(binary(), #{example => "TEXT-LOG-ITEMS"})},
|
||||||
{meta, fields(bytes) ++ fields(position)}
|
{meta, fields(bytes) ++ fields(position)}
|
||||||
]
|
],
|
||||||
|
400 => emqx_dashboard_swagger:error_codes(
|
||||||
|
['READ_FILE_ERROR', 'RPC_ERROR', 'NODE_ERROR'], <<"Trace Log Failed">>
|
||||||
|
)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}.
|
}.
|
||||||
|
|
Loading…
Reference in New Issue