Skip to main content
Announcements
New: No-code data prep in Qlik Cloud Analytics™ TAKE A TOUR
cancel
Showing results for 
Search instead for 
Did you mean: 
akinert
Contributor
Contributor

Project: Python, QRS API: Creating Task Schedule, Gantt Chart and Overlapping Task Analysis

Hello everyone,

I’m excited to share a Python tool I’ve developed that connects with the Qlik Sense QRS API to visualize task management and identify time intervals where more than six apps (the maximum number of reload tasks that can work simultaneously) reload concurrently on QMC.

Unlike monitoring apps that rely on executed reload task logs, this tool bases the schedule on the defined trigger start time and reload task duration. This approach assumes that no task will be queued, even if it exceeds the limit, allowing us to inspect possible queues according to the defined triggers.

Key Features:

  • Gantt Chart Visualization: A Gantt chart is generated to visualize the reload process and display overlapping tasks.
  • Interval Analysis: The tool inspects time intervals where more than 6 reloads occur simultaneously, reporting the time and overlapping reload tasks with their count.

gantt_chart.jpg

 I attached an excel file gantt chart visual as an example of output of the project. Excel file includes a task schedule(sheet1) ,measured start and finish time(sheet2) and overlapping task intervals(sheet3).


Check out the project here: github.com/akinertu/qliksense 

 

Project Steps:

     0. Connecting Qlik Sense QRS API

  • Requirements:
    • Qlik Sense UserID
    • Qlik Sense User Directory
    • Qlik sense Server Adress
    • Certificates: client.pem, client_key.pem (Can be exported from QMC)
  1. Retrive Qlik Sense App properties
    • 'id', 'name', 'published', 'description', 'stream', 'fileSize', 'lastReloadDate', 'lastReloadTime', 'owner'
  2. Retrive Qlik Sense Task properties
    • 'id', 'name', 'enabled', 'nextExecutionDate', 'duration', 'app_id'
  3. Retrive Qlik Sense Reload Task Trigger properties
    • 'id', 'schemaFilterDescription', 'incrementDescription', 'enabled', 'reloadTask_id', 'startDate'
    • 'id', 'reloadTask_id', 'enabled', 'preceeding_reloadTask_id'
    • decoding 'schemaFilterDescription' &  'incrementDescription' into trigger period/time info
  4. Creating Task Schedule
    • Merging app, task and trigger into a dataframe
  5. Filtering Enabled Tasks & Published Apps (Optional)
    • To use only enabled task/trigger of published apps
  6. Getting/Measuring start and finish time of reload tasks
    • For tasks with periodic triggers:
      • start time = trigger time
      • finish time = start time + reload time duration
    • For tasks with task triggers(dependent)
      • start time = preceeding reload task finish time
      • finish time = start time + reload time duration
  7. Creating a Gantt Chart for reloadtasks
  8. Analysing task overlaps

This tool is designed to enhance efficiency and ensure optimal scheduling within Qlik Sense environments. I’m thrilled to contribute to the Qlik community and would love to hear your feedback or suggestions!

 

Labels (3)
1 Solution

Accepted Solutions
KadenceRowland
Contributor
Contributor

This Python tool sounds super helpful in managing task schedules with Qlik Sense! Visualizing overlapping reloads and identifying when more than six tasks run concurrently is a great way to avoid potential bottlenecks. Basing it on trigger start times and task duration instead of just logs seems like a more innovative way to predict and prevent queuing.

View solution in original post

1 Reply
KadenceRowland
Contributor
Contributor

This Python tool sounds super helpful in managing task schedules with Qlik Sense! Visualizing overlapping reloads and identifying when more than six tasks run concurrently is a great way to avoid potential bottlenecks. Basing it on trigger start times and task duration instead of just logs seems like a more innovative way to predict and prevent queuing.