You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Feb 5, 2025. It is now read-only.
Which version of Duende BFF are you using?
None yet, still spiking with latest versions
Which version of .NET are you using?
.NET 6.0
Describe the bug
We would like to overwrite the ManagementBasePath to a complex segment. So instead of it being /bff we want regex, ie: /{path:regex(^[a-zA-Z\\d-]+$)}/bff.
To Reproduce
You can test this out by changing the ManagementBasePath to the below code:
// Add BFF services to DI - also add server-side session management
services.AddBff(options =>
{
options.ManagementBasePath = new PathString("/{path:regex(^[a-zA-Z\\d-]+$)}/bff");
})
.AddRemoteApis();
After this change calling /admin/bff endpoints do not work.
Expected behavior
That calling /admin/bff endpoints work as per the regex.
The change to make this work is simply updating code in BffEndpointRouteBuilderExtensions.cs from options.SomePath to options.SomePath.Value.
Our tenancy model is a bit unique, this will open up opportunities for us to simplify our deployment and configurations. It's not something we need tomorrow, our spike is done and this is what we found. I just wanted to start the conversation, we'll be deciding on which approach to go in a few months depending if this request is implemented.
Which version of Duende BFF are you using?
None yet, still spiking with latest versions
Which version of .NET are you using?
.NET 6.0
Describe the bug
We would like to overwrite the
ManagementBasePath
to a complex segment. So instead of it being/bff
we want regex, ie:/{path:regex(^[a-zA-Z\\d-]+$)}/bff
.To Reproduce
You can test this out by changing the
ManagementBasePath
to the below code:After this change calling
/admin/bff
endpoints do not work.Expected behavior
That calling
/admin/bff
endpoints work as per the regex.The change to make this work is simply updating code in
BffEndpointRouteBuilderExtensions.cs
fromoptions.SomePath
tooptions.SomePath.Value
.ie:
Additional context
I'm wondering if you'd consider this change.
Thanks.
The text was updated successfully, but these errors were encountered: