solarlabsteam / cosmos-exporter

Scrape the data about the validators set, specific validators or wallets in the Cosmos network.
75 stars 73 forks source link

Kava /metrics/validator not working #8

Open shifty11 opened 2 years ago

shifty11 commented 2 years ago

I tried to use it with my Kava node. Everything works except the scraping of validator metrics with a specific address.

Query: MY_IP:9300/metrics/validator?address=kavavaloper16wmsum8eaf6sqmj97k9ayvh3c28u00nuuyt9xt

This is the log output. It seems like the query for delegations never finishes. It has a Started querying validator delegations but no end.

2:27AM DBG Started querying validator address=kavavaloper16wmsum8eaf6sqmj97k9ayvh3c28u00nuuyt9xt request-id=570860da-06bb-4a87-bab2-f9059747f043
2:27AM DBG Finished querying validator address=kavavaloper16wmsum8eaf6sqmj97k9ayvh3c28u00nuuyt9xt request-id=570860da-06bb-4a87-bab2-f9059747f043 request-time=1.277257541
2:27AM DBG Started querying validator other validators address=kavavaloper16wmsum8eaf6sqmj97k9ayvh3c28u00nuuyt9xt request-id=570860da-06bb-4a87-bab2-f9059747f043
2:27AM DBG Started querying validator delegations address=kavavaloper16wmsum8eaf6sqmj97k9ayvh3c28u00nuuyt9xt request-id=570860da-06bb-4a87-bab2-f9059747f043
2:27AM DBG Started querying validator commission address=kavavaloper16wmsum8eaf6sqmj97k9ayvh3c28u00nuuyt9xt request-id=570860da-06bb-4a87-bab2-f9059747f043
2:27AM DBG Started querying validator rewards address=kavavaloper16wmsum8eaf6sqmj97k9ayvh3c28u00nuuyt9xt request-id=570860da-06bb-4a87-bab2-f9059747f043
2:27AM DBG Started querying validator unbonding delegations address=kavavaloper16wmsum8eaf6sqmj97k9ayvh3c28u00nuuyt9xt request-id=570860da-06bb-4a87-bab2-f9059747f043
2:27AM DBG Started querying validator redelegations address=kavavaloper16wmsum8eaf6sqmj97k9ayvh3c28u00nuuyt9xt request-id=570860da-06bb-4a87-bab2-f9059747f043
2:27AM DBG Started querying validator signing info address=kavavaloper16wmsum8eaf6sqmj97k9ayvh3c28u00nuuyt9xt request-id=570860da-06bb-4a87-bab2-f9059747f043
2:27AM DBG Finished querying validator signing info address=kavavaloper16wmsum8eaf6sqmj97k9ayvh3c28u00nuuyt9xt request-id=570860da-06bb-4a87-bab2-f9059747f043 request-time=0.092198156
2:27AM DBG Finished querying validator signing info address=kavavaloper16wmsum8eaf6sqmj97k9ayvh3c28u00nuuyt9xt missedBlocks=0 request-id=570860da-06bb-4a87-bab2-f9059747f043
2:27AM DBG Finished querying validator commission address=kavavaloper16wmsum8eaf6sqmj97k9ayvh3c28u00nuuyt9xt request-id=570860da-06bb-4a87-bab2-f9059747f043 request-time=0.289733001
2:27AM DBG Finished querying validator rewards address=kavavaloper16wmsum8eaf6sqmj97k9ayvh3c28u00nuuyt9xt request-id=570860da-06bb-4a87-bab2-f9059747f043 request-time=0.489137674
2:27AM DBG Finished querying validator redelegations address=kavavaloper16wmsum8eaf6sqmj97k9ayvh3c28u00nuuyt9xt request-id=570860da-06bb-4a87-bab2-f9059747f043 request-time=1.916307469
2:27AM DBG Finished querying validator unbonding delegations address=kavavaloper16wmsum8eaf6sqmj97k9ayvh3c28u00nuuyt9xt request-id=570860da-06bb-4a87-bab2-f9059747f043 request-time=2.01117766
albttx commented 2 years ago

i had the same issue on JUNO,

the query return me the result after 3m55s ...

:warning: Be careful, this could DDoS your validator

shifty11 commented 2 years ago

Ah yes I see now that it takes between 2 and 3 minutes. Well okay in that case I will scrape it once every 5 or 10 minutes and it should be fine.

albttx commented 2 years ago

Do you have any idea why is it that long ? I'm running it on Stargaze, Ki, Cheqd, I don't have any issue...

shifty11 commented 2 years ago

I don't know I run it on Chihuahua, Dig and Kava. Only Kava makes troubles. I will post it if I find out more.

albttx commented 2 years ago

After a chat with @polkachu he had an idea, that could be because the node run indexer="kv" I'll take a look and keeps in touch

or maybe the --limit could help