iotex-core icon indicating copy to clipboard operation
iotex-core copied to clipboard

add blockdao server and grpc blockdao

Open CoderZhi opened this issue 1 year ago • 5 comments

Add grpc blockdao, which will request blockdao server to read data remotely

Follow up PR needed to setup a sever to serve blockdao (including building)

Type of change

Please delete options that are not relevant.

  • [] Bug fix (non-breaking change which fixes an issue)
  • [] New feature (non-breaking change which adds functionality)
  • [] Code refactor or improvement
  • [] Breaking change (fix or feature that would cause a new or changed behavior of existing functionality)
  • [] This change requires a documentation update

How Has This Been Tested?

Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration

  • [] make test
  • [] fullsync
  • [] Other test (please specify)

Test Configuration:

  • Firmware version:
  • Hardware:
  • Toolchain:
  • SDK:

Checklist:

  • [] My code follows the style guidelines of this project
  • [] I have performed a self-review of my code
  • [] I have commented my code, particularly in hard-to-understand areas
  • [] I have made corresponding changes to the documentation
  • [] My changes generate no new warnings
  • [] I have added tests that prove my fix is effective or that my feature works
  • [] New and existing unit tests pass locally with my changes
  • [] Any dependent changes have been merged and published in downstream modules

CoderZhi avatar May 07 '24 07:05 CoderZhi

add a flag in config, to selectively start this grpc blockdao service when starting the node?

dustinxie avatar May 08 '24 00:05 dustinxie

The aim seems to setup a side server to serve blockdao directly. The code would be better to be added in ./server or ./tools package.

Liuhaai avatar May 08 '24 23:05 Liuhaai

Codecov Report

Attention: Patch coverage is 3.34928% with 202 lines in your changes missing coverage. Please review.

Project coverage is 74.82%. Comparing base (36f0d99) to head (8de28fe). Report is 16 commits behind head on master.

Files with missing lines Patch % Lines
blockchain/blockdao/grpcblockdao.go 0.00% 127 Missing :warning:
api/blockdaoservice.go 3.84% 75 Missing :warning:
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #4263      +/-   ##
==========================================
- Coverage   75.86%   74.82%   -1.04%     
==========================================
  Files         361      368       +7     
  Lines       30116    30501     +385     
==========================================
- Hits        22846    22823      -23     
- Misses       6134     6519     +385     
- Partials     1136     1159      +23     

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

codecov[bot] avatar Aug 30 '24 00:08 codecov[bot]