Batch Macro - They seem to run concurrently. How to Force to run Running Consecutively
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Mute
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Hello,
The summary is: I suspect that the Batch Macro runs concurrently but I need it to run consecutively to give each iteration time to finish its interaction with the Tableau Server. Is my suspicion correct and what do I do differently?
I have a Batch Macro which uses Rest API to download a data source from a Tableau server.
When I run it directly (so that it uses the Template Input (for Test as a Standard Workflow)->Text Input) it run's correctly 100% of the time (including manually putting in different data sources in the Text Input))
When I run it in Batch Macro mode so that I pass it 10 data sources, it only downloads a few of the data sources.
My guess is that the tableau server doesn't like 10 concurrent requests.
A few things are making me guess that it's not running the batch macro consecutively. One, a seemingly random set of data sources are downloaded every time.
Another is that I added 2 message and a wait tool (below screenshot) and the Results Messages are:
First Message Tool - Data Source Name One
First Message Tool - Data Source Name Two
First Message Tool - Data Source Name Three
First Message Tool - Data Source Name Four
2nd Message Tool After the Wait - Data Source Name One
2nd Message Tool After the Wait - Data Source Name Two
2nd Message Tool After the Wait - Data Source Name Three
2nd Message Tool After the Wait - Data Source Name Four
The macro runs a tar to unzip the Datasource and it's only one terminal window popping up instead of one for every iteration.
I have this problem with the Rest API. Using the old Tabcmd (from Tableau...it's a cmd that gets installed on the Gallery), it runs correctly. I guess the authentication/interaction is more like a person doing something on a server unlike the RestAPI interaction.
(I'm still on Designer 2021.1)
Solved! Go to Solution.
- Labels:
- Batch Macro
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Hey @AlexApolloni,
Is the AMP Engine Turned on in you workflow? Turning it off might help. AMP enables Alteryx to process multiple records at once, so this could cause an issue.
Other then that you could try if the "Throttle" Tool is more helpful then "Wait a Second".
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
From your description it sounds like it's behaving like a standard macro. Have a look at this post and make sure you are using a control parameter and/or control group by appropriately:
Also ensure it is saved as type Batch Macro:
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Thanks for the replies!
@FrederikE I had AMP turned off(put then tried it on ¯\_(ツ)_/¯ and now it's back off).
I tried adding the Throttle but didn't see an improvement. Would you put it in the same place as the Wait a Second? I did that and set it to "1 Record per minute".
@willemb Mmmm.. it looks like this...seems ok, no?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Try it like this, and then in the Control GroupBy field select DataSourceName again:
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
🎉
That did it.
Now when I run it (in addition to seeing all of the data sources downloading) the tar/unzip cmd windows pop up once per macro iteration vs previously when they seemed to get all bundled into one cmd run.
Very strange, I reread the post you pointed me to and I'm not really understanding why it's acting differently.
Thanks again, I definitely wouldn't have tried what you suggested based off of the documentation.
