Skip to content

gateway: support extension hooks #457

@willscott

Description

@willscott

Per ipfs/specs#431 - there is a desire for clients to be able to signal support for additional semantics in their requests to the gateway handler.
ipfs/specs#412 introduced a spec location for signalling of additional parameters.

The ask of the boxo library is how to support usage of the gateway handler with registered support for additional semantics / callback hooks to allow for transformation / changed behavior based upon signalled requests for such.

Currently, the best approach would seem to be for the server to wrap the boxo handler with middleware, which would have to re-parse inbound requests to identify extension semantics, and filter/transform the response as a byte stream. That approach seems like it may lead to unwanted amounts of code reuse. On the flip side, the choice of appropriate hooks to allow server code to plug into does not seem immediately obvious either.

Metadata

Metadata

Assignees

No one assigned

    Labels

    need/triageNeeds initial labeling and prioritization

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions