block-explorer icon indicating copy to clipboard operation
block-explorer copied to clipboard

Improve the block loading for the block view

Open AlexITC opened this issue 7 years ago • 0 comments

Update the block API to retrieve a block from the database and fallback to the xsnd.

Expected behavior

There are two endpoints for loading a block:

  1. GET /blocks/:query -> Loads the block data from the database.
  2. GET /blocks/:query/legacy -> Loads the block data from the xsnd.

The web-ui tries to load a block from the database, when it isn't present, it tries to load it from the xsnd, a message is displayed if it doesn't exists.

When the 1st method is used, the confirmations field should be computed on the client.

Actual behavior

The GET /blocks/:query loads a block from the block from the xsnd while we might have it on the database.

AlexITC avatar Oct 01 '18 05:10 AlexITC