To execute a scheduled job in Oracle Integration Cloud (OIC) that runs only on weekdays (Monday to Friday) excluding public holidays, We can follow these steps:
1. Set Up the Weekday Recurrence in OIC:
we can use a recurrence pattern to run the job only on weekdays. choose the iCal format.Set the frequency to DAILY and restrict it to Monday to Friday using the BYDAY parameter.
For example:
FREQ=DAILY;BYDAY=MO,TU,WE,TH,FR
This ensures the job only runs Monday through Friday.
2. Exclude Public Holidays:
OIC doesn't provide a built-in way to exclude public holidays automatically. You'll need to handle this manually or programmatically. Here are some approaches:
Option 1: Manually Disable the Job for Public Holidays
Create a list of public holidays, and manually disable the schedule on those days.You could either:Pause the integration the day before the holiday, orModify the recurrence rules around those dates.
Option 2: Use a Lookup Table for Public Holidays
Create a lookup table that contains the list of public holidays.Modify the integration to check the current date against this list at runtime.If the current date is a public holiday, the job won’t proceed further.
Option 3: Programmatically Handle Holidays in the Integration Flow
In the integration logic, before running the core job, add a step that checks if the current date is a public holiday (by querying a list of holidays stored in a file or a database).If it's a public holiday, you can skip the execution.
You can combine options 1 and 3 for flexibility. Manually manage the public holidays for the current year and set up a query mechanism for holidays that changes each year.
No comments:
Post a Comment