The OneStream Community is temporarily frozen until June 29th due to the ongoing maintenance. Please read the blog post here to learn more.
Forum Discussion
photon
9 months agoContributor
Process Cube automation
We have a business rule that, after loading data, runs a Process Cube.
When using this with the batch harvest API, it behaves pretty much as expected in that, after the process is complete, it retu...
ckattookaran
9 months agoValued Contributor
All those process return a task activity item which you can check for status. I would do it as a for loop to wait till the status becomes successful after the calc execution.
photon
9 months agoContributor
There we go. Process: Complete. Calc: still running.
The BR only seems to be able to report on the on Process itself and I can't find a way to access the details/status of the child calc.
- ckattookaran9 months agoValued Contributor
Aha, so you are using a no calculate and running a dm job from it. I'm don't know whether there is a process which can get the status of an already running task that was not initiated within the rule. Not in front of a system to check for this. But your best bet is going to be that, look for a method that can give you the status of a running DM job and then wait for that one, or you might have to tweak the event handler to do it as an execute dm instead of start dm.
- photon9 months agoContributor
I think the "correct" approach here is to move the calc from the DM step to an actual calc defined within the WF, if I can actually get it to do what I need.
Of all the weird things I've done in OS over the years, it's probably bizarre that I have literally never used this screen before.The DM calc is just a consolidation of the full year but it appears the time for a WF calc is always just the period. This may be why they used the DM calc instead. Is there a way to have it consolidate the WF year instead of the period?
- RobbSalzmann9 months agoValued Contributor II
Specifically, what object.method are you calling that returns a status of "Success"?
Here is code I use to get the ProcessCubeProcessInfo result of WorkFlowDataQuality.ExecuteProcessCube. Unfortunately AFAIK there is no handle to the actual process, and therefore no way to monitor it's progress. As you can see here, the method to launch the process simply fires it off and waits for a ProcessCubeProcessInfo result, then based on the value of ProcessCubeProcessInfo.Status, returns a bool.
What it sounds like you're saying is WorkflowDataQuality.ExecuteProcessCube returns immediately after being called?
result in the code below is a ProcessCubeProcessInfo object. Among other things, it should contain a List(of DataUnitInfo), process start, end, and duration times, status, and error messages.
I'm not handling any of that info, other than to validate status completed. Are you saying the status is returned before the calc finishes?public bool Execute(WorkflowExecutionContext context) { var result = WorkflowDataQuality.ExecuteProcessCube(si, context.ClusterPk, context.StepType, false); if (result.Status != WorkflowStatusTypes.Completed) { throw new WorkflowStepException(string.Format( context.BaseMessage, context.WorkflowInfo.CurrentStep().Name, context.ProfileName, result.DataUnitInfos, result.ErrorMessage)); } return true; }
Related Content
- 12 days ago
- 2 years ago
- 3 years ago