<?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 Re: Parsing the process definition in Alfresco Archive</title>
    <link>https://connect.hyland.com/t5/alfresco-archive/parsing-the-process-definition/m-p/33436#M17438</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Ok, can get the process definition:&lt;/SPAN&gt;&lt;BR /&gt;&lt;CODE&gt;&lt;BR /&gt;ProcessDefinition p = processEngine.getRepositoryService()&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; .createProcessDefinitionQuery()&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; .key(processName).singleResult()&lt;BR /&gt;&lt;/CODE&gt;&lt;SPAN&gt;Correct? But what should I cast to? And then how can I get to the definition itself? &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Even with the debugger I could not see something helpful in the ProcessDefinition.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Please, could you give me some hints how to proceed, so I don't have to wait for the next release?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 06 Oct 2010 09:33:02 GMT</pubDate>
    <dc:creator>frauke</dc:creator>
    <dc:date>2010-10-06T09:33:02Z</dc:date>
    <item>
      <title>Parsing the process definition</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/parsing-the-process-definition/m-p/33434#M17436</link>
      <description>Hello everybody,is it possible to parse the process definition before the process has been started?We like to get some information about the tasks before starting the process.Frauke</description>
      <pubDate>Tue, 05 Oct 2010 14:21:38 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/parsing-the-process-definition/m-p/33434#M17436</guid>
      <dc:creator>frauke</dc:creator>
      <dc:date>2010-10-05T14:21:38Z</dc:date>
    </item>
    <item>
      <title>Re: Parsing the process definition</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/parsing-the-process-definition/m-p/33435#M17437</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;That's currently not possible (at least not without casting: you could do it by obtaining a ProcessDefinition through the processDefinitionQuery),&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;but we have had several request for this so we are currently thinking about incorporating this in the API.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 06 Oct 2010 08:40:11 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/parsing-the-process-definition/m-p/33435#M17437</guid>
      <dc:creator>jbarrez</dc:creator>
      <dc:date>2010-10-06T08:40:11Z</dc:date>
    </item>
    <item>
      <title>Re: Parsing the process definition</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/parsing-the-process-definition/m-p/33436#M17438</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Ok, can get the process definition:&lt;/SPAN&gt;&lt;BR /&gt;&lt;CODE&gt;&lt;BR /&gt;ProcessDefinition p = processEngine.getRepositoryService()&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; .createProcessDefinitionQuery()&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; .key(processName).singleResult()&lt;BR /&gt;&lt;/CODE&gt;&lt;SPAN&gt;Correct? But what should I cast to? And then how can I get to the definition itself? &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Even with the debugger I could not see something helpful in the ProcessDefinition.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Please, could you give me some hints how to proceed, so I don't have to wait for the next release?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 06 Oct 2010 09:33:02 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/parsing-the-process-definition/m-p/33436#M17438</guid>
      <dc:creator>frauke</dc:creator>
      <dc:date>2010-10-06T09:33:02Z</dc:date>
    </item>
    <item>
      <title>Re: Parsing the process definition</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/parsing-the-process-definition/m-p/33437#M17439</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;It;s very low-level PVM code, but this should do it:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;cast to ProcessDefinitionImpl. This has an getInitial() method which returns an ActivityImpl.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;This ActivityImpl has outgoingTransitions that can be followed to its destinatiins (again ActivityImpl).&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;But as you would agree, this isnt very pretty to look at &lt;span class="lia-unicode-emoji" title=":winking_face:"&gt;😉&lt;/span&gt;&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 06 Oct 2010 12:06:22 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/parsing-the-process-definition/m-p/33437#M17439</guid>
      <dc:creator>jbarrez</dc:creator>
      <dc:date>2010-10-06T12:06:22Z</dc:date>
    </item>
    <item>
      <title>Re: Parsing the process definition</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/parsing-the-process-definition/m-p/33438#M17440</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Oh, it looks pretty enough to me … if it would work like that.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;But the getInitial() returns null. :cry:&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 06 Oct 2010 12:21:43 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/parsing-the-process-definition/m-p/33438#M17440</guid>
      <dc:creator>frauke</dc:creator>
      <dc:date>2010-10-06T12:21:43Z</dc:date>
    </item>
    <item>
      <title>Re: Parsing the process definition</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/parsing-the-process-definition/m-p/33439#M17441</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;This issue is what I ran into several days ago, and there's another thread about it:&lt;/SPAN&gt;&lt;BR /&gt;&lt;A href="http://forums.activiti.org/en/viewtopic.php?f=3&amp;amp;t=288" rel="nofollow noopener noreferrer"&gt;http://forums.activiti.org/en/viewtopic.php?f=3&amp;amp;t=288&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;It is null because the process definition is not parsed at that point.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;When you start a process, Activiti looks up the cache, and if the process is not in the cache it loads it, parses it (from the bytes of deployment) and puts it into the cache.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Your issue comes up because the definition is not parsed until it is needed for execution by PVM. There will be API for loading it, see here:&lt;/SPAN&gt;&lt;BR /&gt;&lt;A href="http://jira.codehaus.org/browse/ACT-172" rel="nofollow noopener noreferrer"&gt;http://jira.codehaus.org/browse/ACT-172&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Meanwhile, here's a very ugly hack:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;If you start the process once, it should be placed in the cache alright. So if you can somehow start a fake instance of the process, that should work for you (I guess).&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I'm waiting for my access to be granted on Activiti source code. I can fix this issue quickly if so, and let you know.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;-Hamed&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 07 Oct 2010 07:19:14 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/parsing-the-process-definition/m-p/33439#M17441</guid>
      <dc:creator>iravanchi</dc:creator>
      <dc:date>2010-10-07T07:19:14Z</dc:date>
    </item>
    <item>
      <title>Re: Parsing the process definition</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/parsing-the-process-definition/m-p/33440#M17442</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;To elaborate a bit more on that ugly hack:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;The &lt;/SPAN&gt;&lt;EM&gt;ProcessInstance&lt;/EM&gt;&lt;SPAN&gt; returned by the &lt;/SPAN&gt;&lt;EM&gt;startProcessInstanceBy*&lt;/EM&gt;&lt;SPAN&gt; methods of the &lt;/SPAN&gt;&lt;EM&gt;RuntimeService&lt;/EM&gt;&lt;SPAN&gt; contains an introspectable &lt;/SPAN&gt;&lt;EM&gt;ProcessDefinitionEntity&lt;/EM&gt;&lt;SPAN&gt;. So either you keep that &lt;/SPAN&gt;&lt;EM&gt;ProcessDefinitionEntity&lt;/EM&gt;&lt;SPAN&gt; in memory or you start a fake instance every time you need it.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 13 Oct 2010 21:50:52 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/parsing-the-process-definition/m-p/33440#M17442</guid>
      <dc:creator>falko_menge</dc:creator>
      <dc:date>2010-10-13T21:50:52Z</dc:date>
    </item>
    <item>
      <title>Re: Parsing the process definition</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/parsing-the-process-definition/m-p/33441#M17443</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Is is possible to start the fake process instance without the process doing something?&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Usually if I start the process it starts modifying my system right away and I can't do that.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 14 Oct 2010 06:32:22 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/parsing-the-process-definition/m-p/33441#M17443</guid>
      <dc:creator>frauke</dc:creator>
      <dc:date>2010-10-14T06:32:22Z</dc:date>
    </item>
    <item>
      <title>Re: Parsing the process definition</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/parsing-the-process-definition/m-p/33442#M17444</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;method to inspect the process was added &lt;/SPAN&gt;&lt;A href="http://jira.codehaus.org/browse/ACT-242" rel="nofollow noopener noreferrer"&gt;http://jira.codehaus.org/browse/ACT-242&lt;/A&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 14 Oct 2010 10:35:52 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/parsing-the-process-definition/m-p/33442#M17444</guid>
      <dc:creator>tombaeyens</dc:creator>
      <dc:date>2010-10-14T10:35:52Z</dc:date>
    </item>
    <item>
      <title>Re: Parsing the process definition</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/parsing-the-process-definition/m-p/33443#M17445</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;ACT-172 is a related issue. You might want to mark it as resolved too.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 14 Oct 2010 14:09:27 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/parsing-the-process-definition/m-p/33443#M17445</guid>
      <dc:creator>iravanchi</dc:creator>
      <dc:date>2010-10-14T14:09:27Z</dc:date>
    </item>
    <item>
      <title>Re: Parsing the process definition</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/parsing-the-process-definition/m-p/33444#M17446</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Correct. I closed it. Thanks!&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 18 Oct 2010 08:39:43 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/parsing-the-process-definition/m-p/33444#M17446</guid>
      <dc:creator>jbarrez</dc:creator>
      <dc:date>2010-10-18T08:39:43Z</dc:date>
    </item>
    <item>
      <title>Re: Parsing the process definition</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/parsing-the-process-definition/m-p/33445#M17447</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I still don't see the api function from ACT-242 in 5.3.&amp;nbsp; &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;ReadOnlyProcessDefinition RepositoryService.getDeployedProcessDefinition(String);&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I would like to introspect the structure of some of my workflows, what to do?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 17 Mar 2011 21:54:21 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/parsing-the-process-definition/m-p/33445#M17447</guid>
      <dc:creator>rmoskal</dc:creator>
      <dc:date>2011-03-17T21:54:21Z</dc:date>
    </item>
    <item>
      <title>Re: Parsing the process definition</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/parsing-the-process-definition/m-p/33446#M17448</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;And a processquery from the runtime service doesn't return a ProcessInstance with the ProcessDefinition fields populated.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 17 Mar 2011 22:01:01 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/parsing-the-process-definition/m-p/33446#M17448</guid>
      <dc:creator>rmoskal</dc:creator>
      <dc:date>2011-03-17T22:01:01Z</dc:date>
    </item>
    <item>
      <title>Re: Parsing the process definition</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/parsing-the-process-definition/m-p/33447#M17449</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;You will need to cast to RepositoryServiceImpl to see the method. It's not yet 100% as we would like it, hence the cast.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;And a processquery from the runtime service doesn't return a ProcessInstance with the ProcessDefinition fields populated.&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt;No, this is for performance reasons, as parsing the process definition is time-consuming and wouldnt service 80% of the typical use cases.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;So you would need a second query to get the details.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 21 Mar 2011 16:51:24 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/parsing-the-process-definition/m-p/33447#M17449</guid>
      <dc:creator>jbarrez</dc:creator>
      <dc:date>2011-03-21T16:51:24Z</dc:date>
    </item>
  </channel>
</rss>

