Skip to content

Allow extending ServerContext and/or ServerRequest with additional information #2159

Open
@sergiocampama

Description

@sergiocampama

I'm implementing a Vapor server where I can process grpc-web and regular API routes. While I have the entire request/response flow working (custom transport implementation specific for grpc-web), I'm missing passing in more context into the gRPC services in relation to the request itself. Vapor's Request object is fairly complete with much context needed to process any kind of request, while ServerRequest from grpc-swift doesn't have much going on other than metadata.

Would it align with this project to extend these objects so that we can pass arbitrary contexts into the requests themselves, so that they can be injected along the request path into the GRPCService itself?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions