How to use webMethods Integration Server business Calendars to check company holidays
webMethods Integration Server Common Directory Service(CDS) supports the use of business calendars and user calendars. These calendars can be used in Integration Server flow services to stop running Scheduling Tasks in company holidays
Prerequisites
1. Install Common Directory Service database component
Run IBM WebMethods Database Component Configurator and install CommonDirectoryServices database schema in Integration Server Database schema.
Note: This is not required if you are already using My WebMethods Server for User Management (MWS).
2. Install Common Directory Services WmCDS package using Installer
Select Common Directory Services Support 11.1 and Center User Management 11.1 options when installing the software
3. Configure Integration Server JDBC Pool alias
Configure Integration Server JDBC pools to use the JDBC schema created in Step 1: for Central Users
Restart the Integration Server
4. Configure Business Calendar
a. Acccess IBM webMethods Common Directory Service using following URL with your Integration Server hostname and port http://<IS_HOST_NAME>:<IS_PORT>/WmCDS/#/directory-services
b. Click on Calendars > Business Calendar
c. Click on Create button
d. Enter Unique business calendar name , lookup name then Click +Create button to add Business Days (Monday – Friday) and Holidays.
e. Create Holiday
f. Click Save Button to save the Calendar
5. Download WxCheckHoliday package using following link
https://github.com/prudhvi-penmetsa-saggs/WxCheckHoliday/raw/refs/heads/main/WxCheckHoliday.zip
6. Install WxCheckHoliday package
7. Configure Integration Server Global Variable calendar_name
This variable will be used to lookup the holiday
How to Check Holiday
Service 1: WxCheckHoliday:checkHoliday service checks whether the given date is a company configured holiday in Common Directory Service Business Calendar or not
Input:
date: Enter the date in yyyy-MM-dd format to check whether this date is configured as a holiday in the business calendar.
Output:
isHoliday:
true - if the date is a company holiday
false - if the date is a working day.
Service 2: WxCheckHoliday:isTodayHoliday service checks whether today’s date is a company configured holiday in Common Directory Service Business Calendar
Input:
throwException: This flag can be used to stop schedule jobs running on holidays
true - this will throw a Service Exception if the current date is a holiday.
false - default value. This will return isHoliday=true if the current date is a holiday.
Output:
isHoliday:
true - if the date is a company holiday
false - if the date is a working day.
#Spotlight