-
-
Notifications
You must be signed in to change notification settings - Fork 104
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
Hangfire configuration and the recurring UserSessionJob #830
Comments
Hello, First question: To view the configuration of the recurring job, you can access the Hangfire dashboard. To enable this feature, edit the Program.cs file and add the following instruction before UseSID:
Sample project : https://github.com/simpleidserver/SimpleIdServer/tree/Release503/samples/AddHangfireUi Unfortunately, at the moment, it is not possible to edit the cron expressions of the different jobs. I have created a new ticket to support this feature: Ticket#831. Second question : Indeed, the configuration of the IDidFactoryResolver service should be moved to our application builder. In the meantime, can you add the missing registration as follows?
KR, SID |
Thank you for the reply. I will take a look at the dashboard. I'll need to reach out to our Cyber department to find out if that's something we can even deploy to Production. I can definitely add the registration in the meantime. Do you have an idea when the v5.0.3 packages might be available? |
Hello, The version 5.0.3 will be published by the end of the month! 🙂 Next month, we’ll release version 6.0.0, which introduces a new feature: a form builder. This feature will allow you to customize the UI and workflow for authentication and registration. KR |
We are finally upgrading to v5.x. For context see prior issue: #725
First question:
I'm trying to upgrade to the 5.0.0 packages first. We aren't using back channel authentication, so Hangfire is not being pulled in. I can add the service manually, but then the UserSessionJob keeps firing every 10-15 seconds. I can kill the job, but I'd rather disable Hangfire altogether.
I feel like adding a flag to the following lines (or moving them to the IsBCEnabled section) in SimpleIdServer.IdServer's WebApplicationExtension.cs would make that possible:
var reccuringJobManager = webApplication.Services.GetRequiredService();
// Occurs every 10 seconds.
reccuringJobManager.AddOrUpdate(nameof(UserSessionJob), j => webApplication.Services.GetRequiredService().Execute(), "*/10 * * * * *");
If Hangfire is necessary regardless of whether or not back channel authentication is enabled, is there a way to configure it so we have some control over what background jobs are created, whether they are recurring or fire and forget, the time in between firing, etc.?
Second question/issue:
I tried to upgrade directly to the 5.2.0 packages (NuGet packages used: SimpleIdServer.IdServer and SimpleIdServer.IdServer.SqlServerMigrations), but I received the following dependency injection error:
I feel like the DI should be handled in the package and not inside our application builder, but I could be wrong. I decided to start with v5.0.0, since that code doesn't include that AuthorizationCallbackRequestHandler class. Plan to upgrade incrementally after, but figured I might as well ask about that while I'm here.
The text was updated successfully, but these errors were encountered: