<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Run a workflow on multiple devices, one after the other in ExtremeCloud IQ- Site Engine Management Center</title>
    <link>https://community.extremenetworks.com/t5/extremecloud-iq-site-engine/run-a-workflow-on-multiple-devices-one-after-the-other/m-p/79058#M8880</link>
    <description>Hello,&lt;BR /&gt;
&lt;BR /&gt;
I have a workflow that finds a given VLAN (with a prompted variable), and duplicates it with another ID if it exists. However, I have two things that I would love to implement, but haven't found anything that shows me it's possible.&lt;BR /&gt;
&lt;BR /&gt;
1 - Is there a way to start the workflow on multiple devices, but it does them one by one, and not at the same time ? &lt;BR /&gt;
As I have multiple python scripts or signals, the workflow is executed steps by steps on all the devices. So when storing information in a variable, it mixes between the devices and I don't have the correct result at the end. &lt;BR /&gt;
Maybe it's possible to create workflow variable from script, but don't know how to play with variable outside of emc_vars.get() and emc_results.put().&lt;BR /&gt;
&lt;BR /&gt;
I guess I could make a GateWay to make a loop, while checking the list of all the selected devices, and increasing an index until it's out of the devices_list's length. But maybe there is a more practical way.&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
2 - Is it possible to add a variable (like the Device name) in an Event's message ?&lt;BR /&gt;
It would be to say "VLAN 3 was correctly added on the device : Device3", or messages like that.&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
Thanks a lot already for the answers. &lt;BR /&gt;
Would happily discuss about it more in details.</description>
    <pubDate>Thu, 15 Aug 2019 20:13:39 GMT</pubDate>
    <dc:creator>Nealo</dc:creator>
    <dc:date>2019-08-15T20:13:39Z</dc:date>
    <item>
      <title>Run a workflow on multiple devices, one after the other</title>
      <link>https://community.extremenetworks.com/t5/extremecloud-iq-site-engine/run-a-workflow-on-multiple-devices-one-after-the-other/m-p/79058#M8880</link>
      <description>Hello,&lt;BR /&gt;
&lt;BR /&gt;
I have a workflow that finds a given VLAN (with a prompted variable), and duplicates it with another ID if it exists. However, I have two things that I would love to implement, but haven't found anything that shows me it's possible.&lt;BR /&gt;
&lt;BR /&gt;
1 - Is there a way to start the workflow on multiple devices, but it does them one by one, and not at the same time ? &lt;BR /&gt;
As I have multiple python scripts or signals, the workflow is executed steps by steps on all the devices. So when storing information in a variable, it mixes between the devices and I don't have the correct result at the end. &lt;BR /&gt;
Maybe it's possible to create workflow variable from script, but don't know how to play with variable outside of emc_vars.get() and emc_results.put().&lt;BR /&gt;
&lt;BR /&gt;
I guess I could make a GateWay to make a loop, while checking the list of all the selected devices, and increasing an index until it's out of the devices_list's length. But maybe there is a more practical way.&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
2 - Is it possible to add a variable (like the Device name) in an Event's message ?&lt;BR /&gt;
It would be to say "VLAN 3 was correctly added on the device : Device3", or messages like that.&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
Thanks a lot already for the answers. &lt;BR /&gt;
Would happily discuss about it more in details.</description>
      <pubDate>Thu, 15 Aug 2019 20:13:39 GMT</pubDate>
      <guid>https://community.extremenetworks.com/t5/extremecloud-iq-site-engine/run-a-workflow-on-multiple-devices-one-after-the-other/m-p/79058#M8880</guid>
      <dc:creator>Nealo</dc:creator>
      <dc:date>2019-08-15T20:13:39Z</dc:date>
    </item>
    <item>
      <title>Re: Run a workflow on multiple devices, one after the other</title>
      <link>https://community.extremenetworks.com/t5/extremecloud-iq-site-engine/run-a-workflow-on-multiple-devices-one-after-the-other/m-p/79059#M8881</link>
      <description>Number one: store variables from one activity to other activity = the information is not overwritten.&lt;BR /&gt;
This can be done if you define variable scope as activity instead of workflow.&lt;BR /&gt;
&lt;BR /&gt;
Number two: using device name.&lt;BR /&gt;
You can use NBI to get information from XMC database to workflow.&lt;BR /&gt;
&lt;BR /&gt;
Let me know if you need some examples. Next week I should be able to give you hints.</description>
      <pubDate>Fri, 16 Aug 2019 14:21:05 GMT</pubDate>
      <guid>https://community.extremenetworks.com/t5/extremecloud-iq-site-engine/run-a-workflow-on-multiple-devices-one-after-the-other/m-p/79059#M8881</guid>
      <dc:creator>Zdeněk_Pala</dc:creator>
      <dc:date>2019-08-16T14:21:05Z</dc:date>
    </item>
    <item>
      <title>Re: Run a workflow on multiple devices, one after the other</title>
      <link>https://community.extremenetworks.com/t5/extremecloud-iq-site-engine/run-a-workflow-on-multiple-devices-one-after-the-other/m-p/79060#M8882</link>
      <description>&lt;BR /&gt;
&lt;BR /&gt;
Thanks for those infos. I have to look into it.&lt;BR /&gt;
Would love some examples though, so I can have a better idea on how it works.</description>
      <pubDate>Fri, 16 Aug 2019 15:56:22 GMT</pubDate>
      <guid>https://community.extremenetworks.com/t5/extremecloud-iq-site-engine/run-a-workflow-on-multiple-devices-one-after-the-other/m-p/79060#M8882</guid>
      <dc:creator>Nealo</dc:creator>
      <dc:date>2019-08-16T15:56:22Z</dc:date>
    </item>
    <item>
      <title>Re: Run a workflow on multiple devices, one after the other</title>
      <link>https://community.extremenetworks.com/t5/extremecloud-iq-site-engine/run-a-workflow-on-multiple-devices-one-after-the-other/m-p/79061#M8883</link>
      <description>here is example for the device name/nickname NBI call&lt;BR /&gt;
&lt;BR /&gt;
&lt;DIV class="threadCode"&gt;&lt;B&gt;code:&lt;/B&gt;&lt;PRE spellcheck="false"&gt;varDeviceIP = "10.8.255.15"&lt;BR /&gt;varQuery = '''query{network{device(ip:"%s"){name,nickName}}}''' %varDeviceIP &lt;BR /&gt;varResult = emc_nbi.query(varQuery)&lt;BR /&gt;varName = varResult['network']['device']['name']&lt;BR /&gt;varNickName = varResult['network']['device']['nickName']&lt;BR /&gt;&lt;/PRE&gt;&lt;/DIV&gt;</description>
      <pubDate>Sat, 17 Aug 2019 02:45:57 GMT</pubDate>
      <guid>https://community.extremenetworks.com/t5/extremecloud-iq-site-engine/run-a-workflow-on-multiple-devices-one-after-the-other/m-p/79061#M8883</guid>
      <dc:creator>Zdeněk_Pala</dc:creator>
      <dc:date>2019-08-17T02:45:57Z</dc:date>
    </item>
    <item>
      <title>Re: Run a workflow on multiple devices, one after the other</title>
      <link>https://community.extremenetworks.com/t5/extremecloud-iq-site-engine/run-a-workflow-on-multiple-devices-one-after-the-other/m-p/79062#M8884</link>
      <description>&lt;BR /&gt;
&lt;BR /&gt;
I'm not sure I understand correctly where to insert that.&lt;BR /&gt;
&lt;BR /&gt;
In the example figure bollow, should I insert your code in the script Activity &lt;B&gt;Create VLAN 111&lt;/B&gt;, or in the signals &lt;B&gt;VLAN created / VLAN not created&lt;/B&gt; after that ?&lt;BR /&gt;
&lt;P class="fancybox-image"&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="8d1e20e4d2f442999c8f5c7c8c292110_6aec6316-f610-4fe3-baa7-56c8b4ebb7bb.png"&gt;&lt;img src="https://community.extremenetworks.com/t5/image/serverpage/image-id/1772i8055903810AB2DB2/image-size/large?v=v2&amp;amp;px=999" role="button" title="8d1e20e4d2f442999c8f5c7c8c292110_6aec6316-f610-4fe3-baa7-56c8b4ebb7bb.png" alt="8d1e20e4d2f442999c8f5c7c8c292110_6aec6316-f610-4fe3-baa7-56c8b4ebb7bb.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;BR /&gt;
&lt;BR /&gt;
I guess it's in the script Activity. But it means it prints those informations in the Output of every device that ran the script. Or maybe I'm missing something.&lt;BR /&gt;
&lt;BR /&gt;
What I'm trying to do is keeping logs of the successes/failures of the script.&lt;BR /&gt;
Is there a way to affect the signal message from the script directly ? Like :&lt;BR /&gt;
&lt;DIV class="threadCode"&gt;&lt;B&gt;code:&lt;/B&gt;&lt;PRE spellcheck="false"&gt;emc_signal("ID_vlanCreated").put("message", "The VLAN " + id_vlan + " was created successfully.")&lt;BR /&gt;&lt;/PRE&gt;&lt;/DIV&gt;&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
I tried looking in the &lt;A href="https://api.extremenetworks.com/" target="_blank" rel="nofollow noreferrer noopener"&gt;API&lt;/A&gt; that was given to me in a previous post, but couldn't find any hint. &lt;BR /&gt;
&lt;BR /&gt;
Thanks for helping me.</description>
      <pubDate>Mon, 19 Aug 2019 14:04:18 GMT</pubDate>
      <guid>https://community.extremenetworks.com/t5/extremecloud-iq-site-engine/run-a-workflow-on-multiple-devices-one-after-the-other/m-p/79062#M8884</guid>
      <dc:creator>Nealo</dc:creator>
      <dc:date>2019-08-19T14:04:18Z</dc:date>
    </item>
    <item>
      <title>Re: Run a workflow on multiple devices, one after the other</title>
      <link>https://community.extremenetworks.com/t5/extremecloud-iq-site-engine/run-a-workflow-on-multiple-devices-one-after-the-other/m-p/79063#M8885</link>
      <description>Yes you can add it to the python activity or you can create new python activity. In the activity you can resolv the nickname/name and store it to other variable (scope workflow). This new variable can be used in your signal...</description>
      <pubDate>Mon, 19 Aug 2019 18:00:06 GMT</pubDate>
      <guid>https://community.extremenetworks.com/t5/extremecloud-iq-site-engine/run-a-workflow-on-multiple-devices-one-after-the-other/m-p/79063#M8885</guid>
      <dc:creator>Zdeněk_Pala</dc:creator>
      <dc:date>2019-08-19T18:00:06Z</dc:date>
    </item>
    <item>
      <title>Re: Run a workflow on multiple devices, one after the other</title>
      <link>https://community.extremenetworks.com/t5/extremecloud-iq-site-engine/run-a-workflow-on-multiple-devices-one-after-the-other/m-p/79064#M8886</link>
      <description>I looked at the System workflows' examples to see how to use them in signals. &lt;BR /&gt;
It's the ${CreatedVarName} that needs to be in the message, isn't it ?&lt;BR /&gt;
&lt;BR /&gt;
Thank you very much for the help.</description>
      <pubDate>Mon, 19 Aug 2019 20:02:24 GMT</pubDate>
      <guid>https://community.extremenetworks.com/t5/extremecloud-iq-site-engine/run-a-workflow-on-multiple-devices-one-after-the-other/m-p/79064#M8886</guid>
      <dc:creator>Nealo</dc:creator>
      <dc:date>2019-08-19T20:02:24Z</dc:date>
    </item>
    <item>
      <title>Re: Run a workflow on multiple devices, one after the other</title>
      <link>https://community.extremenetworks.com/t5/extremecloud-iq-site-engine/run-a-workflow-on-multiple-devices-one-after-the-other/m-p/79065#M8887</link>
      <description>See two example workflows. &lt;BR /&gt;
&lt;A href="https://extremenetworks2com-my.sharepoint.com/:u:/g/personal/zpala_extremenetworks_com/EYvwsnf3MFZJqpwuq59ujVgBwe5gNj6jeBM1w5Tv-N7-yw?e=PwONvw" target="_blank" rel="nofollow noreferrer noopener"&gt;4Nealo &lt;/A&gt;= you can see how we can handle variables in Signals.&lt;BR /&gt;
&lt;A href="https://extremenetworks2com-my.sharepoint.com/:u:/g/personal/zpala_extremenetworks_com/EYBqXUBLKG9Em76HoQUNwBYB4CBGd2HMLtOlxSKD1LbUUQ?e=hz9Cfs" target="_blank" rel="nofollow noreferrer noopener"&gt;4Mealo-ConcurrentExecution&lt;/A&gt; = you can see how we can pass variables between activities with concurrent execution.&lt;BR /&gt;
&lt;BR /&gt;
I have not found nice way how to generate more signals in concurrent execution.</description>
      <pubDate>Tue, 20 Aug 2019 03:58:45 GMT</pubDate>
      <guid>https://community.extremenetworks.com/t5/extremecloud-iq-site-engine/run-a-workflow-on-multiple-devices-one-after-the-other/m-p/79065#M8887</guid>
      <dc:creator>Zdeněk_Pala</dc:creator>
      <dc:date>2019-08-20T03:58:45Z</dc:date>
    </item>
  </channel>
</rss>

