Skip to main content

I find that workflows become incomprehensible due to the logging of “starts” and “loops” when in reality the changes in phase don’t capture useful information.

Is there a way to manually add and update phases in the workflow?

 

Thanks.

Chris.

Adding @Chris Sunderland as a precaution :-)

What exactly do you want to alter?  How they are stopped and started, the names, etc.?

Describe your optimal goal and we’ll see what can be done :nerd:


You can add your own logging to workflows within any script (i.e. Script activity, OnStart, OnComplete, etc) with the syntax

logger.info(“information to log”);

This will be logged in both the WorkflowEngine.log and WorkflowCustom.log.  The WorkflowCustom.log will only show you custom logging that you’ve added to any workflow.

So if the WorkflowEngine.log is to cumbersome to read, you can implement your own logging and view them in the WorkflowCustom.log.

If you have a workflow that requires a lot of custom logging and you want to log it to a separate file all together, you can use this logging syntax

logger.path(“c:/path/to/file.log”).info(“information to log”);

 


Thank you Chris. 

This is in fact useful, but what I was looking for it more along the lines of what shows up in the GUI when phases change.

This is meant for the end users running the workflows to be able see what it happening.

For example to be able to inform the user that “Client X is currently being added to Storage Policy Y” 

“Client X has succeeded in being added to Storage Policy Y”. 

 

thanks. 

Chris.


Basically I want someone to be able to know what is currently happening in the workflow by looking at the controller. The workflows are essentially being written for the benefit of people who do not write them and are not necessarily interested in looking at logs.


The phases in the job controller is just the activity name that was executed.  You can set the display name of the activity to something helpful that a user can understand.  For activities that don’t have any meaning and don’t need to show, you can set the skip creating attempt to true in the General tab.  This will keep this activity from showing up in the phases.

 


The phases in the job controller is just the activity name that was executed.  You can set the display name of the activity to something helpful that a user can understand.  For activities that don’t have any meaning and don’t need to show, you can set the skip creating attempt to true in the General tab.  This will keep this activity from showing up in the phases.

 

That is exactly what I needed to know. Thank you.


One more question can the name of the activity be changed dynamically so that it shows up in the phase? So for example an activity with the name “add client” could be updated to include the client name? 


Display names of activities allow for variables inside the name.  So you can set the display name of the activity to something like

Add client xpath:{/workflow/inputs/client}

 

 


That is pretty sweet. 
Thanks again.


Unrelated @Chris Sunderland but doing that makes the display name look absolutely horrifying, is it fair guess that it can’t be changed at runtime?