Hello there. I am new to this forum. I would like to pose a questiong regarding using Guid instead of Int.
To begin with, I am making a asp.net core project where users can schedule notifications. This notifications can either be scheduled using BackgroundJob.Schedule or ReccuringJobManager.AddOrUpdate methods. So here I encountered a problem: .Schedule return type is Int, but in .AddOrUpdate I obviously need to pass Guid to be sure that It will be unique. ( my whole project is using Guid ).
All that things is because I have a classes that represent currently active background tasks and the actual task have all information what to do including List and List to plan it multiple times.
- ScheduledJob ( ExecuteUtc: DateTime, Id: Guid ).
- ReccurringJob ( CronExpressionUtc: stirng, Id: Guid ).
Along with that, I need to pass to a PlanTransmissionRequested object an Id of a plan, so scheduled plan will be deleted from my SQLite database as soon as it executes.
I need somehow to make .Schedule return Guid. I was trying to figure it out for the last 3 days and nothing comes up to my mind. I browsed whole internet including ChatGPT.
For now I am using SQLite as a job storage for Hangfire jobs, but then I will be using postgres ( in Docker )