Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

720
Views
System.InvalidOperationException: el trabajo recurrente no se puede programar

Tengo este punto final de API que ejecuta C# hangfire.

 RecurringJob.AddOrUpdate<IIngestService>(x => x.Process("ABC"), cronExpression, TimeZoneInfo.Local); RecurringJob.AddOrUpdate<IIngestService>(x => x.Process("XYZ"), cronExpression, TimeZoneInfo.Local);

El problema es que siempre ejecuta Process("XYZ") solamente. Entonces me imagino que tengo que incluir trabajo recurrente si el nombre del método es el mismo.

 RecurringJob.AddOrUpdate<IIngestService>("ABC", x => x.Process("ABC"), cronExpression, TimeZoneInfo.Local); RecurringJob.AddOrUpdate<IIngestService>("XYZ", x => x.Process("XYZ"), cronExpression, TimeZoneInfo.Local);

Cuando ejecuto el trabajo manualmente desde la web de HangFire, funciona sin errores. Pero, cuando el programador hangfire inicia el trabajo automáticamente después de un minuto (Mi trabajo cron es * * * * *), se interrumpe.

El mensaje de error es:

System.InvalidOperationException: el trabajo recurrente no se puede programar, consulte la excepción interna para obtener más información. ---> Hangfire.Common.JobLoadException: no se pudo cargar el trabajo. Consulte la excepción interna para conocer los detalles. ---> System.TypeLoadException: no se pudo cargar el tipo 'xxx.IIngestService' del ensamblado 'xxx.Service, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null'. en System.Reflection.RuntimeAssembly.GetType(QCallAssembly ensamblado, nombre de cadena, booleano throwOnError, booleano ignoreCase, tipo ObjectHandleOnStack, ObjectHandleOnStack keepAlive, ObjectHandleOnStack ensambladoLoadContext)

over 4 years ago · Santiago Trujillo
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!