Skip to content

Conversation

@jframe
Copy link
Contributor

@jframe jframe commented Sep 25, 2025

PR description

Fix EthStats not updating blocks. This due the BlockResult containing an Optional.

This is the exception we are currently getting

ERROR | EthStatsService | Failed to send BLOCK ethstats request with error Java 8 optional type `java.util.Optional<org.hyperledger.besu.ethereum.api.jsonrpc.internal.results.BlockAccessListResult>` not supported by default: add Module "com.fasterxml.jackson.datatype:jackson-datatype-jdk8" to enable handling (through reference chain: org.hyperledger.besu.ethstats.request.EthStatsRequest["emit"]->java.util.ArrayList[1]->org.hyperledger.besu.ethstats.report.ImmutableBlockReport["block"]->org.hyperledger.besu.ethereum.api.jsonrpc.internal.results.BlockResult["blockAccessList"])

Fixed Issue(s)

Thanks for sending a pull request! Have you done the following?

  • Checked out our contribution guidelines?
  • Considered documentation and added the doc-change-required label to this PR if updates are required.
  • Considered the changelog and included an update if required.
  • For database changes (e.g. KeyValueSegmentIdentifier) considered compatibility and performed forwards and backwards compatibility tests

Locally, you can run these tests to catch failures early:

  • spotless: ./gradlew spotlessApply
  • unit tests: ./gradlew build
  • acceptance tests: ./gradlew acceptanceTest
  • integration tests: ./gradlew integrationTest
  • reference tests: ./gradlew ethereum:referenceTests:referenceTests
  • hive tests: Engine or other RPCs modified?

Signed-off-by: Jason Frame <jason.frame@consensys.net>
Signed-off-by: Jason Frame <jason.frame@consensys.net>
Signed-off-by: Jason Frame <jason.frame@consensys.net>
Signed-off-by: Jason Frame <jason.frame@consensys.net>
Signed-off-by: Jason Frame <jason.frame@consensys.net>
@jframe jframe marked this pull request as ready for review September 25, 2025 04:14
Signed-off-by: Jason Frame <jason.frame@consensys.net>
@jframe jframe changed the title Fix EthStats not updating blocks Fix EthStats integration with updating blocks Sep 25, 2025
@fab-10 fab-10 enabled auto-merge (squash) September 25, 2025 10:58
@fab-10 fab-10 merged commit ad769d3 into hyperledger:main Sep 25, 2025
46 checks passed
AliZDev-v0 pushed a commit to AliZDev-v0/besu that referenced this pull request Oct 5, 2025
* Fix EthStats not updating blocks

Signed-off-by: Jason Frame <jason.frame@consensys.net>

* Update gradle to include jackson-datatype-jdk8 for ethstats module

Signed-off-by: Jason Frame <jason.frame@consensys.net>

* changelog

Signed-off-by: Jason Frame <jason.frame@consensys.net>

* test for sending ethstats block message

Signed-off-by: Jason Frame <jason.frame@consensys.net>

* rename test

Signed-off-by: Jason Frame <jason.frame@consensys.net>

* rename test

Signed-off-by: Jason Frame <jason.frame@consensys.net>

---------

Signed-off-by: Jason Frame <jason.frame@consensys.net>
Co-authored-by: Fabio Di Fabio <fabio.difabio@consensys.net>
Signed-off-by: Ali Zhagparov <alijakparov.kz@gmail.com>
jflo pushed a commit to jflo/besu that referenced this pull request Oct 13, 2025
* Fix EthStats not updating blocks

Signed-off-by: Jason Frame <jason.frame@consensys.net>

* Update gradle to include jackson-datatype-jdk8 for ethstats module

Signed-off-by: Jason Frame <jason.frame@consensys.net>

* changelog

Signed-off-by: Jason Frame <jason.frame@consensys.net>

* test for sending ethstats block message

Signed-off-by: Jason Frame <jason.frame@consensys.net>

* rename test

Signed-off-by: Jason Frame <jason.frame@consensys.net>

* rename test

Signed-off-by: Jason Frame <jason.frame@consensys.net>

---------

Signed-off-by: Jason Frame <jason.frame@consensys.net>
Co-authored-by: Fabio Di Fabio <fabio.difabio@consensys.net>
Signed-off-by: jflo <justin+github@florentine.us>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants