|
|
@ -1,5 +1,6 @@
|
|
|
|
#include <rpc/rpc.hpp>
|
|
|
|
#include <rpc/rpc.hpp>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
#include <constants/version.hpp>
|
|
|
|
#include <router/abstractrouter.hpp>
|
|
|
|
#include <router/abstractrouter.hpp>
|
|
|
|
#include <service/context.hpp>
|
|
|
|
#include <service/context.hpp>
|
|
|
|
#include <util/logging/logger.hpp>
|
|
|
|
#include <util/logging/logger.hpp>
|
|
|
@ -259,6 +260,13 @@ namespace llarp
|
|
|
|
return resp;
|
|
|
|
return resp;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Response
|
|
|
|
|
|
|
|
DumpVersion() const
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
const Response resp{{"version", LLARP_VERSION}};
|
|
|
|
|
|
|
|
return resp;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
absl::optional< Response >
|
|
|
|
absl::optional< Response >
|
|
|
|
HandleJSONRPC(Method_t method,
|
|
|
|
HandleJSONRPC(Method_t method,
|
|
|
|
ABSL_ATTRIBUTE_UNUSED const Params& params) override
|
|
|
|
ABSL_ATTRIBUTE_UNUSED const Params& params) override
|
|
|
@ -279,6 +287,10 @@ namespace llarp
|
|
|
|
{
|
|
|
|
{
|
|
|
|
return DumpStatus();
|
|
|
|
return DumpStatus();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
if(method == "llarp.version")
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
return DumpVersion();
|
|
|
|
|
|
|
|
}
|
|
|
|
return false;
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
};
|
|
|
|
};
|
|
|
|