Add gRPC support (#3127):

* add support for AccountInfo, Fee and Submit RPCs

* add partial support for Tx RPC (only supports Payments)
This commit is contained in:
CJ Cobb
2019-10-16 12:44:25 -07:00
parent 761bb5744e
commit 7d867b806d
112 changed files with 4428 additions and 296 deletions

View File

@@ -221,9 +221,17 @@ public:
auto& app = env.app();
Resource::Charge loadType = Resource::feeReferenceRPC;
Resource::Consumer c;
RPC::Context context { env.journal, {}, app, loadType,
app.getOPs(), app.getLedgerMaster(), c, Role::USER,
RPC::APIVersionIfUnspecified};
RPC::JsonContext context{{env.journal,
app,
loadType,
app.getOPs(),
app.getLedgerMaster(),
c,
Role::USER},
{},
RPC::APIVersionIfUnspecified,
{}};
Json::Value params = Json::objectValue;
params[jss::command] = "ripple_path_find";
@@ -321,9 +329,17 @@ public:
auto& app = env.app();
Resource::Charge loadType = Resource::feeReferenceRPC;
Resource::Consumer c;
RPC::Context context {env.journal, {}, app, loadType,
app.getOPs(), app.getLedgerMaster(), c, Role::USER,
RPC::APIVersionIfUnspecified};
RPC::JsonContext context{{env.journal,
app,
loadType,
app.getOPs(),
app.getLedgerMaster(),
c,
Role::USER},
{},
RPC::APIVersionIfUnspecified,
{}};
Json::Value result;
gate g;
// Test RPC::Tuning::max_src_cur source currencies.