Skip to content

Built-in support for something similar to nginx proxy_redirect default #1548

Open
@per-samuelsson

Description

@per-samuelsson

Tried to read everything in both #21 and #13, plus related PRs, and did tests myself.

But I can't find anything like a built-in feature similar to that of nginx' proxy_redirect default (which is enabled there by default).

So, before I start implementing my own (using response transforms), just want to make sure I didn't miss anything? And, of course, also, if it's not there, I'd suggest it as a great improvement. 😃

Gist of what I'm looking for:

.AddTransforms(transformBuilderContext =>
{
    transformBuilderContext.AddResponseTransform(async transformContext =>
    {
        await transformContext.RedirectProxyLocationOfNewResource();
    });
})

where RedirectProxyLocationOfNewResource would implement something like

// => POST http://service.myproxy.com {...}
//   => POST https://some-backend-service.com {...}
//   <= HTTP 201: Location: https://some-backend-service.com/path/to/resource
// <= HTTP 201: Location: http://service.myproxy/path/to/resource

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type: IdeaThis issue is a high-level idea for discussion.help wantedWe will welcome a contribution

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions