-
Notifications
You must be signed in to change notification settings - Fork 893
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add changeset for using RpcRequest and RpcResponse in RPC Subscriptions #3407
Add changeset for using RpcRequest and RpcResponse in RPC Subscriptions #3407
Conversation
🦋 Changeset detectedLatest commit: 13363b7 The changes in this PR will be included in the next version bump. Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Merge activity
|
This PR changes the configs of the `executeRpcPubSubSubscriptionPlan` function such that it accepts a "Subscribe Request" as a `RpcRequest` object instead of a `subscribeMethodName` and `subscribeParams` duo. This mean we can now use the `RpcRequestTransformer` provided in a more idiomatic way. Note: A changeset for this PR is included in #3407.
This PR refactors the definition of a Response Transformer in the RPC Subscriptions architecture from `<T>(response: unknown, notificationName: string) => T;` to `RpcResponseTransformer`. That way, both the RPC and RPC Subscriptions architectures use the same interfaces for transforming requests and responses which means we can refactoring helper method like `getDefaultResponseTransformerForSolanaRpcSubscriptions` in a more composable way (using the `pipe` function like we did with default RPC Response Transformer). Note: A changeset for this PR is included in #3407.
This PR replaces the `notificationName` and `params` arguments of the `RpcSubscriptionsPlanExecutor` function by a single `request` argument of type `RpcRequest`. This request argument is meant to represent the user intent to request a subscription from the RPC Subscriptions packages. Note: A changeset for this PR is included in #3407.
3b41daa
to
14ca5cc
Compare
14ca5cc
to
13363b7
Compare
Because there has been no activity on this PR for 14 days since it was merged, it has been automatically locked. Please open a new issue if it requires a follow up. |
This PR adds a changeset combining several smaller changes in the previous PRs of this stack. That way, we provide a slightly more digest changelog.