<?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: issue with bean acces in service task in Alfresco Archive</title>
    <link>https://connect.hyland.com/t5/alfresco-archive/issue-with-bean-acces-in-service-task/m-p/109359#M76744</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi and thanks for looking into this.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I'm really not a spring expert …&amp;nbsp; I tried to add this property under beans element&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;CODE&gt;org.xml.sax.SAXParseException: cvc-complex-type.2.4.a: Invalid content was found starting with element 'property'. One of '{"&lt;A href="http://www.springframework.org/schema/beans%22:import" rel="nofollow noopener noreferrer"&gt;http://www.springframework.org/schema/beans':import&lt;/A&gt;, "&lt;A href="http://www.springframework.org/schema/beans%22:alias" rel="nofollow noopener noreferrer"&gt;http://www.springframework.org/schema/beans':alias&lt;/A&gt;, "&lt;A href="http://www.springframework.org/schema/beans%22:bean" rel="nofollow noopener noreferrer"&gt;http://www.springframework.org/schema/beans':bean&lt;/A&gt;, WC[##other:"&lt;A href="http://www.springframework.org/schema/beans" rel="nofollow noopener noreferrer"&gt;http://www.springframework.org/schema/beans&lt;/A&gt;"], "&lt;A href="http://www.springframework.org/schema/beans%22:beans" rel="nofollow noopener noreferrer"&gt;http://www.springframework.org/schema/beans':beans&lt;/A&gt;}' is expected.&lt;BR /&gt;&lt;/CODE&gt;&lt;BR /&gt;&lt;SPAN&gt;and under bean&amp;nbsp; id="processEngineConfiguration" –&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;CODE&gt;org.springframework.beans.NotWritablePropertyException: Invalid property 'myService' of bean class [org.activiti.spring.SpringProcessEngineConfiguration]: &lt;/CODE&gt;&lt;BR /&gt;&lt;SPAN&gt;Where should I define this property ? And should it be defined for any bean I want to use from service tasks ?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Regards,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Michel&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 11 Oct 2012 15:14:57 GMT</pubDate>
    <dc:creator>mdaviot</dc:creator>
    <dc:date>2012-10-11T15:14:57Z</dc:date>
    <item>
      <title>issue with bean acces in service task</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/issue-with-bean-acces-in-service-task/m-p/109357#M76742</link>
      <description>Hello,I have been stuck all day with this issue… your help would be really welcome.I have a simple process DemoErrorManagement with a service task implemented as an expression which refers to a bean : myService, speficied with the interface Service1.In my unit test I inject the bean myService which</description>
      <pubDate>Wed, 10 Oct 2012 16:52:22 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/issue-with-bean-acces-in-service-task/m-p/109357#M76742</guid>
      <dc:creator>mdaviot</dc:creator>
      <dc:date>2012-10-10T16:52:22Z</dc:date>
    </item>
    <item>
      <title>Re: issue with bean acces in service task</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/issue-with-bean-acces-in-service-task/m-p/109358#M76743</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I see you're using the SpringProcessEngineCOnfiguration. So the full spring-context is available to use in your expressions. So "myService" should just work.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Can you try adding the bean to the "beans" property in activiti configuration;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;CODE&gt;&lt;BR /&gt;&amp;lt;property name="myService"&amp;gt;&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;map&amp;gt;&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;entry key="myService" value-ref="myService" /&amp;gt;&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/map&amp;gt;&lt;BR /&gt;&amp;nbsp; &amp;lt;/property&amp;gt;&lt;BR /&gt;&lt;/CODE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 11 Oct 2012 13:20:42 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/issue-with-bean-acces-in-service-task/m-p/109358#M76743</guid>
      <dc:creator>frederikherema1</dc:creator>
      <dc:date>2012-10-11T13:20:42Z</dc:date>
    </item>
    <item>
      <title>Re: issue with bean acces in service task</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/issue-with-bean-acces-in-service-task/m-p/109359#M76744</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi and thanks for looking into this.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I'm really not a spring expert …&amp;nbsp; I tried to add this property under beans element&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;CODE&gt;org.xml.sax.SAXParseException: cvc-complex-type.2.4.a: Invalid content was found starting with element 'property'. One of '{"&lt;A href="http://www.springframework.org/schema/beans%22:import" rel="nofollow noopener noreferrer"&gt;http://www.springframework.org/schema/beans':import&lt;/A&gt;, "&lt;A href="http://www.springframework.org/schema/beans%22:alias" rel="nofollow noopener noreferrer"&gt;http://www.springframework.org/schema/beans':alias&lt;/A&gt;, "&lt;A href="http://www.springframework.org/schema/beans%22:bean" rel="nofollow noopener noreferrer"&gt;http://www.springframework.org/schema/beans':bean&lt;/A&gt;, WC[##other:"&lt;A href="http://www.springframework.org/schema/beans" rel="nofollow noopener noreferrer"&gt;http://www.springframework.org/schema/beans&lt;/A&gt;"], "&lt;A href="http://www.springframework.org/schema/beans%22:beans" rel="nofollow noopener noreferrer"&gt;http://www.springframework.org/schema/beans':beans&lt;/A&gt;}' is expected.&lt;BR /&gt;&lt;/CODE&gt;&lt;BR /&gt;&lt;SPAN&gt;and under bean&amp;nbsp; id="processEngineConfiguration" –&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;CODE&gt;org.springframework.beans.NotWritablePropertyException: Invalid property 'myService' of bean class [org.activiti.spring.SpringProcessEngineConfiguration]: &lt;/CODE&gt;&lt;BR /&gt;&lt;SPAN&gt;Where should I define this property ? And should it be defined for any bean I want to use from service tasks ?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Regards,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Michel&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 11 Oct 2012 15:14:57 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/issue-with-bean-acces-in-service-task/m-p/109359#M76744</guid>
      <dc:creator>mdaviot</dc:creator>
      <dc:date>2012-10-11T15:14:57Z</dc:date>
    </item>
    <item>
      <title>Re: issue with bean acces in service task</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/issue-with-bean-acces-in-service-task/m-p/109360#M76745</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;whoops.. should have been "beans" under "processEngineConfiguration":&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;CODE&gt;&lt;BR /&gt;&amp;lt;property name="beans"&amp;gt;&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;map&amp;gt;&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;entry key="myService" value-ref="myService" /&amp;gt;&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/map&amp;gt;&lt;BR /&gt;&amp;nbsp; &amp;lt;/property&amp;gt;&lt;BR /&gt;&lt;/CODE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 12 Oct 2012 06:59:29 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/issue-with-bean-acces-in-service-task/m-p/109360#M76745</guid>
      <dc:creator>frederikherema1</dc:creator>
      <dc:date>2012-10-12T06:59:29Z</dc:date>
    </item>
    <item>
      <title>Re: issue with bean acces in service task</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/issue-with-bean-acces-in-service-task/m-p/109361#M76746</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;OK, this time the spring configuration is recognized, but it does not solve my issue at all.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;CODE&gt;&lt;BR /&gt;&amp;lt;bean id="myService" class="net.atos.cetelem.service.impl.DemoService" /&amp;gt;&lt;BR /&gt;&lt;BR /&gt;&amp;lt;bean id="processEngineConfiguration" class="org.activiti.spring.SpringProcessEngineConfiguration"&amp;gt;&lt;BR /&gt;&amp;nbsp; &amp;lt;property name="history" value="full" /&amp;gt;&lt;BR /&gt;&amp;nbsp; &amp;lt;property name="dataSource" ref="activitiDataSource" /&amp;gt;&lt;BR /&gt;&amp;nbsp; &amp;lt;property name="transactionManager" ref="activitiTransactionManager" /&amp;gt;&lt;BR /&gt;&amp;nbsp; &amp;lt;property name="databaseSchemaUpdate" value="true" /&amp;gt;&lt;BR /&gt;&amp;nbsp; &amp;lt;property name="jobExecutorActivate" value="false" /&amp;gt;&lt;BR /&gt;&amp;nbsp; &lt;BR /&gt;&amp;nbsp; &amp;lt;property name="beans"&amp;gt;&lt;BR /&gt;&amp;nbsp; &amp;lt;map&amp;gt;&lt;BR /&gt;&amp;nbsp;&amp;nbsp; &amp;lt;entry key="myService" value-ref="myService" /&amp;gt;&lt;BR /&gt;&amp;nbsp; &amp;lt;/map&amp;gt;&lt;BR /&gt; &amp;lt;/property&amp;gt;&lt;BR /&gt; &amp;lt;/bean&amp;gt;&lt;BR /&gt;&lt;/CODE&gt;&lt;BR /&gt;&lt;SPAN&gt;Would you try to reproduce it on your environment ? You just have to launch net.atos.cetelem.StartProcess, it uses an H2 DB.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;CODE&gt;org.activiti.engine.ActivitiException: Unknown property used in expression&lt;BR /&gt; at org.activiti.engine.impl.el.JuelExpression.getValue(JuelExpression.java:55)&lt;BR /&gt;…&lt;BR /&gt;Caused by: org.activiti.engine.impl.javax.el.PropertyNotFoundException: Cannot resolve identifier 'myService'&lt;BR /&gt; at org.activiti.engine.impl.juel.AstIdentifier.eval(AstIdentifier.java:83)&lt;/CODE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 12 Oct 2012 07:55:15 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/issue-with-bean-acces-in-service-task/m-p/109361#M76746</guid>
      <dc:creator>mdaviot</dc:creator>
      <dc:date>2012-10-12T07:55:15Z</dc:date>
    </item>
    <item>
      <title>Re: issue with bean acces in service task</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/issue-with-bean-acces-in-service-task/m-p/109362#M76747</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;There is no file attached to your comment, please upload it somewhere on the web instead…&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 12 Oct 2012 07:56:34 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/issue-with-bean-acces-in-service-task/m-p/109362#M76747</guid>
      <dc:creator>frederikherema1</dc:creator>
      <dc:date>2012-10-12T07:56:34Z</dc:date>
    </item>
    <item>
      <title>Re: issue with bean acces in service task</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/issue-with-bean-acces-in-service-task/m-p/109363#M76748</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Project is available here : &lt;/SPAN&gt;&lt;A href="http://dl.dropbox.com/u/21035474/DemoErrorMgt.zip" rel="nofollow noopener noreferrer"&gt;http://dl.dropbox.com/u/21035474/DemoErrorMgt.zip&lt;/A&gt;&lt;SPAN&gt; (as stated in the first post)&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 12 Oct 2012 08:24:31 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/issue-with-bean-acces-in-service-task/m-p/109363#M76748</guid>
      <dc:creator>mdaviot</dc:creator>
      <dc:date>2012-10-12T08:24:31Z</dc:date>
    </item>
    <item>
      <title>Re: issue with bean acces in service task</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/issue-with-bean-acces-in-service-task/m-p/109364#M76749</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I see your problem now, it's the way you fetch your process-engine. You're using "ProcessEngines.getDefaultProcessEngine()", this will only read the "processEngines" bean from the activiti.cfg.xml-file.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;If you want to use spring, you have to:&lt;/SPAN&gt;&lt;BR /&gt;&lt;UL&gt;&lt;LI&gt;Use org.activiti.spring.SpringProcessEngineConfiguration (which you are doing, so that's fine)&lt;/LI&gt;&lt;BR /&gt;&lt;LI&gt;Create the ApplicationContext yourself (e.g.. by using Spring's servletContextListener or by creating a XMLClassPathApplicationContext)&lt;/LI&gt;&lt;BR /&gt;&lt;LI&gt;Retreive the bean "processEngine" manually and use this INSTEAD of ProcessEngines.getDefaultProcessEngine()&lt;/LI&gt;&lt;/UL&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 12 Oct 2012 08:41:58 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/issue-with-bean-acces-in-service-task/m-p/109364#M76749</guid>
      <dc:creator>frederikherema1</dc:creator>
      <dc:date>2012-10-12T08:41:58Z</dc:date>
    </item>
    <item>
      <title>Re: issue with bean acces in service task</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/issue-with-bean-acces-in-service-task/m-p/109365#M76750</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Thanks a lot, you solved the issue for me !!&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;For the record, here is the working code if anyone is interested :&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;CODE&gt;&lt;BR /&gt;public class StartProcess {&lt;BR /&gt;&lt;BR /&gt;&amp;nbsp; private static final ApplicationContext ac= &lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; new ClassPathXmlApplicationContext("activiti.cfg.xml");&lt;BR /&gt; &lt;BR /&gt; static ProcessEngine processEngine = ac.getBean(ProcessEngine.class);&lt;BR /&gt;&lt;BR /&gt; public static void main(String[] args) {&lt;BR /&gt;&amp;nbsp; RepositoryService repositoryService = processEngine.getRepositoryService();&lt;BR /&gt;&amp;nbsp; repositoryService.createDeployment().addClasspathResource("diagrams/DemoErrorManagement.bpmn20.xml").deploy();&lt;BR /&gt;&amp;nbsp; processEngine.getRuntimeService().startProcessInstanceByKey("DemoErrorManagement");&lt;BR /&gt;&lt;BR /&gt; }&lt;BR /&gt;&lt;BR /&gt;}&lt;BR /&gt;&lt;BR /&gt;&lt;/CODE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 12 Oct 2012 11:29:08 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/issue-with-bean-acces-in-service-task/m-p/109365#M76750</guid>
      <dc:creator>mdaviot</dc:creator>
      <dc:date>2012-10-12T11:29:08Z</dc:date>
    </item>
    <item>
      <title>Re: issue with bean acces in service task</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/issue-with-bean-acces-in-service-task/m-p/109366#M76751</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Note : this step is not required at all.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;whoops.. should have been "beans" under "processEngineConfiguration":&lt;BR /&gt;&lt;BR /&gt;&lt;CODE&gt;&lt;BR /&gt;&amp;lt;property name="beans"&amp;gt;&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;map&amp;gt;&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;entry key="myService" value-ref="myService" /&amp;gt;&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/map&amp;gt;&lt;BR /&gt;&amp;nbsp; &amp;lt;/property&amp;gt;&lt;BR /&gt;&lt;/CODE&gt;&lt;/BLOCKQUOTE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 12 Oct 2012 11:30:28 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/issue-with-bean-acces-in-service-task/m-p/109366#M76751</guid>
      <dc:creator>mdaviot</dc:creator>
      <dc:date>2012-10-12T11:30:28Z</dc:date>
    </item>
    <item>
      <title>Re: issue with bean acces in service task</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/issue-with-bean-acces-in-service-task/m-p/109367#M76752</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Indeed, it's only required if you want to limit the visibility of the whole spring-context ion expressions….&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 12 Oct 2012 12:14:45 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/issue-with-bean-acces-in-service-task/m-p/109367#M76752</guid>
      <dc:creator>frederikherema1</dc:creator>
      <dc:date>2012-10-12T12:14:45Z</dc:date>
    </item>
  </channel>
</rss>

