Forum

Rpc.xdaichain.com sometimes returns duplicate cors headers

On zeroalpha.art we’re seeing occasional failures of requests to https://rpc.xdaichain.com/ :

The response for a failed request:

You can see that the field access-control-allow-origin is indeed set twice.

The request looked like this:

This is something which seems to happen randomly.
The same request usually succeeds (the site polls the state every 5 seconds) - with the response containing only one access-control-allow-origin field (with value set to*).
It looks as if the request is handled by various instances behind a load balancer which behave slightly differently.

1 Like

Thanks for reporting. We deployed a fix and run the page for a few minutes. No errors so far.

Please let us know if the problem is not fixed on your end.

P.S. Someone just purchased the item…

great, thx!
Btw. may it be that the xdai RPC nodes have no min gas price set? Thomas had a tx accepted, but not executed (gas price set to < 1 gwei). If it’s the OpenEthereum client, I suggest to set min_gas_price=1000000000 in the RPC node config.

thanks, btw it’s --min-gas-price=1000000000
but it’s a good question what is the right setting here. some transactions are accepted with 0 GWei, e.g. some system transactions or transactions with transaction priority https://www.xdaichain.com/for-validators/for-consensus-validators/transactions-prioritization-in-aura

ah, didn’t know that there’s 0 gwei txs which go through the public RPC. Then it’s probably a UX tradeoff to be made.