Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Progress endpoint won't respect PrefixPath defined in dashboard UI #125

Open
eCorke opened this issue Jun 29, 2023 · 8 comments
Open

Progress endpoint won't respect PrefixPath defined in dashboard UI #125

eCorke opened this issue Jun 29, 2023 · 8 comments

Comments

@eCorke
Copy link

eCorke commented Jun 29, 2023

It seems that progress circular loading that's shown in overview of running tasks (for each row) doesn't respect PrefixPath defined in dashboard registration. The repeated requests towards hangfire/console/progress is never prefixed.

As in my case, the dashboard is exposed on sub address (https://localhost:6001/application/hangfire...) with PrefixPath defined as application, the progress requests point to https://localhost:6001/hangfire/console/progress

@khellang
Copy link

khellang commented Oct 20, 2023

The code just uses default Hangfire APIs to register dashboard routes:

// register dispatchers to serve console data
DashboardRoutes.Routes.Add("/console/progress", new JobProgressDispatcher(options));
DashboardRoutes.Routes.Add("/console/([0-9a-f]{11}.+)", new ConsoleDispatcher(options));

I think this might be a bug in Hangfire itself?

@AnderssonPeter
Copy link

@khellang I saw that you created a fork of this repository, I have a nuget package that extends this one and was thinking about creating 2 additional nugets that target your fork.
Is it ok if I named them IdentityStream.Hangfire.Console.Extensions and IdentityStream.Hangfire.Console.Extensions.Serilog? (If it's your company name I fully understand if your not OK with it!!)

https://github.com/AnderssonPeter/Hangfire.Console.Extensions
https://www.nuget.org/packages/Hangfire.Console.Extensions
https://www.nuget.org/packages/Hangfire.Console.Extensions.Serilog

@khellang
Copy link

khellang commented Nov 7, 2023

I'm not totally opposed to it, but the IdentityStream.* prefix is reserved for my company's account on NuGet.org, so I'm not sure how doable it is. Any other suggestions? 😆

@AnderssonPeter
Copy link

If that is the case how about Hangfire.Console.Extensions.IdentityStream and Hangfire.Console.Extensions.Serilog.IdentityStream?

@khellang
Copy link

khellang commented Nov 7, 2023

Yeah, that's fine 👍🏻

@AnderssonPeter
Copy link

@khellang seems like anything with the name IdentityStream in it is reserved.
How about if you create a API Key that only allows me to push IdentityStream.Hangfire.Console.*? (You can specify a pattern when you create the key)

@khellang
Copy link

khellang commented Nov 9, 2023

Hmm. That's weird. I wonder what part of "prefix" Microsoft doesn't get? 😆 The prefix is explicitly IdentityStream.*:

image

I'm not too keen on having packages we don't maintain sitting under the IdentityStream NuGet organization either 🤔

@khellang
Copy link

khellang commented Nov 9, 2023

What about IdS.Hangfire.Console.Extensions or Hangfire.Console.Extensions.IdS? 😅

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants