RPC: http cache header mod
What
Relative (head-n) queries are always changing which creates friction for integrating Octez RPCs with generic Caches as operators needs extra logic/heuristics to know when to invalidate such a response. To get around this, we introduce relevant HTTP Cache headers into the responses of Octez RPCs. The headers to be implemented are Expires
and If-None-Modified
. This is an ongoing work with multiple MRs.
Adds the skeleton of Http cache headers module. The 2 inner function parse_block_uri
and add_headers
will be used by all other middleware of this type.
1/n
Why
Base module for implementing http cache headers middleware.
How
Implements the skeleton mod.
Manually testing the MR
Checklist
-
Document the interface of any function added or modified (see the coding guidelines) -
Document any change to the user interface, including configuration parameters (see node configuration) -
Provide automatic testing (see the testing guide). -
For new features and bug fixes, add an item in the appropriate changelog ( docs/protocols/alpha.rst
for the protocol and the environment,CHANGES.rst
at the root of the repository for everything else). -
Select suitable reviewers using the Reviewers
field below. -
Select as Assignee
the next person who should take action on that MR