A lightweight JSON RPC client & server
**This will be a breaking change, but you don't have to upgrade. The current version is stable enough.** I learned from the mistakes in the current design, it's time to consider what the next step is. ## Architecture changes - [x] **(internal)** Rewrite the build architecture of this repository. - [x] Support Node package exports - [ ] Be able to tree shake unused contents (? may not, this library is small enough) - [ ] A documentation website. Mention common practice (including integration with Zod). ## API changes - [ ] Should be able to create the client and the server separately. - [ ] Still allows creating isomorphic client & server. ```js const client = createClient({ ... }) const { client, server } = create({ ... }) ``` - [x] Should be able to stop the instance by an AbortSignal - [x] Rename `seralization/deseralization` to `encode/decode` - [x] batch should have multiple queue - [ ] Remove CallbackBasedChannel (this is the biggest mistake in the current design). - [ ] Call context, the function be called can receive an extra object. By `this`? Or an extra wrapper? - Progress report - AbortSignal from remote/local - custom object provided by the channel - Bind to the request - Logger! - [ ] Logger - Get the raw message (send/receive) - Get the decoded message (send/receive) - Get call context - Get the replay function - Get progress report - Get cancellation - Get result - Get metrics of encode/decode, execution - [ ] Handle JSON RPC internal methods better - [ ] Rewrite common channels and encoder-decoders - [ ] AsyncGeneratorCall should be able to create based on the existing AsyncCall instance (or explicitly list generator names/functions?)
This issue appears to be discussing a feature request or bug report related to the repository. Based on the content, it seems to be still under discussion. The issue was opened by Jack-Works and has received 0 comments.