SlideShare a Scribd company logo
1 of 15
Download to read offline
Building Human-Friendly Scheduled Tasks
LED BY
Giancarlo Gomez
SESSION
Giancarlo Gomez
SPEAKER AT ITB2023
• Proud father of 3
• Web Developer since 1999
• Freelance since 2001
• Owner of Fuse Developments and CrossTrackr, Inc.
• South Florida ColdFusion User Group Co-Manager
The Pros and Cons - Adobe ColdFusion
Scheduled Tasks on your engine of choice
PROS
• Cool Features ( Enterprise Only )
• mode
Allows to define Application level tasks
• eventHandler
Simple Event Handlers
• action
create and modify options added in 2018.
modify allows to update an existing task while
retaining its old values.
• cronTime
* custom cronTime format
http://www.quartz-scheduler.org/documentation/quartz-2.2.2/tutorials/
tutorial-lesson-06.html
CONS
• The cool features come at a hefty cost $$$
• Although you can track in code
• tasks can be created / edited
* server tasks
• tasks can be removed
* server and application level
The Pros and Cons - Lucee
Scheduled Tasks on your engine of choice
PROS
• unique
Execute task once at a time no overlapping
• Funny behavior ...
Does not add the full interval only the remaining
• readonly
No edit or delete allowed in admin
Nice way to force in code only workflow
• autodelete
Helps with the bad habit of people not being pro
active about code debt clean up and yes tasks that
are no longer needed create code debt to manage
CONS
• None of the features from ACF
• Application level tasks
• Event handlers
• Tasks under 10 second intervals do not fire
• Access to the web admin can be a bit of a pain due
to individual context
Biggest Pain Point ...
Scheduled Tasks on your engine of choice
• If managed in code
Switching an engine will require some refactoring
based on features and attributes
• If not managed in code
Good luck, I just went thru this for a project with
over 150 scheduled tasks split over 2 servers with
absolutely no pattern.
Why ColdBox Scheduled Tasks?
• Code First!!!!
Based on your workflow, this can make it easier to manage, track and understand why a task exists
• A fresh, programmatic and human approach to scheduling tasks
Chainable DSL with a human readable touch
• Complete control over lifecycle
Globally and at the individual task level - better event handlers!
• No issue if switching engines
• Cool features at no cost!!!!
• Limitless opportunities!
Simple Example
New Properties
ColdBox Scheduled Tasks
• New Boolean Properties
• annually - defines that the task was scheduled on a yearly basis
• debugEnabled - defines that the task is in debug mode which streams messages to the console
• firstBusinessDay - defines that the task was scheduled to run on the first business day of the month
• lastBusinessDay - defines that the task was scheduled to run on the last business day of the month
• New Time Restriction Properties
• startTime - limits the task to run from a specific time of day
• endTime - limits the task to run up to a specific time of day
• Information Properties
• delayTimeUnit - tracks the delay time unit regardless of setting in chain so it can be processed on start()
• taskTime - tracks the task time when scheduled on first or last business day of month
New Functions
ColdBox Scheduled Tasks
• debug( true|false )
Set debug mode during setup in chain or on demand. This can also be done within the task() method, which now
supports a second argument for debug mode.
• startOnTime( time )
Sets the startTime constraint
• endOnTime( time )
Sets the endTime constraint
• between( startTime, endTime )
Sets the startTime and endTime constraints in 1 call
Fixes and Improvements
ColdBox Scheduled Tasks
• Fixes
• nextRun is now set in the task's stats struct
• onFirstBusinessDayOfMonth() now sets the first day properly when it requires to resolve to the next month
• onLastBusinessDayOfMonth() now sets the day correctly
• delay()no longer overwrites the timeUnit and it is now checked in the start() method.
* still has some restrictions / limitations
• Improvements
• isConstrained()
• dayOfMonth constraint check updated. If the day the user intended to run is higher than the last day of the current
month then we allow it to run on the last day of the month with support for leap years.
• Added startTime and endTime check constraints
Live Coding Segment ....
ColdBox Scheduled Tasks
https://github.com/ColdBox/Building-Human-Friendly-Scheduled-Tasks
How to get in touch with me ...
! https://giancarlogomez.dev
" giancarlo.gomez@gmail.com
! @GiancarloGomez
" https://github.com/GiancarloGomez
# https://www.linkedin.com/in/giancarlogomez
How did I do?
THANK YOU
Thanks to our sponsors

More Related Content

Similar to ITB_2023_Human-Friendly_Scheduled_Tasks_Giancarlo_Gomez.pdf

LandsEnd TechEd2016 (1)
LandsEnd TechEd2016 (1)LandsEnd TechEd2016 (1)
LandsEnd TechEd2016 (1)
Lisa Lawver
 
Anna Fedoruk.Theworkflow.DrupalCamp Kyiv 2011
Anna Fedoruk.Theworkflow.DrupalCamp Kyiv 2011Anna Fedoruk.Theworkflow.DrupalCamp Kyiv 2011
Anna Fedoruk.Theworkflow.DrupalCamp Kyiv 2011
camp_drupal_ua
 
PeopleSoft Upgrades: Best Practices
PeopleSoft Upgrades: Best PracticesPeopleSoft Upgrades: Best Practices
PeopleSoft Upgrades: Best Practices
Emtec Inc.
 

Similar to ITB_2023_Human-Friendly_Scheduled_Tasks_Giancarlo_Gomez.pdf (20)

Era of server less computing
Era of server less computingEra of server less computing
Era of server less computing
 
Single Page Applications with AngularJS 2.0
Single Page Applications with AngularJS 2.0 Single Page Applications with AngularJS 2.0
Single Page Applications with AngularJS 2.0
 
Closing Cockpit Ver6
Closing Cockpit Ver6Closing Cockpit Ver6
Closing Cockpit Ver6
 
Pragmatic Monolith-First, easy to decompose, clean architecture
Pragmatic Monolith-First, easy to decompose, clean architecturePragmatic Monolith-First, easy to decompose, clean architecture
Pragmatic Monolith-First, easy to decompose, clean architecture
 
Task management System (TMS)
Task management System (TMS)Task management System (TMS)
Task management System (TMS)
 
Task Management System (TMS)
Task Management System (TMS)Task Management System (TMS)
Task Management System (TMS)
 
Benchmarking at Parse
Benchmarking at ParseBenchmarking at Parse
Benchmarking at Parse
 
Advanced Benchmarking at Parse
Advanced Benchmarking at ParseAdvanced Benchmarking at Parse
Advanced Benchmarking at Parse
 
System overview
System overviewSystem overview
System overview
 
Technical Modifications to Compress Period End Close - R12.1.3
Technical Modifications to Compress Period End Close - R12.1.3Technical Modifications to Compress Period End Close - R12.1.3
Technical Modifications to Compress Period End Close - R12.1.3
 
#SpFestSea azr203 Azure functions lessons learned
#SpFestSea azr203 Azure functions lessons learned#SpFestSea azr203 Azure functions lessons learned
#SpFestSea azr203 Azure functions lessons learned
 
What is this agile thing anyway
What is this agile thing anywayWhat is this agile thing anyway
What is this agile thing anyway
 
LandsEnd TechEd2016 (1)
LandsEnd TechEd2016 (1)LandsEnd TechEd2016 (1)
LandsEnd TechEd2016 (1)
 
Background Processing With Work Manager
Background Processing With Work ManagerBackground Processing With Work Manager
Background Processing With Work Manager
 
Anna Fedoruk.Theworkflow.DrupalCamp Kyiv 2011
Anna Fedoruk.Theworkflow.DrupalCamp Kyiv 2011Anna Fedoruk.Theworkflow.DrupalCamp Kyiv 2011
Anna Fedoruk.Theworkflow.DrupalCamp Kyiv 2011
 
Azure Functions in Action #OrlandoCC
Azure Functions in Action #OrlandoCCAzure Functions in Action #OrlandoCC
Azure Functions in Action #OrlandoCC
 
Serverless Computing Model
Serverless Computing ModelServerless Computing Model
Serverless Computing Model
 
module1.pptx
module1.pptxmodule1.pptx
module1.pptx
 
Play with azure functions
Play with azure functionsPlay with azure functions
Play with azure functions
 
PeopleSoft Upgrades: Best Practices
PeopleSoft Upgrades: Best PracticesPeopleSoft Upgrades: Best Practices
PeopleSoft Upgrades: Best Practices
 

More from Ortus Solutions, Corp

More from Ortus Solutions, Corp (20)

ITB2024 - Keynote Day 1 - Ortus Solutions.pdf
ITB2024 - Keynote Day 1 - Ortus Solutions.pdfITB2024 - Keynote Day 1 - Ortus Solutions.pdf
ITB2024 - Keynote Day 1 - Ortus Solutions.pdf
 
BATTLEFIELD ORM: TIPS, TACTICS AND STRATEGIES FOR CONQUERING YOUR DATABASE
BATTLEFIELD ORM: TIPS, TACTICS AND STRATEGIES FOR CONQUERING YOUR DATABASEBATTLEFIELD ORM: TIPS, TACTICS AND STRATEGIES FOR CONQUERING YOUR DATABASE
BATTLEFIELD ORM: TIPS, TACTICS AND STRATEGIES FOR CONQUERING YOUR DATABASE
 
Ortus Government.pdf
Ortus Government.pdfOrtus Government.pdf
Ortus Government.pdf
 
Luis Majano The Battlefield ORM
Luis Majano The Battlefield ORMLuis Majano The Battlefield ORM
Luis Majano The Battlefield ORM
 
Brad Wood - CommandBox CLI
Brad Wood - CommandBox CLI Brad Wood - CommandBox CLI
Brad Wood - CommandBox CLI
 
Secure your Secrets and Settings in ColdFusion
Secure your Secrets and Settings in ColdFusionSecure your Secrets and Settings in ColdFusion
Secure your Secrets and Settings in ColdFusion
 
Daniel Garcia ContentBox: CFSummit 2023
Daniel Garcia ContentBox: CFSummit 2023Daniel Garcia ContentBox: CFSummit 2023
Daniel Garcia ContentBox: CFSummit 2023
 
ITB_2023_CommandBox_Multi-Server_-_Brad_Wood.pdf
ITB_2023_CommandBox_Multi-Server_-_Brad_Wood.pdfITB_2023_CommandBox_Multi-Server_-_Brad_Wood.pdf
ITB_2023_CommandBox_Multi-Server_-_Brad_Wood.pdf
 
ITB_2023_The_Many_Layers_of_OAuth_Keith_Casey_.pdf
ITB_2023_The_Many_Layers_of_OAuth_Keith_Casey_.pdfITB_2023_The_Many_Layers_of_OAuth_Keith_Casey_.pdf
ITB_2023_The_Many_Layers_of_OAuth_Keith_Casey_.pdf
 
ITB_2023_Relationships_are_Hard_Data_modeling_with_NoSQL_Curt_Gratz.pdf
ITB_2023_Relationships_are_Hard_Data_modeling_with_NoSQL_Curt_Gratz.pdfITB_2023_Relationships_are_Hard_Data_modeling_with_NoSQL_Curt_Gratz.pdf
ITB_2023_Relationships_are_Hard_Data_modeling_with_NoSQL_Curt_Gratz.pdf
 
ITB_2023_Extend_your_contentbox_apps_with_custom_modules_Javier_Quintero.pdf
ITB_2023_Extend_your_contentbox_apps_with_custom_modules_Javier_Quintero.pdfITB_2023_Extend_your_contentbox_apps_with_custom_modules_Javier_Quintero.pdf
ITB_2023_Extend_your_contentbox_apps_with_custom_modules_Javier_Quintero.pdf
 
ITB_2023_25_Most_Dangerous_Software_Weaknesses_Pete_Freitag.pdf
ITB_2023_25_Most_Dangerous_Software_Weaknesses_Pete_Freitag.pdfITB_2023_25_Most_Dangerous_Software_Weaknesses_Pete_Freitag.pdf
ITB_2023_25_Most_Dangerous_Software_Weaknesses_Pete_Freitag.pdf
 
ITB_2023_CBWire_v3_Grant_Copley.pdf
ITB_2023_CBWire_v3_Grant_Copley.pdfITB_2023_CBWire_v3_Grant_Copley.pdf
ITB_2023_CBWire_v3_Grant_Copley.pdf
 
ITB_2023_Practical_AI_with_OpenAI_-_Grant_Copley_.pdf
ITB_2023_Practical_AI_with_OpenAI_-_Grant_Copley_.pdfITB_2023_Practical_AI_with_OpenAI_-_Grant_Copley_.pdf
ITB_2023_Practical_AI_with_OpenAI_-_Grant_Copley_.pdf
 
ITB_2023_When_Your_Applications_Work_As_a_Team_Nathaniel_Francis.pdf
ITB_2023_When_Your_Applications_Work_As_a_Team_Nathaniel_Francis.pdfITB_2023_When_Your_Applications_Work_As_a_Team_Nathaniel_Francis.pdf
ITB_2023_When_Your_Applications_Work_As_a_Team_Nathaniel_Francis.pdf
 
ITB_2023_Faster_Apps_That_Wont_Get_Crushed_Brian_Klaas.pdf
ITB_2023_Faster_Apps_That_Wont_Get_Crushed_Brian_Klaas.pdfITB_2023_Faster_Apps_That_Wont_Get_Crushed_Brian_Klaas.pdf
ITB_2023_Faster_Apps_That_Wont_Get_Crushed_Brian_Klaas.pdf
 
ITB_2023_Chatgpt_Box_Scott_Steinbeck.pdf
ITB_2023_Chatgpt_Box_Scott_Steinbeck.pdfITB_2023_Chatgpt_Box_Scott_Steinbeck.pdf
ITB_2023_Chatgpt_Box_Scott_Steinbeck.pdf
 
ITB_2023_CommandBox_Task_Runners_Brad_Wood.pdf
ITB_2023_CommandBox_Task_Runners_Brad_Wood.pdfITB_2023_CommandBox_Task_Runners_Brad_Wood.pdf
ITB_2023_CommandBox_Task_Runners_Brad_Wood.pdf
 
ITB_2023_Create_as_many_web_sites_or_web_apps_as_you_want_George_Murphy.pdf
ITB_2023_Create_as_many_web_sites_or_web_apps_as_you_want_George_Murphy.pdfITB_2023_Create_as_many_web_sites_or_web_apps_as_you_want_George_Murphy.pdf
ITB_2023_Create_as_many_web_sites_or_web_apps_as_you_want_George_Murphy.pdf
 
ITB2023 Developing for Performance - Denard Springle.pdf
ITB2023 Developing for Performance - Denard Springle.pdfITB2023 Developing for Performance - Denard Springle.pdf
ITB2023 Developing for Performance - Denard Springle.pdf
 

Recently uploaded

Jax, FL Admin Community Group 05.14.2024 Combined Deck
Jax, FL Admin Community Group 05.14.2024 Combined DeckJax, FL Admin Community Group 05.14.2024 Combined Deck
Jax, FL Admin Community Group 05.14.2024 Combined Deck
Marc Lester
 

Recently uploaded (20)

Reinforcement Learning – a Rewards Based Approach to Machine Learning - Marko...
Reinforcement Learning – a Rewards Based Approach to Machine Learning - Marko...Reinforcement Learning – a Rewards Based Approach to Machine Learning - Marko...
Reinforcement Learning – a Rewards Based Approach to Machine Learning - Marko...
 
Malaysia E-Invoice digital signature docpptx
Malaysia E-Invoice digital signature docpptxMalaysia E-Invoice digital signature docpptx
Malaysia E-Invoice digital signature docpptx
 
Implementing KPIs and Right Metrics for Agile Delivery Teams.pdf
Implementing KPIs and Right Metrics for Agile Delivery Teams.pdfImplementing KPIs and Right Metrics for Agile Delivery Teams.pdf
Implementing KPIs and Right Metrics for Agile Delivery Teams.pdf
 
Weeding your micro service landscape.pdf
Weeding your micro service landscape.pdfWeeding your micro service landscape.pdf
Weeding your micro service landscape.pdf
 
Optimizing Operations by Aligning Resources with Strategic Objectives Using O...
Optimizing Operations by Aligning Resources with Strategic Objectives Using O...Optimizing Operations by Aligning Resources with Strategic Objectives Using O...
Optimizing Operations by Aligning Resources with Strategic Objectives Using O...
 
OpenChain @ LF Japan Executive Briefing - May 2024
OpenChain @ LF Japan Executive Briefing - May 2024OpenChain @ LF Japan Executive Briefing - May 2024
OpenChain @ LF Japan Executive Briefing - May 2024
 
The Impact of PLM Software on Fashion Production
The Impact of PLM Software on Fashion ProductionThe Impact of PLM Software on Fashion Production
The Impact of PLM Software on Fashion Production
 
Automate your OpenSIPS config tests - OpenSIPS Summit 2024
Automate your OpenSIPS config tests - OpenSIPS Summit 2024Automate your OpenSIPS config tests - OpenSIPS Summit 2024
Automate your OpenSIPS config tests - OpenSIPS Summit 2024
 
Secure Software Ecosystem Teqnation 2024
Secure Software Ecosystem Teqnation 2024Secure Software Ecosystem Teqnation 2024
Secure Software Ecosystem Teqnation 2024
 
Jax, FL Admin Community Group 05.14.2024 Combined Deck
Jax, FL Admin Community Group 05.14.2024 Combined DeckJax, FL Admin Community Group 05.14.2024 Combined Deck
Jax, FL Admin Community Group 05.14.2024 Combined Deck
 
KLARNA - Language Models and Knowledge Graphs: A Systems Approach
KLARNA -  Language Models and Knowledge Graphs: A Systems ApproachKLARNA -  Language Models and Knowledge Graphs: A Systems Approach
KLARNA - Language Models and Knowledge Graphs: A Systems Approach
 
Entropy, Software Quality, and Innovation (presented at Princeton Plasma Phys...
Entropy, Software Quality, and Innovation (presented at Princeton Plasma Phys...Entropy, Software Quality, and Innovation (presented at Princeton Plasma Phys...
Entropy, Software Quality, and Innovation (presented at Princeton Plasma Phys...
 
INGKA DIGITAL: Linked Metadata by Design
INGKA DIGITAL: Linked Metadata by DesignINGKA DIGITAL: Linked Metadata by Design
INGKA DIGITAL: Linked Metadata by Design
 
COMPUTER AND ITS COMPONENTS PPT.by naitik sharma Class 9th A mittal internati...
COMPUTER AND ITS COMPONENTS PPT.by naitik sharma Class 9th A mittal internati...COMPUTER AND ITS COMPONENTS PPT.by naitik sharma Class 9th A mittal internati...
COMPUTER AND ITS COMPONENTS PPT.by naitik sharma Class 9th A mittal internati...
 
Wired_2.0_CREATE YOUR ULTIMATE LEARNING ENVIRONMENT_JCON_16052024
Wired_2.0_CREATE YOUR ULTIMATE LEARNING ENVIRONMENT_JCON_16052024Wired_2.0_CREATE YOUR ULTIMATE LEARNING ENVIRONMENT_JCON_16052024
Wired_2.0_CREATE YOUR ULTIMATE LEARNING ENVIRONMENT_JCON_16052024
 
What is an API Development- Definition, Types, Specifications, Documentation.pdf
What is an API Development- Definition, Types, Specifications, Documentation.pdfWhat is an API Development- Definition, Types, Specifications, Documentation.pdf
What is an API Development- Definition, Types, Specifications, Documentation.pdf
 
The Strategic Impact of Buying vs Building in Test Automation
The Strategic Impact of Buying vs Building in Test AutomationThe Strategic Impact of Buying vs Building in Test Automation
The Strategic Impact of Buying vs Building in Test Automation
 
Lessons Learned from Building a Serverless Notifications System.pdf
Lessons Learned from Building a Serverless Notifications System.pdfLessons Learned from Building a Serverless Notifications System.pdf
Lessons Learned from Building a Serverless Notifications System.pdf
 
Crafting the Perfect Measurement Sheet with PLM Integration
Crafting the Perfect Measurement Sheet with PLM IntegrationCrafting the Perfect Measurement Sheet with PLM Integration
Crafting the Perfect Measurement Sheet with PLM Integration
 
Workshop: Enabling GenAI Breakthroughs with Knowledge Graphs - GraphSummit Milan
Workshop: Enabling GenAI Breakthroughs with Knowledge Graphs - GraphSummit MilanWorkshop: Enabling GenAI Breakthroughs with Knowledge Graphs - GraphSummit Milan
Workshop: Enabling GenAI Breakthroughs with Knowledge Graphs - GraphSummit Milan
 

ITB_2023_Human-Friendly_Scheduled_Tasks_Giancarlo_Gomez.pdf

  • 1. Building Human-Friendly Scheduled Tasks LED BY Giancarlo Gomez SESSION
  • 2. Giancarlo Gomez SPEAKER AT ITB2023 • Proud father of 3 • Web Developer since 1999 • Freelance since 2001 • Owner of Fuse Developments and CrossTrackr, Inc. • South Florida ColdFusion User Group Co-Manager
  • 3.
  • 4. The Pros and Cons - Adobe ColdFusion Scheduled Tasks on your engine of choice PROS • Cool Features ( Enterprise Only ) • mode Allows to define Application level tasks • eventHandler Simple Event Handlers • action create and modify options added in 2018. modify allows to update an existing task while retaining its old values. • cronTime * custom cronTime format http://www.quartz-scheduler.org/documentation/quartz-2.2.2/tutorials/ tutorial-lesson-06.html CONS • The cool features come at a hefty cost $$$ • Although you can track in code • tasks can be created / edited * server tasks • tasks can be removed * server and application level
  • 5. The Pros and Cons - Lucee Scheduled Tasks on your engine of choice PROS • unique Execute task once at a time no overlapping • Funny behavior ... Does not add the full interval only the remaining • readonly No edit or delete allowed in admin Nice way to force in code only workflow • autodelete Helps with the bad habit of people not being pro active about code debt clean up and yes tasks that are no longer needed create code debt to manage CONS • None of the features from ACF • Application level tasks • Event handlers • Tasks under 10 second intervals do not fire • Access to the web admin can be a bit of a pain due to individual context
  • 6. Biggest Pain Point ... Scheduled Tasks on your engine of choice • If managed in code Switching an engine will require some refactoring based on features and attributes • If not managed in code Good luck, I just went thru this for a project with over 150 scheduled tasks split over 2 servers with absolutely no pattern.
  • 7. Why ColdBox Scheduled Tasks? • Code First!!!! Based on your workflow, this can make it easier to manage, track and understand why a task exists • A fresh, programmatic and human approach to scheduling tasks Chainable DSL with a human readable touch • Complete control over lifecycle Globally and at the individual task level - better event handlers! • No issue if switching engines • Cool features at no cost!!!! • Limitless opportunities!
  • 9. New Properties ColdBox Scheduled Tasks • New Boolean Properties • annually - defines that the task was scheduled on a yearly basis • debugEnabled - defines that the task is in debug mode which streams messages to the console • firstBusinessDay - defines that the task was scheduled to run on the first business day of the month • lastBusinessDay - defines that the task was scheduled to run on the last business day of the month • New Time Restriction Properties • startTime - limits the task to run from a specific time of day • endTime - limits the task to run up to a specific time of day • Information Properties • delayTimeUnit - tracks the delay time unit regardless of setting in chain so it can be processed on start() • taskTime - tracks the task time when scheduled on first or last business day of month
  • 10. New Functions ColdBox Scheduled Tasks • debug( true|false ) Set debug mode during setup in chain or on demand. This can also be done within the task() method, which now supports a second argument for debug mode. • startOnTime( time ) Sets the startTime constraint • endOnTime( time ) Sets the endTime constraint • between( startTime, endTime ) Sets the startTime and endTime constraints in 1 call
  • 11. Fixes and Improvements ColdBox Scheduled Tasks • Fixes • nextRun is now set in the task's stats struct • onFirstBusinessDayOfMonth() now sets the first day properly when it requires to resolve to the next month • onLastBusinessDayOfMonth() now sets the day correctly • delay()no longer overwrites the timeUnit and it is now checked in the start() method. * still has some restrictions / limitations • Improvements • isConstrained() • dayOfMonth constraint check updated. If the day the user intended to run is higher than the last day of the current month then we allow it to run on the last day of the month with support for leap years. • Added startTime and endTime check constraints
  • 12. Live Coding Segment .... ColdBox Scheduled Tasks https://github.com/ColdBox/Building-Human-Friendly-Scheduled-Tasks
  • 13. How to get in touch with me ... ! https://giancarlogomez.dev " giancarlo.gomez@gmail.com ! @GiancarloGomez " https://github.com/GiancarloGomez # https://www.linkedin.com/in/giancarlogomez
  • 14. How did I do?
  • 15. THANK YOU Thanks to our sponsors