Skip to content
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

Metrics about claims are not available #571

Open
2 tasks
endersonmaia opened this issue Aug 20, 2024 · 0 comments
Open
2 tasks

Metrics about claims are not available #571

endersonmaia opened this issue Aug 20, 2024 · 0 comments
Assignees
Labels
bug Something isn't working triage To be triaged
Milestone

Comments

@endersonmaia
Copy link
Contributor

endersonmaia commented Aug 20, 2024

🙂 Expected behavior

When the rollups-node sends claims, we should have metrics about it from dispatcher and authority-claimer modules.

  • cartesi_rollups_dispatcher_claims_sent exposed and updated by the dispatcher when it feeds the claims `strea with the claim;
  • cartesi_rollups_authority_claimer_claims_sent exposed and updated by the authority-claimer when it sends the transaction claim to the blockchain.

🫠 Actual behavior

When I run the node with make docker-run and send some inputs, I see no *_claims_sent metrics on the /metrics endpoint.

🧪 Minimal test case

make docker-run
# send some inputs
go run cmd/cartesi-rollups-cli/main.go send --payload 0x$(printf "hello" | xxd -p)
go run cmd/cartesi-rollups-cli/main.go send --payload 0x$(printf "world" | xxd -p)
# wait for the epoch_length
# enter the node and check its `/metrics` endpoint
docker exec -ti rollups-node-node-1 /bin/bash
$ curl localhost:10000/metrics
# HELP cartesi_rollups_dispatcher_claims_sent Counts the number of claims sent.
# TYPE cartesi_rollups_dispatcher_claims_sent counter
# HELP cartesi_rollups_dispatcher_advance_inputs_sent Counts the number of <advance_input>s sent.
# TYPE cartesi_rollups_dispatcher_advance_inputs_sent counter
cartesi_rollups_dispatcher_advance_inputs_sent_total{chain_id="31337",dapp_address="7c54e3f7a8070a54223469965a871fb8f6f88c22"} 2
# HELP cartesi_rollups_dispatcher_finish_epochs_sent Counts the number of <finish_epoch>s sent.
# TYPE cartesi_rollups_dispatcher_finish_epochs_sent counter
cartesi_rollups_dispatcher_finish_epochs_sent_total{chain_id="31337",dapp_address="7c54e3f7a8070a54223469965a871fb8f6f88c22"} 2
# EOF

Checking redis streams, we can see the *:rollups-claims stream was created, thus I expected the _dispatcher_claims_sent to have some value.

# still inside the node
$ redis-cli -p 10011
127.0.0.1:10011> SCAN 0 TYPE stream
1) "0"
2) 1) "{chain-31337:dapp-7c54e3f7a8070a54223469965a871fb8f6f88c22}:rollups-outputs"
   2) "{chain-31337:dapp-7c54e3f7a8070a54223469965a871fb8f6f88c22}:rollups-inputs"
   3) "{chain-31337:dapp-7c54e3f7a8070a54223469965a871fb8f6f88c22}:rollups-claims"

If we connect directly to the authority-claimer port 10002:/metrics endpoint, the value is there.

# still inside the node
$ curl localhost:10002/metrics
# HELP cartesi_rollups_authority_claimer_claims_sent Counts the number of claims sent.
# TYPE cartesi_rollups_authority_claimer_claims_sent counter
cartesi_rollups_authority_claimer_claims_sent_total{chain_id="31337",dapp_address="7c54e3f7a8070a54223469965a871fb8f6f88c22"} 2
# EOF

🌎 Environment

I'm using cartesi/rollups-node:1.5.1-rc1.

✔️ Possible solutions

  • Make authority-claimer metrics appear at 10000:/metrics endpoint.
  • Make dispatcher feed the cartesi_rollups_dispatcher_claims_sent metric
@endersonmaia endersonmaia added bug Something isn't working triage To be triaged labels Aug 20, 2024
@marcelstanley marcelstanley added this to the 1.6 milestone Aug 23, 2024
@marcelstanley marcelstanley self-assigned this Aug 23, 2024
@marcelstanley marcelstanley moved this to 📋 Backlog in Node Unit Aug 23, 2024
@marcelstanley marcelstanley modified the milestones: 1.6, TBD Aug 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working triage To be triaged
Projects
Status: 📋 Backlog
Development

No branches or pull requests

2 participants