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

feat: Add graphql query fields for retreiving information about upgrades #2119

Conversation

netrome
Copy link
Contributor

@netrome netrome commented Aug 20, 2024

Linked Issues/PRs

Closes #2071

Description

This PR adds the following three new query fields

  • consensusParameters(version: Int!): ConsensusParameters!
  • stateTransitionBytecodeByVersion(version: Int!): StateTransitionBytecode
  • stateTransitionBytecodeByRoot(root: HexString!): StateTransitionBytecode!

which help provide more insights in previous upgrades on the chain.

Checklist

  • Breaking changes are clearly marked as such in the PR description and changelog
  • New behavior is reflected in tests
  • The specification matches the implemented behavior (link update PR if changes are needed)

Before requesting review

  • I have reviewed the code myself
  • I have created follow-up issues caused by this PR and linked them here

After merging, notify other teams

@netrome netrome self-assigned this Aug 20, 2024
@netrome netrome linked an issue Aug 20, 2024 that may be closed by this pull request
@netrome netrome added the graphql-api Affects API of the GraphQL label Aug 20, 2024
@@ -11,7 +11,8 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
### Added
- [2051](https://github.com/FuelLabs/fuel-core/pull/2051): Add support for AWS KMS signing for the PoA consensus module. The new key can be specified with `--consensus-aws-kms AWS_KEY_ARN`.
- [2092](https://github.com/FuelLabs/fuel-core/pull/2092): Allow iterating by keys in rocksdb, and other storages.
- [2096](https://github.com/FuelLabs/fuel-core/pull/2096): GraphQL endpoint to fetch blob byte code by its blob ID.
- [2096](https://github.com/FuelLabs/fuel-core/pull/2096): GraphQL query field to fetch blob byte code by its blob ID.
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Note: I just renamed "endpoint" to "query field" here as I realized these are technically not endpoints.

@netrome netrome marked this pull request as ready for review August 21, 2024 08:36
@netrome netrome requested a review from a team August 21, 2024 08:36
crates/client/assets/schema.sdl Outdated Show resolved Hide resolved
crates/fuel-core/src/query/block.rs Show resolved Hide resolved
@netrome netrome requested review from a team and rymnc August 26, 2024 07:34
Dentosal
Dentosal previously approved these changes Aug 26, 2024
@netrome netrome force-pushed the 2071-add-new-graphql-endpoints-for-retrieving-information-about-upgrades branch from 7d50174 to 4b3c09c Compare August 26, 2024 12:18
@netrome netrome requested a review from Dentosal August 26, 2024 12:18
@netrome netrome merged commit 74dae6d into master Aug 26, 2024
35 checks passed
@netrome netrome deleted the 2071-add-new-graphql-endpoints-for-retrieving-information-about-upgrades branch August 26, 2024 13:12
@xgreenx xgreenx mentioned this pull request Aug 28, 2024
xgreenx added a commit that referenced this pull request Aug 28, 2024
## Version v0.35.0

### Added
- [2122](#2122): Changed the
relayer URI address to be a vector and use a quorum provider. The
`relayer` argument now supports multiple URLs to fetch information from
different sources.
- [2119](#2119): GraphQL query
fields for retrieving information about upgrades.

### Changed
- [2113](#2113): Modify the
way the gas price service and shared algo is initialized to have some
default value based on best guess instead of `None`, and initialize
service before graphql.
- [2112](#2112): Alter the way
the sealed blocks are fetched with a given height.
- [2120](#2120): Added
`submitAndAwaitStatus` subscription endpoint which returns the
`SubmittedStatus` after the transaction is submitted as well as the
`TransactionStatus` subscription.
- [2115](#2115): Add test for
`SignMode` `is_available` method.
- [2124](#2124): Generalize
the way p2p req/res protocol handles requests.

#### Breaking

- [2040](#2040): Added full
`no_std` support state transition related crates. The crates now require
the "alloc" feature to be enabled. Following crates are affected:
  - `fuel-core-types`
  - `fuel-core-storage`
  - `fuel-core-executor`
- [2116](#2116): Replace
`H160` in config and cli options of relayer by `Bytes20` of `fuel-types`

### Fixed
- [2134](#2134): Perform
RecoveryID normalization for AWS KMS -generated signatures.

## What's Changed
* Change TODO clippy to wait for false positive correction by
@AurelienFT in #2110
* Remove option on shared algo, give default algo, reorder service
startup by @MitchTurner in
#2113
* chore(sealed_blocks): optimize fetching of sealed block header at a
given height by @rymnc in
#2112
* chore(p2p_service): remove unnecessary cast to usize by @rymnc in
#2123
* Added a benchmark for the predicate with ed19 verification by @xgreenx
in #2127
* Add test SignMode is_available by @AurelienFT in
#2115
* feat: Add graphql query fields for retreiving information about
upgrades by @netrome in #2119
* Small code optimizations by @MoneyBund in
#2035
* Change relayer URI address to be vector and use quorum provider by
@AurelienFT in #2122
* chore(p2p_service): clean up processing of p2p req/res protocol by
@rymnc in #2124
* feat: add `submitAndAwaitStatus` subscription endpoint by @maschad in
#2120
* Replace H160 in config and cli options of relayer by Bytes20 by
@AurelienFT in #2116
* Secp256k1 RecoveryID correction for KMS-genrated signatures by
@Dentosal in #2134
* Added `no_std` support state transition related crates by @xgreenx in
#2040

## New Contributors
* @MoneyBund made their first contribution in
#2035
* @maschad made their first contribution in
#2120

**Full Changelog**:
v0.34.0...v0.35.0
GoldenPath1109 added a commit to GoldenPath1109/fuel-core that referenced this pull request Sep 7, 2024
## Version v0.35.0

### Added
- [2122](FuelLabs/fuel-core#2122): Changed the
relayer URI address to be a vector and use a quorum provider. The
`relayer` argument now supports multiple URLs to fetch information from
different sources.
- [2119](FuelLabs/fuel-core#2119): GraphQL query
fields for retrieving information about upgrades.

### Changed
- [2113](FuelLabs/fuel-core#2113): Modify the
way the gas price service and shared algo is initialized to have some
default value based on best guess instead of `None`, and initialize
service before graphql.
- [2112](FuelLabs/fuel-core#2112): Alter the way
the sealed blocks are fetched with a given height.
- [2120](FuelLabs/fuel-core#2120): Added
`submitAndAwaitStatus` subscription endpoint which returns the
`SubmittedStatus` after the transaction is submitted as well as the
`TransactionStatus` subscription.
- [2115](FuelLabs/fuel-core#2115): Add test for
`SignMode` `is_available` method.
- [2124](FuelLabs/fuel-core#2124): Generalize
the way p2p req/res protocol handles requests.

#### Breaking

- [2040](FuelLabs/fuel-core#2040): Added full
`no_std` support state transition related crates. The crates now require
the "alloc" feature to be enabled. Following crates are affected:
  - `fuel-core-types`
  - `fuel-core-storage`
  - `fuel-core-executor`
- [2116](FuelLabs/fuel-core#2116): Replace
`H160` in config and cli options of relayer by `Bytes20` of `fuel-types`

### Fixed
- [2134](FuelLabs/fuel-core#2134): Perform
RecoveryID normalization for AWS KMS -generated signatures.

## What's Changed
* Change TODO clippy to wait for false positive correction by
@AurelienFT in FuelLabs/fuel-core#2110
* Remove option on shared algo, give default algo, reorder service
startup by @MitchTurner in
FuelLabs/fuel-core#2113
* chore(sealed_blocks): optimize fetching of sealed block header at a
given height by @rymnc in
FuelLabs/fuel-core#2112
* chore(p2p_service): remove unnecessary cast to usize by @rymnc in
FuelLabs/fuel-core#2123
* Added a benchmark for the predicate with ed19 verification by @xgreenx
in FuelLabs/fuel-core#2127
* Add test SignMode is_available by @AurelienFT in
FuelLabs/fuel-core#2115
* feat: Add graphql query fields for retreiving information about
upgrades by @netrome in FuelLabs/fuel-core#2119
* Small code optimizations by @MoneyBund in
FuelLabs/fuel-core#2035
* Change relayer URI address to be vector and use quorum provider by
@AurelienFT in FuelLabs/fuel-core#2122
* chore(p2p_service): clean up processing of p2p req/res protocol by
@rymnc in FuelLabs/fuel-core#2124
* feat: add `submitAndAwaitStatus` subscription endpoint by @maschad in
FuelLabs/fuel-core#2120
* Replace H160 in config and cli options of relayer by Bytes20 by
@AurelienFT in FuelLabs/fuel-core#2116
* Secp256k1 RecoveryID correction for KMS-genrated signatures by
@Dentosal in FuelLabs/fuel-core#2134
* Added `no_std` support state transition related crates by @xgreenx in
FuelLabs/fuel-core#2040

## New Contributors
* @MoneyBund made their first contribution in
FuelLabs/fuel-core#2035
* @maschad made their first contribution in
FuelLabs/fuel-core#2120

**Full Changelog**:
FuelLabs/fuel-core@v0.34.0...v0.35.0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
graphql-api Affects API of the GraphQL
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add new GraphQL endpoints for retrieving information about upgrades
3 participants