<?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 Retrieve executionId inside CommandInterceptor in Alfresco Forum</title>
    <link>https://connect.hyland.com/t5/alfresco-forum/retrieve-executionid-inside-commandinterceptor/m-p/5460#M2685</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I am implementing my own Activiti command intereceptor like this :&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;public class ActivitiCommandInterceptor extends AbstractCommandInterceptor {&lt;BR /&gt;&amp;nbsp; &amp;nbsp; private RuntimeService runtimeService;&lt;BR /&gt;&amp;nbsp; &amp;nbsp; private CommandInterceptor delegate;&lt;BR /&gt; &lt;BR /&gt;&amp;nbsp; &amp;nbsp; public ActivitiSpringTxCommandInterceptor(RuntimeService runtimeService, CommandInterceptor delegate) {&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; this.runtimeService = runtimeService;&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; this.delegate=delegate;&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;}&lt;BR /&gt; &lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;@Override&lt;BR /&gt;&amp;nbsp; &amp;nbsp; public &amp;lt;T&amp;gt; T execute(CommandConfig config, Command&amp;lt;T&amp;gt; command) {&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; String myVariable = runtimeService.getVariable(&amp;lt;missingExecutionId&amp;gt;, "myVariableName");&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; ...&lt;BR /&gt;&amp;nbsp; &amp;nbsp; }&lt;BR /&gt; }&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Inside the `execute()` method I need to retrieve a variable from the execution context related to this command.&lt;/P&gt;&lt;P&gt;To do that, I need to have the `executionId`, but I can't find a way to retrieve it.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;How can I get my variable from this interceptor?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 26 Jun 2019 09:28:39 GMT</pubDate>
    <dc:creator>louisp</dc:creator>
    <dc:date>2019-06-26T09:28:39Z</dc:date>
    <item>
      <title>Retrieve executionId inside CommandInterceptor</title>
      <link>https://connect.hyland.com/t5/alfresco-forum/retrieve-executionid-inside-commandinterceptor/m-p/5460#M2685</link>
      <description>I am implementing my own Activiti command intereceptor like this &lt;IMG id="smileytongue" class="emoticon emoticon-smileytongue" src="https://migration33.stage.lithium.com/i/smilies/16x16_smiley-tongue.png" alt="Smiley Tongue" title="Smiley Tongue" /&gt;ublic class ActivitiCommandInterceptor extends AbstractCommandInterceptor {&amp;nbsp; &amp;nbsp; private RuntimeService runtimeService;&amp;nbsp; &amp;nbsp; private CommandInterceptor delegate; &amp;nbsp; &amp;nbsp; public ActivitiSpringTxCommandInterceptor(RuntimeService runtimeService</description>
      <pubDate>Wed, 26 Jun 2019 09:28:39 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-forum/retrieve-executionid-inside-commandinterceptor/m-p/5460#M2685</guid>
      <dc:creator>louisp</dc:creator>
      <dc:date>2019-06-26T09:28:39Z</dc:date>
    </item>
  </channel>
</rss>

