xrpld
Loading...
Searching...
No Matches
LogRotate.cpp
1#include <xrpld/app/main/Application.h>
2#include <xrpld/rpc/Context.h>
3#include <xrpld/rpc/detail/Handler.h>
4
5#include <xrpl/basics/Log.h>
6#include <xrpl/core/PerfLog.h>
7#include <xrpl/json/json_value.h>
8
9namespace xrpl {
10
11json::Value
13{
14 context.app.getPerfLog().rotate();
15 return RPC::makeObjectValue(context.app.getLogs().rotate());
16}
17
18} // namespace xrpl
std::string rotate()
Definition Log.cpp:187
virtual perf::PerfLog & getPerfLog()=0
virtual Logs & getLogs()=0
virtual void rotate()=0
Rotate perf log file.
json::Value makeObjectValue(Value const &value, json::StaticString const &field=jss::message)
Return a json::ValueType::Object with a single entry.
Definition Handler.h:45
Use hash_* containers for keys that do not need a cryptographically secure hashing algorithm.
Definition algorithm.h:5
json::Value doLogRotate(RPC::JsonContext &context)
Definition LogRotate.cpp:12
Application & app
Definition Context.h:21