emeraldpay / dshackle

Fault Tolerant Load Balancer for Ethereum and Bitcoin APIs
Apache License 2.0
298 stars 65 forks source link

1.14: Two upstreams share the same priority #242

Open PDVJAM opened 1 year ago

PDVJAM commented 1 year ago

Upgraded to 1.14 and see the following in logs:

2023-06-06 15:23:52.964 | WARN  |   PriorityForkChoice | Two upstreams share the same priority. It can cause an unpredicted behaviour of the Dshackle. Check config for alchemy and infura, both have 10 priority

But the config is actually has different priorities for alchemy and infura upstreams:

    - id: alchemy
      chain: ethereum
      role: secondary
      priority: 20
      options:
        disable-validation: true
        validation-interval: 60
      connection:
        ethereum:
          rpc:
            url: "https://eth-mainnet.g.alchemy.com/v2/${ALCHEMY_KEY}"
    - id: infura
      chain: ethereum
      role: primary
      priority: 10
      options:
        disable-validation: true
        validation-interval: 60
      connection:
        ethereum:
          rpc:
            url: "https://mainnet.infura.io/v3/${INFURA_DA_USER}"
          ws:
            url: "wss://mainnet.infura.io/ws/v3/${INFURA_DA_USER}"

Seems like a small bug.

AJolly commented 10 months ago

Running into the same issue.