Workspace 6.21.5
Public Slots | Signals | Public Member Functions | Protected Member Functions | List of all members
ProcessWorkflows Class Reference

#include <Tools/WorkflowValidation/BatchApplication/processworkflows.h>

Inherits QObject.

Public Slots

void onWorkflowFinished (const QString &workflow)
 
void onWorkflowTimeout ()
 

Signals

void finished ()
 
void workflowFinished (const QString &fileName)
 

Public Member Functions

 ProcessWorkflows (QStack< QString > fileStack, QList< LogWorkflow * > &runningLog, bool runWorkflows, bool staticAnalyze, QStringList dependencyComponents, bool analyzeStructure, bool resaveWorkflows, int timeoutInterval, bool autoAddConfigEntries, bool showRepeatedEntries, bool loggingToFile)
 
DataExecution::SerializedItem getConfigItem (const QString &workflow)
 
void processWorkflow (const QString &workflow)
 
QString resultsInBrief ()
 
void start ()
 
int summariseDeprecationWarnings (bool logZeroCount=false)
 
int summariseErrors (bool logZeroCount=false)
 
int summariseTimeouts ()
 
int summariseWarnings (bool logZeroCount=false)
 

Protected Member Functions

bool addWorkflowEntry (const QString &workflow, DataExecution::SerializedItem &top) const
 
void analyseWorkflowStructure (const QString &filename)
 
QList< QPair< QString, QString > > find_audited_images (const DataExecution::SerializedItem &workflowItem) const
 
QStringList find_audited_logs (const DataExecution::SerializedItem &workflowItem) const
 
QStringList find_required_plugins (const DataExecution::SerializedItem &workflowItem) const
 
void logMessageCount (uint count, QMap< QString, uint > map, const QString &tag, bool logZeroCount=false) const
 
void staticAnalyzeWorkflow (const QString &filename)
 

Constructor & Destructor Documentation

◆ ProcessWorkflows()

ProcessWorkflows ( QStack< QString >  fileStack,
QList< LogWorkflow * > &  runningLog,
bool  runWorkflows,
bool  staticAnalyze,
QStringList  dependencyComponents,
bool  analyzeStructure,
bool  resaveWorkflows,
int  timeOut,
bool  autoAddConfigEntries,
bool  showRepeatedEntries,
bool  loggingToFile 
)
Parameters
fileStackQStack of workflow files to analyze.
runningLogList of LogWorkflow items (one will be created per workflow loaded)
runWorkflowsTrue if the workflows should be run after loading
staticAnalyzeTrue if the workflows should be statically analyzed after loading
dependencyComponentsDat for statically analyzing workflows
analyzeStructureGenerate the analyse workflow report
resaveWorkflowsTrue if the workflows should be resaved after loading
timeOutTimeout interval in ms (per workflow run, ignored if the workflows are only loaded)
autoAddConfigEntriesTrue if allowed to creates an entry if it does not exist
showRepeatedEntriesTrue if repeated log messages from a given workflow should all be shown
loggingToFileTrue if the output is being redirected to a file

Member Function Documentation

◆ addWorkflowEntry()

bool addWorkflowEntry ( const QString &  workflow,
DataExecution::SerializedItem top 
) const
protected

◆ analyseWorkflowStructure()

void analyseWorkflowStructure ( const QString &  filename)
protected

◆ find_audited_images()

QList< QPair< QString, QString > > find_audited_images ( const DataExecution::SerializedItem workflowItem) const
protected

Finds the list of images that should be generated by the given workflow, as given by the workflow-analyse.config file These should be set up inside "image" child elements of the "audited_images" element of the workflow item

◆ find_audited_logs()

QStringList find_audited_logs ( const DataExecution::SerializedItem workflowItem) const
protected

Finds the list of log strings that should be generated by the given workflow, as given by the workflow-analyse.config file These should be set up as text inside "log" child elements of the "audited_log" element of the workflow item

◆ find_required_plugins()

QStringList find_required_plugins ( const DataExecution::SerializedItem workflowItem) const
protected

A list of required plugins can be set in the config file, if any of these are absent the system does not try to load or run the workflow

◆ finished

void finished ( )
signal

◆ getConfigItem()

DataExecution::SerializedItem getConfigItem ( const QString &  workflow)

Finds the Serialized item matching the given workflow inside the local workflow-analyse.config file

Creates an entry if it does not exist, creates a config file if it does not exist (subject to write permissions...)

◆ logMessageCount()

void logMessageCount ( uint  count,
QMap< QString, uint >  map,
const QString &  tag,
bool  logZeroCount = false 
) const
protected

Logs a summary of the messages generated by the workflow stack, only logs those workflows that generated messages

◆ onWorkflowFinished

void onWorkflowFinished ( const QString &  workflow)
slot

◆ onWorkflowTimeout

void onWorkflowTimeout ( )
slot

◆ processWorkflow()

void processWorkflow ( const QString &  workflow)

◆ resultsInBrief()

QString resultsInBrief ( )

Returns a one-line result summary

◆ start()

void start ( )

Start processing the stack of workflows

◆ staticAnalyzeWorkflow()

void staticAnalyzeWorkflow ( const QString &  filename)
protected

Run static analyze on the specified workspace file, print out information.

◆ summariseDeprecationWarnings()

int summariseDeprecationWarnings ( bool  logZeroCount = false)

Logs a summary of the warnings generated by the workflow stack, only logs those workflows that generated warnings

Parameters
logZeroCountLog a result of zero
Returns
The total number of unexpected deprecated operation warnings

◆ summariseErrors()

int summariseErrors ( bool  logZeroCount = false)

Logs a summary of the errors generated by the workflow stack, only logs those workflows that generated errors

Parameters
logZeroCountLog a result of zero
Returns
The total number of unexpected errors generated

◆ summariseTimeouts()

int summariseTimeouts ( )

Logs a summary of the workflows that were aborted due to running for longer than the timeout interval

Returns
The total number of workflows which timed out

◆ summariseWarnings()

int summariseWarnings ( bool  logZeroCount = false)

Logs a summary of the warnings generated by the workflow stack, only logs those workflows that generated warnings

Parameters
logZeroCountLog a result of zero
Returns
The total number of unexpected general warnings

◆ workflowFinished

void workflowFinished ( const QString &  fileName)
signal