gridcoin-community / Gridcoin-Research

Gridcoin-Research
MIT License
588 stars 173 forks source link

Port RPC functionality from Bitcoin #1142

Open denravonska opened 6 years ago

denravonska commented 6 years ago

Copy Bitcoin code

Copy the relevant Bitcoin RPC code into rpc/. This will cascade into dependencies so if the job is not feasible to do we will notice it here.

Gridcoin RPC isolation

With the new RPC engine in place we can migrate our Gridcoin specific calls from the old RPC files under src/rpc* to files following the Bitcoin naming convention under src/gridcoin/rpc/. We can and should be liberal with axing calls which are unused or obsolete calls which can be done by external scripts using existing calls.

RPC table injection

Bitcoin calls RegisterAllCoreRPCCommands during initialization to register the RPC functions. At the end of this we should include a call to RegisterGridcoinRPCCommands which is implemented in gridcoin/rpc/register.h and follows the same pattern but only injects Gridcoin specific commands.

RoboticMind commented 3 years ago

I think at least part 1 and 2 would be covered by https://github.com/gridcoin-community/Gridcoin-Research/pull/1705 whenever that gets merged. Not sure about the RPC table injection thing