Home Powershell Activity
Options

Issues setting an activity to ReRun inside a Cireson PowerShell Activity

Ryan_KennedyRyan_Kennedy Customer IT Monkey ✭
Hello,

I am having issues setting a previous activity back to ReRun within a Cireson PowerShell Activity.
The workflow I have looks something like this:

CiresonPSAct1
MA1
CiresonPSAct2
MA2

In the CiresonPSAct2 I am setting MA1 to rerun.
This does happen - MA1 goes to ReRun / In Progress and CiresonPSAct2 goes to Pending.
BUT MA2 also goes to In Progress.. So Once the ReRun on MA1 is Complete, CiresonPSAct2 never becomes In Progress..
I have tried to set MA2 to Pending within CiresonPSAct2 but it only goes to In Progress once the activity completes...

I have previously done this running a powershell script from a runbook and never had any issues but it just doesn't seem to work with the Cireson PowerShell Activities ...
Has anyone had an issue like this before?


I basically just get the class instance of the activity and run :
$MA1 | %{$_.Status= "ActivityStatusEnum.Rerun";$_} | Update-SCClassInstance

Have also tried getting the activity object and using
$MA1 | set-scsmobject -property Status -value "ActivityStatusEnum.Rerun"


Thanks for any help you can give,

Ryan

Answers

  • Options
    Justin_WorkmanJustin_Workman Cireson Support Super IT Monkey ✭✭✭✭✭
    Hey Ryan,
    I'm glad to see someone using PS Activities.  I think they're a little unsung.  I'm experimenting with this in my lab now.  I'll get back with you on this shortly... :)
  • Options
    Ryan_KennedyRyan_Kennedy Customer IT Monkey ✭
    Did you end up testing this @Justin_Workman? Has anyone else had this issue?
  • Options
    Adam_DzyackyAdam_Dzyacky Product Owner Contributor Monkey ✭✭✭✭✭
    I can second this as I was recently experimenting with these. A rerun or an invocation/on-demand execution provides no actual re-run of the Cireson P$A. But rerunning runbooks (SCO or SMA) works as you cite works without issue.

  • Options
    Ryan_Kennedy1Ryan_Kennedy1 Customer IT Monkey ✭
    It also seems that if you have a Sequential Activity with a PowerShell Activity followed by a MA inside of it, if you skip the MA in the PowerShell Activity , once the PowerShell Activity completes, the MA changes state from Skipped to In Progress ..... I think this was working okay without the Sequential Activity but definitely not working with it... If I Skip the MA , put a sleep of 5 minutes in, then the PowerShell Activity completes, it still puts the MA In Progress ..
  • Options
    Ryan_Kennedy1Ryan_Kennedy1 Customer IT Monkey ✭
    Has anyone else had this issue / does anyone know a way around this?
  • Options
    Justin_WorkmanJustin_Workman Cireson Support Super IT Monkey ✭✭✭✭✭
    @Ryan_Kennedy1 - I still want to look at this.  I just haven't got around to it...I'm sorry :frowning:

Sign In or Register to comment.