Project

General

Profile

Actions

Bug #14487

closed

Task export should include successful tasks as well as the pending or errored one

Added by Bryan Kearney about 8 years ago. Updated over 7 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
-
Target version:
-
Difficulty:
Triaged:
Fixed in Releases:
Found in Releases:

Description

Cloned from https://bugzilla.redhat.com/show_bug.cgi?id=1314207
Description of problem:
Current behavior of foreman-debug, specifically task export might not be sufficient when we are looking for performance issues. I. e. if I can see error message: "[E] Required lock is already taken by other running tasks." and I need to check the actual task which had the locks and this task finished successfully, it will not be included later, when the foreman-debug performs task export script.

Version-Release number of selected component (if applicable):
Satellite 6.X

How reproducible:
Just run foreman-debug and look for successful tasks in the task export

Actual results:
Successful tasks are missing in the task export

Expected results:
Successful task will be included in the task export

Additional info:
Current implementation:

#foreman-tasks export
if hash foreman-rake 2>/dev/null; then
echo "Exporting tasks, this may take a few minutes."
tasks_filename=`foreman-rake foreman_tasks:export_tasks 2> /tmp/tasks_export.log | tail -n 1 | awk '{print $2}'`
copy_files $tasks_filename
add_files /tmp/tasks_export.log
fi

Proposed modification:
#foreman-tasks export
if hash foreman-rake 2>/dev/null; then
echo "Exporting tasks, this may take a few minutes."
tasks_filename=`foreman-rake foreman_tasks:export_tasks tasks=all days=14 2> /tmp/tasks_export.log | tail -n 1 | awk '{print $2}'`
copy_files $tasks_filename
add_files /tmp/tasks_export.log
fi

Because there might be a lot of tasks, I believe it will be good to limit the age of tasks included in the task export. Therefore I'm proposing 14 days as I think it should be more than sufficient.

Actions #1

Updated by Dominic Cleal about 8 years ago

  • Project changed from Foreman to Katello
  • Category deleted (foreman-debug)
Actions #2

Updated by Eric Helms about 8 years ago

  • Project changed from Katello to foreman-tasks
Actions #3

Updated by Ivan Necas almost 8 years ago

  • Assignee changed from Ivan Necas to David Davis
Actions #4

Updated by The Foreman Bot almost 8 years ago

  • Status changed from New to Ready For Testing
  • Pull request https://github.com/theforeman/foreman-tasks/pull/186 added
Actions #5

Updated by Anonymous over 7 years ago

  • Status changed from Ready For Testing to Closed
  • % Done changed from 0 to 100
Actions

Also available in: Atom PDF