Skip to content

Commit

Permalink
fix PR comments
Browse files Browse the repository at this point in the history
  • Loading branch information
ranlavanet committed Dec 19, 2024
1 parent 94712fc commit ebfaa9a
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 0 additions & 2 deletions protocol/chainlib/chain_router.go
Original file line number Diff line number Diff line change
Expand Up @@ -188,8 +188,6 @@ func (cri *chainRouterImpl) BatchNodeUrlsByServices(rpcProviderEndpoint lavasess
nodeUrl.Addons = append(nodeUrl.Addons, WebSocketExtension)
routerKey.SetExtensions(nodeUrl.Addons)
}

// _, isAlreadyAutoGenerated := autoGeneratedInternalPaths[nodeUrl.InternalPath]
cri.setRouterKeyInBatch(nodeUrl, returnedBatch, routerKey, rpcProviderEndpoint, true) // will override existing entries

if nodeUrl.InternalPath == "" { // root path
Expand Down
2 changes: 2 additions & 0 deletions protocol/chainlib/jsonRPC.go
Original file line number Diff line number Diff line change
Expand Up @@ -567,13 +567,15 @@ func (cp *JrpcChainProxy) start(ctx context.Context, nConns uint, nodeUrl common
isWs, parseErr := IsUrlWebSocket(nodeUrl.Url)
if parseErr == nil && isWs {
newUrl := strings.TrimSuffix(nodeUrl.Url, "/") + "/ws"
originalUrl := nodeUrl.Url
utils.LavaFormatWarning("Failed creating connector for ws, trying to create with /ws path", err, utils.LogAttr("url", nodeUrl.UrlStr()), utils.LogAttr("newUrl", newUrl))
nodeUrl.Url = newUrl
conn, newConnErr := chainproxy.NewConnector(ctx, nConns, nodeUrl)
if newConnErr == nil {
cp.conn = conn
return nil
}
nodeUrl.Url = originalUrl
}
return err
}
Expand Down

0 comments on commit ebfaa9a

Please sign in to comment.