Uploaded image for project: 'mod-data-export-spring'
  1. mod-data-export-spring
  2. MODEXPS-42

Rework scheduling approach for supporting multiple Cron jobs with different configurations

    XMLWordPrintable

    Details

    • Type: Story
    • Status: Closed (View Workflow)
    • Priority: P2
    • Resolution: Done
    • Affects Version/s: None
    • Fix Version/s: None
    • Labels:
    • Template:
    • Sprint:
      ACQ Sprint 129, ACQ Sprint 130
    • Story Points:
      5
    • Development Team:
      Thunderjet
    • Release:
      Lotus R1 2022

      Description

      Overview:
      Current implementation support only one configuration(bursar fees fines) and can't not be used for scheduling jobs for another export types except BURSAR_FEES_FINES

      Purpose:
      Scheduling of the export jobs must supports many configurations and able to schedule Cron jobs for each configuration separately.

      Requirements/Scope:

      1. Scheduling of the export jobs must supports many configurations and able to schedule Cron jobs for each configuration separately.
      2. Schedule time can be reconfigured and Job reschedule with updated configuration

      Approach:
      1. Update logic org.folio.des.controller.FolioTenantController#postTenant: Fetch all the schedule configuration
      2. Update org.folio.des.scheduling.ExportScheduler#configureTasks: new Trigger must be created for each schedule configuration
      Example1 : https://dzone.com/articles/multiple-cron-task-with-spring-boot-scheduler
      Example2 :https://mbcoder.com/dynamic-task-scheduling-with-spring/

      Details how canceling scheduled task under the hood : https://stackoverflow.com/questions/69107355/when-to-use-scheduledthreadpoolexecutors-removeoncancel-policy
      Manage scheduled task : https://programmer.help/blogs/dynamic-add-delete-start-stop-of-timed-tasks-based-on-spring-boot.html

      Acceptance criteria:

      • Logic updated
      • Tested

        TestRail: Results

          Attachments

            Issue Links

              Activity

                People

                Assignee:
                Andrei_Makaranka Andrei Makaranka
                Reporter:
                Andrei_Makaranka Andrei Makaranka
                Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                  Dates

                  Created:
                  Updated:
                  Resolved:

                    TestRail: Runs

                      TestRail: Cases