-
Notifications
You must be signed in to change notification settings - Fork 2.1k
Description
I'm building a javascript lib for Thelonious-Tendermint and would like to contribute to the server side, particularly the RPC/RMI section. Seems like the logic is mostly there, so I'd be refining & standardizing.
This is my suggestions:
Coding
Separate into two different RPC protocols. The first would be used between Go libraries that can just import the serialization/binary stuff. The second would be generic (JSON) RPC, and that's what I'd be working with. I'd create proxies and conversion functions for all the needed data-structures and hook them up with the handlers. I guess regular HTTP requests could use them as well, though I wouldn't be concerned with that.
This would also involve going over method names, namespacing etc. Maybe add some more functions (a way to get the client version etc.), and divide a few of the current ones up etc. The model I use in the javascript library (as of now) has the following classes:
- Accounts
- Blockchain
- Consensus
- Core
- Networking
- Transactions
- Unsafe
These are based on the current rpc commands (and looking at the client), and I don't think more classes will be needed for some time.
Tests
I would make sure the tests are working before PRing to develop, and add any new ones that might be needed.
Docs
I could put the spec in the wiki.
Time
It would probably take about a week for the code, and another for doing good tests and docs + the time it takes to look into / research the library more. Around 3 weeks in total.