-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
WS URL can be optional when LogBroadcaster is disabled #14364
Conversation
core/chains/evm/client/evm_client.go
Outdated
@@ -20,7 +20,7 @@ func NewEvmClient(cfg evmconfig.NodePool, chainCfg commonclient.ChainConfig, cli | |||
var sendonlys []commonclient.SendOnlyNode[*big.Int, RPCClient] | |||
largePayloadRPCTimeout, defaultRPCTimeout := getRPCTimeouts(chainType) | |||
for i, node := range nodes { | |||
if node.SendOnly != nil && *node.SendOnly { | |||
if node.WSURL == nil || (node.SendOnly != nil && *node.SendOnly) { |
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.
A secondary or SendOnly node has limited functionality. It's only used to broadcast transactions (fire and forget), and we are not running health checks for it.
We should not change the type of the node. Instead, introduce changes to the RPC client.
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.
Moving the enforcement check to Dial()
at rpc_client.go
…BCFR-451/make-ws-url-optional
Quality Gate passedIssues Measures |
Optional WS URL for RPCs to unblock new chain integration. Charry-picks from: smartcontractkit/chainlink#14354 smartcontractkit/chainlink#14373 smartcontractkit/chainlink#14534 smartcontractkit/chainlink#14364 smartcontractkit/chainlink#14929 --------- Co-authored-by: Joe Huang <joe.huang@smartcontract.com>
Optional WS URL for RPCs to unblock new chain integration. Charry-picks from: smartcontractkit/chainlink#14534 smartcontractkit/chainlink#14364 smartcontractkit/chainlink#14929 --------- Co-authored-by: Joe Huang <joe.huang@smartcontract.com> Co-authored-by: Adam Hamrick <adam.hamrick@smartcontract.com> Co-authored-by: Chunkai Yang <matYang@users.noreply.github.com>
Description
WS URL can be optional (empty string) when LogBroadcaster is disabled. If WS URL was not provided, SubscribeFilterLogs should fail with an explicit error
Tickets:
BCFR-451