Skip to content

Use SSZ by default for VC <--> BN requests #15317

@rkapka

Description

@rkapka

Description

more and more endpoints now support SSZ, we support it beacon apis and builders will be supporting ssz soon ethereum/builder-specs#104

  • for GET requests we should use this "Accept: application/octet-stream;q=0.95,application/json;q=0.9" kind of header. and beacon nodes should support this. (in prysm we are not respecting this. need to investigate)
  • for POST requests, we need the cache. (cache should be per url, to support multiple beacon nodes. this is how lodestar implements it). We could have the cache expire after a while (like 2 weeks), but not strictly necessary. but the cache should reset after vc restart.

Describe the solution you'd like

- [x] add a flag for enabling ssz, add it as a new feature flag

  • Create of list of endpoints that support vs not support SSZ for this feature

  • --use-ssz and --use-json, for debugging purposes.

  • /eth/v3/validator/blocks/{slot}

  • /eth/v2/beacon/blocks

  • /eth/v2/beacon/blinded_blocks

  • create list of endpoints that can be done in ssz and which are not for the validator client

  • have ssz fall back to json is not available & cache the response
    - add new condition either at the http client level or at the endpoint itself

Metadata

Metadata

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions