Hey Community! Can anyone help me to create a custom event?
Best Answer
-
The solution I have for this involves a few different steps. I'm assuming that the dataset is being refreshed ad-hoc (eg from a file source), rather than being refreshed automatically (eg from a database).
To begin, I have
- A Dataset in Space1 (MySourceData)
- A View in Space1, which shares this data into Space2
- A published workflow in Space2 (Execute when MySourceData refreshes) which should run on dataset refresh
1. Set up a Custom Event in Space1 that will be shared to Space2
Create a Custom Event and share it to Space2. This is what will trigger the workflow in Space2.
2. Create a workflow in Space1 to trigger the custom event
Create a very simple workflow that will trigger the custom event (using the Fire Event step) and publish it:
3. Create an Automation in Space 1 to trigger when the Dataset is refreshed
This Automation will cause the workflow we created in step 2 (Fire Event When MySourceData is refreshed, in Space1) to be executed.
4. Include the Space1 Custom Event in Space2
Navigate to Space2. Bring in the custom event that you created in step 1 (from Space1, using the "Include from another Space" option).
5. Create an Automation in Space2 to trigger when the Space1 Custom Event occurs
The Automation in Space2 will be triggered when the Space1 event is fired, and will cause the Space2 workflow (which you'd created earlier) to be executed
Result
The outcome of all this work should be that, when you refresh the MySourceData dataset, two workflows will execute:
- The Fire Event When MySourceData is refreshed workflow in Space1, triggered by the dataset refresh.
- The Execte when MySourceData refreshes workflow in Space2, triggered by the Space1 Custom Event.
1
Answers
-
Hi M.Lambert,
There is not much details to work on (maybe you can share more on what you're trying to achieve?) but the short answer is while automations are bound by space, you can actually create custom events and share it across other spaces. With that you will be able to trigger your automation in a different space when the custom event is fired. This works from Aperture Data Studio v2.8.7 onwards. Please refer to the release notes here for more details. Do let me know if this helps or if you have further questions. Thanks.
2 -
Hi Ivan, thanks for your help. I tried to create the custom event but I feel like I need to understand a bit more, for example: We divided the whole process that the data goes through into 3 spaces, so the output of one space gets saved as a view and shared with other space so how is this going to work? Does the custom event get the output from the other space and trigger the next workflow?
1 -
It sounds like this is the problem you're trying to solve:
- You have a Dataset in Space1
- That Dataset is shared via a View to Space2
- The View is then used in a Workflow in Space 2
- When the Dataset is refreshed in Space1, you want it to trigger the Workflow in Space2 to execute
Is that correct?
1 -
Hey Henry, spot on that's exactly what I need. How I make this flow work without saving a view and sharing between spaces?
1 -
Ok Henry, that make sense. I will try that now and will let you know. Thanks a lot
0 -
Hi there, I just wanted to leave a comment here as I was trying to put the custom event in the beginning of the workflow but now realise is in the end. This is saying to the next workflow that the data has been refreshed, so the automation triggers for that workflow. Thanks a lot for your help Henry it all seems to be working now!
1