<?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 NPE when trying to signal Receive Task in Alfresco Archive</title>
    <link>https://connect.hyland.com/t5/alfresco-archive/npe-when-trying-to-signal-receive-task/m-p/191136#M144266</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hello everyone,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I'm trying to model a process where users receive a mail after which they need to verify that they read it. If they haven't verified after a certain period, another mail should be send. This should continue indefinitely until either all users have verified the mail or someone overrides the process.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;The following schema shows how I modeled the happy flow where users always immediately verify upon receiving the mail.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;A href="http://imgur.com/Rd3Ojby" rel="nofollow noopener noreferrer"&gt;http://imgur.com/Rd3Ojby&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;The sub-process is called for each e-mail in a collection of e-mails that is set on the process context when starting the process. The "Send mail" ServiceTask sends an e-mail to someone with the execution ID in the message body. (DelegateExecution.getId()) Using the console, I enter the number and call RuntimeService.signal(id) where id is the number I just received from the mail. Once I do this for all e-mails, the process continues as expected and "Hello World" is printed to the console.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Next, I try to send an e-mail every n-period while no signal has been received.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;A href="http://imgur.com/4AUDEDq" rel="nofollow noopener noreferrer"&gt;http://imgur.com/4AUDEDq&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;When I run this process, I will indeed get an e-mail every n-period. However, when I now signal the execution ID I get the exception as shown in the image.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Is this the right way to model what I'm trying to achieve? If so, how can I resolve this issue? If not, how would you recommend these requirements to be modeled?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thank you very much,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Davey&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 13 Oct 2014 09:10:01 GMT</pubDate>
    <dc:creator>daveychu</dc:creator>
    <dc:date>2014-10-13T09:10:01Z</dc:date>
    <item>
      <title>NPE when trying to signal Receive Task</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/npe-when-trying-to-signal-receive-task/m-p/191136#M144266</link>
      <description>Hello everyone,I'm trying to model a process where users receive a mail after which they need to verify that they read it. If they haven't verified after a certain period, another mail should be send. This should continue indefinitely until either all users have verified the mail or someone override</description>
      <pubDate>Mon, 13 Oct 2014 09:10:01 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/npe-when-trying-to-signal-receive-task/m-p/191136#M144266</guid>
      <dc:creator>daveychu</dc:creator>
      <dc:date>2014-10-13T09:10:01Z</dc:date>
    </item>
    <item>
      <title>Re: NPE when trying to signal Receive Task</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/npe-when-trying-to-signal-receive-task/m-p/191137#M144267</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi Davey,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Could you create jUnit test to reproduce this exception?&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;To solve your problem use following jUnit test from activiti source:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;org.activiti.engine.test.bpmn.event.timer.IntermediateTimerEventTest#testLoop&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Regards&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Martin&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 14 Oct 2014 06:21:32 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/npe-when-trying-to-signal-receive-task/m-p/191137#M144267</guid>
      <dc:creator>martin_grofcik</dc:creator>
      <dc:date>2014-10-14T06:21:32Z</dc:date>
    </item>
    <item>
      <title>Re: NPE when trying to signal Receive Task</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/npe-when-trying-to-signal-receive-task/m-p/191138#M144268</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hello Davey,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thank you for the jUnit test - it makes things much easier.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;I cloned it - but I do not have access to push changes and I do not want to fork your repository. That's why I post the solution here:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;CODE&gt;&lt;BR /&gt;&amp;nbsp; @Test&lt;BR /&gt;&amp;nbsp; @Deployment(resources = {"diagrams/MyProcess.bpmn"})&lt;BR /&gt;&amp;nbsp; public void testName() {&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; ProcessInstance pi = rule.getRuntimeService().startProcessInstanceByKey("myProcess");&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Execution execution = rule.getRuntimeService().createExecutionQuery()&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; .processInstanceId(pi.getId())&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; .activityId("receivetask1")&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; .singleResult();&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; assertNotNull(execution);&lt;BR /&gt;&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; rule.getRuntimeService().signal(execution.getId());&lt;BR /&gt;&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; assertThat("after the receive task [receivetask1] all process instances are finished",&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; rule.getRuntimeService().createProcessInstanceQuery().count(), is(0L));&lt;BR /&gt;&amp;nbsp; }&lt;BR /&gt;&lt;BR /&gt;&lt;/CODE&gt;&lt;BR /&gt;&lt;SPAN&gt;Regards&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Martin&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 16 Oct 2014 06:42:02 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/npe-when-trying-to-signal-receive-task/m-p/191138#M144268</guid>
      <dc:creator>martin_grofcik</dc:creator>
      <dc:date>2014-10-16T06:42:02Z</dc:date>
    </item>
    <item>
      <title>Re: NPE when trying to signal Receive Task</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/npe-when-trying-to-signal-receive-task/m-p/191139#M144269</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Your unit test works exactly as required. Thank you Martin! Is there an expected way to mark this topic as solved?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Kind regards,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Davey&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 16 Oct 2014 07:41:16 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/npe-when-trying-to-signal-receive-task/m-p/191139#M144269</guid>
      <dc:creator>daveychu</dc:creator>
      <dc:date>2014-10-16T07:41:16Z</dc:date>
    </item>
    <item>
      <title>Re: NPE when trying to signal Receive Task</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/npe-when-trying-to-signal-receive-task/m-p/191140#M144270</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;No, sorry, no such feature here. But thanks for posting back that it works &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 17 Oct 2014 09:46:51 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/npe-when-trying-to-signal-receive-task/m-p/191140#M144270</guid>
      <dc:creator>jbarrez</dc:creator>
      <dc:date>2014-10-17T09:46:51Z</dc:date>
    </item>
    <item>
      <title>Re: NPE when trying to signal Receive Task</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/npe-when-trying-to-signal-receive-task/m-p/191141#M144271</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hello Martin,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I reproduced the problem via JUnit test as requested.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Kind regards,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Davey&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 16 Jan 2015 10:32:39 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/npe-when-trying-to-signal-receive-task/m-p/191141#M144271</guid>
      <dc:creator>daveychu</dc:creator>
      <dc:date>2015-01-16T10:32:39Z</dc:date>
    </item>
    <item>
      <title>Re: NPE when trying to signal Receive Task</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/npe-when-trying-to-signal-receive-task/m-p/191142#M144272</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi Davey,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;I have a requirement wherein I am using a receive task to make a process wait until the receive task gets the required ID to continue the process.I have referred the following link:&lt;/SPAN&gt;&lt;A href="http://forums.activiti.org/content/correct-way-signal-receivetask" rel="nofollow noopener noreferrer"&gt;http://forums.activiti.org/content/correct-way-signal-receivetask&lt;/A&gt;&lt;SPAN&gt; but could not achieve the desired as I am getting errors in the code.Can you help with your code for my reference.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 03 Jul 2015 07:13:34 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/npe-when-trying-to-signal-receive-task/m-p/191142#M144272</guid>
      <dc:creator>owais1</dc:creator>
      <dc:date>2015-07-03T07:13:34Z</dc:date>
    </item>
  </channel>
</rss>

