<?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: Using CDI from JobExecutor in Alfresco Archive</title>
    <link>https://connect.hyland.com/t5/alfresco-archive/using-cdi-from-jobexecutor/m-p/102004#M70905</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Does this also work for timers? And auto acknowledge? Isn't that dangerous in case of failures?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 20 Jul 2012 07:54:11 GMT</pubDate>
    <dc:creator>ronald_van_kuij</dc:creator>
    <dc:date>2012-07-20T07:54:11Z</dc:date>
    <item>
      <title>Using CDI from JobExecutor</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/using-cdi-from-jobexecutor/m-p/101998#M70899</link>
      <description>Hi all,we're looking for ways on how we can make use of CDI services from activities executed by the JobExecutor in JBoss AS 7. In http://forums.activiti.org/en/viewtopic.php?f=6&amp;amp;t=4167 Daniel suggested to write a JCA connector and use @MessageDriven beans. I've never done any JCA connectors bef</description>
      <pubDate>Thu, 19 Jul 2012 10:11:55 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/using-cdi-from-jobexecutor/m-p/101998#M70899</guid>
      <dc:creator>naag</dc:creator>
      <dc:date>2012-07-19T10:11:55Z</dc:date>
    </item>
    <item>
      <title>Re: Using CDI from JobExecutor</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/using-cdi-from-jobexecutor/m-p/101999#M70900</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Using a JBOSS-provided pool would definitely make sense.. The job-executor can be subclassed to run the acquired jobs in that pool, rather than in a default java-threadpool, like the DefaultJobExecutor uses.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 19 Jul 2012 10:23:35 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/using-cdi-from-jobexecutor/m-p/101999#M70900</guid>
      <dc:creator>frederikherema1</dc:creator>
      <dc:date>2012-07-19T10:23:35Z</dc:date>
    </item>
    <item>
      <title>Re: Using CDI from JobExecutor</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/using-cdi-from-jobexecutor/m-p/102000#M70901</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;So you think that CDI services would then be available? I'm not too familiar yet with the inner workings of CDI and documentation is a little bit sparse &lt;span class="lia-unicode-emoji" title=":disappointed_face:"&gt;😞&lt;/span&gt;&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 19 Jul 2012 11:43:12 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/using-cdi-from-jobexecutor/m-p/102000#M70901</guid>
      <dc:creator>naag</dc:creator>
      <dc:date>2012-07-19T11:43:12Z</dc:date>
    </item>
    <item>
      <title>Re: Using CDI from JobExecutor</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/using-cdi-from-jobexecutor/m-p/102001#M70902</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;My knowledge of CDI isn't that great rather. Not sure if "being in the right thead-context" would give access to the beans. Let alone that annotation-resolving would occur. That's more something for a CDI-expert I'm afraid as I only know the basics&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 19 Jul 2012 12:50:15 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/using-cdi-from-jobexecutor/m-p/102001#M70902</guid>
      <dc:creator>frederikherema1</dc:creator>
      <dc:date>2012-07-19T12:50:15Z</dc:date>
    </item>
    <item>
      <title>Re: Using CDI from JobExecutor</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/using-cdi-from-jobexecutor/m-p/102002#M70903</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;OK, I will try to figure it out with the CDI / JCA spec. There must be something somewhere…! Also from Daniel's post in the thread I posted above, it seems that fox platform supports this use case. So somehow, it must be possible. I try to keep this updated here.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 19 Jul 2012 13:42:14 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/using-cdi-from-jobexecutor/m-p/102002#M70903</guid>
      <dc:creator>naag</dc:creator>
      <dc:date>2012-07-19T13:42:14Z</dc:date>
    </item>
    <item>
      <title>Re: Using CDI from JobExecutor</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/using-cdi-from-jobexecutor/m-p/102003#M70904</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Short update: implementing a custom JobExecutor turns out to be quite easy, and we can send JMS messages from it to a @MessageDriven bean. That bean has CDI services enabled and will execute the job via managementService.executeJob(). Some code:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;CODE&gt;&lt;BR /&gt;import javax.ejb.ActivationConfigProperty;&lt;BR /&gt;import javax.ejb.MessageDriven;&lt;BR /&gt;import javax.inject.Inject;&lt;BR /&gt;import javax.jms.JMSException;&lt;BR /&gt;import javax.jms.Message;&lt;BR /&gt;import javax.jms.MessageListener;&lt;BR /&gt;import javax.jms.TextMessage;&lt;BR /&gt;&lt;BR /&gt;import org.activiti.engine.ProcessEngine;&lt;BR /&gt;import org.slf4j.Logger;&lt;BR /&gt;import org.slf4j.LoggerFactory;&lt;BR /&gt;&lt;BR /&gt;@MessageDriven(activationConfig = {&lt;BR /&gt;&amp;nbsp; @ActivationConfigProperty(propertyName = "destination", propertyValue = "java:/jms/queue/activitiJobExecutor"),&lt;BR /&gt;&amp;nbsp; @ActivationConfigProperty(propertyName = "acknowledgeMode", propertyValue = "Auto-acknowledge"),&lt;BR /&gt;&amp;nbsp; @ActivationConfigProperty(propertyName = "destinationType", propertyValue = "javax.jms.Queue") })&lt;BR /&gt;public class JobExecutorBean implements MessageListener {&lt;BR /&gt;&lt;BR /&gt; protected static Logger log = LoggerFactory.getLogger(JobExecutorBean.class);&lt;BR /&gt;&lt;BR /&gt; @Inject&lt;BR /&gt; protected ProcessEngine processEngine;&lt;BR /&gt;&lt;BR /&gt; @Override&lt;BR /&gt; public void onMessage(Message message) {&lt;BR /&gt;&amp;nbsp; String jobId = getJobIdFromMessage(message);&lt;BR /&gt;&lt;BR /&gt;&amp;nbsp; if (jobId != null) {&lt;BR /&gt;&amp;nbsp;&amp;nbsp; processEngine.getManagementService().executeJob(jobId);&lt;BR /&gt;&amp;nbsp; }&lt;BR /&gt; }&lt;BR /&gt;&lt;BR /&gt; protected String getJobIdFromMessage(Message message) {&lt;BR /&gt;&amp;nbsp; if (message instanceof TextMessage) {&lt;BR /&gt;&amp;nbsp;&amp;nbsp; try {&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; TextMessage textMessage = (TextMessage) message;&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; log.debug("Recevied message over JMS: '{}'", textMessage.getText());&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; return textMessage.getText();&lt;BR /&gt;&amp;nbsp;&amp;nbsp; } catch (JMSException e) {&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; log.error("Error occured while reading JMS TextMessage", e);&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; return null;&lt;BR /&gt;&amp;nbsp;&amp;nbsp; }&lt;BR /&gt;&amp;nbsp; }&lt;BR /&gt;&lt;BR /&gt;&amp;nbsp; return null;&lt;BR /&gt; }&lt;BR /&gt;}&lt;BR /&gt;&lt;/CODE&gt;&lt;BR /&gt;&lt;SPAN&gt;The custom JobExecutor basically just connects to the JMS queue obtained via JNDI and posts the Job IDs to that queue in it's executeJobs() method. Basically the MDB replaces the class ExecutorJobsRunnable which DefaultJobExecutor uses to run jobs in it's thread pool. Both ExecutorJobsRunnable and the MDB rely on ExecuteJobsCmd() to do the rest &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt; Of course this is totally untested, but in case anybody has the same requirement, it might be helpful…&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Now let's take a serious look at fox platform ce where this is supposed to be all pretty &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, 20 Jul 2012 07:30:25 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/using-cdi-from-jobexecutor/m-p/102003#M70904</guid>
      <dc:creator>naag</dc:creator>
      <dc:date>2012-07-20T07:30:25Z</dc:date>
    </item>
    <item>
      <title>Re: Using CDI from JobExecutor</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/using-cdi-from-jobexecutor/m-p/102004#M70905</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Does this also work for timers? And auto acknowledge? Isn't that dangerous in case of failures?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 20 Jul 2012 07:54:11 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/using-cdi-from-jobexecutor/m-p/102004#M70905</guid>
      <dc:creator>ronald_van_kuij</dc:creator>
      <dc:date>2012-07-20T07:54:11Z</dc:date>
    </item>
    <item>
      <title>Re: Using CDI from JobExecutor</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/using-cdi-from-jobexecutor/m-p/102005#M70906</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I just tested it with timers, it works.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Of course you're right, it's pretty untested at the moment. For example JMS will, in our current configuration, try to deliver the message up to 10 times in case of a failure. By acknowledging manually and setting up JMS properly, I think the issues can be avoided. This was just a quick test to see if things work together in general.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;So yes, there are still some kinks and also it's still not 100% Java EE compatible because the JobExecutor still uses a Thread for AcquireJobsRunnable.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 20 Jul 2012 07:58:28 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/using-cdi-from-jobexecutor/m-p/102005#M70906</guid>
      <dc:creator>naag</dc:creator>
      <dc:date>2012-07-20T07:58:28Z</dc:date>
    </item>
    <item>
      <title>Re: Using CDI from JobExecutor</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/using-cdi-from-jobexecutor/m-p/102006#M70907</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi Naag.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;It is actually not that different from what we do in the fox platform enterprise edition. But there are quite some nuts and bults to figure out and it might even depend on the JBoss version you are using (see &lt;/SPAN&gt;&lt;A href="https://app.camunda.com/confluence/display/foxUserGuide/Install+fox+platform+on+JBoss+AS+7#InstallfoxplatformonJBossAS7-SupportedJBossASversions" rel="nofollow noopener noreferrer"&gt;https://app.camunda.com/confluence/display/foxUserGuide/Install+fox+platform+on+JBoss+AS+7#InstallfoxplatformonJBossAS7-SupportedJBossASversions&lt;/A&gt;&lt;SPAN&gt; for various bugs we are facing). We basically do the whole stuff in a Java EE 6 compliant way (JCA indeed), so we have the stuff ready for Glassfish and the rest as well. But unfortunately the EE parts of that story are not open source (but we deliver all sources to our customers), but let me know if it is interesting for you anyway.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Cheers&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Bernd&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 01 Aug 2012 16:28:57 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/using-cdi-from-jobexecutor/m-p/102006#M70907</guid>
      <dc:creator>bernd_ruecker</dc:creator>
      <dc:date>2012-08-01T16:28:57Z</dc:date>
    </item>
    <item>
      <title>Re: Using CDI from JobExecutor</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/using-cdi-from-jobexecutor/m-p/102007#M70908</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I'd be interested how your implementation behaves in respect to exclusive-jobs:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;does your custom job-executor (or maybe the activiti base class you extend - didn't check source yet) provide the (&lt;/SPAN&gt;&lt;A href="http://activiti.org/userguide/#exclusiveJobs" rel="nofollow noopener noreferrer"&gt;http://activiti.org/userguide/#exclusiveJobs&lt;/A&gt;&lt;SPAN&gt;) feature?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;i think that even if the your custom-job does exclusiveJobs, I'm afraid you may be run into problems, because you send async (jms) messages per jobId (means your impl actually does not support exclusive-jobs feature) - the application-server will typically process messages in parallel.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;so if I'm correct this could be solved with&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;a) ensure sequential processing of messages (which is actually bad imho)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;b) use advanced messaging-features (e.g. activemq's messagedestinations etc.)&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;did you address/solve this issue using jms/mdbs?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;besides that, the solution feels somehow hacky/(way too) complex to me (imho too much overhead) &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;jobexecutor with threadpool =&amp;gt; asynchronous jms messaging =&amp;gt; mdb&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;daniel&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 02 Aug 2012 22:26:25 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/using-cdi-from-jobexecutor/m-p/102007#M70908</guid>
      <dc:creator>dguggi</dc:creator>
      <dc:date>2012-08-02T22:26:25Z</dc:date>
    </item>
    <item>
      <title>Re: Using CDI from JobExecutor</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/using-cdi-from-jobexecutor/m-p/102008#M70909</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Nonono, no JMS at all. &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;JCA allows you to define your own endpoint interfaces. Our interface looks like this:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;CODE&gt;&lt;BR /&gt;/**&lt;BR /&gt; * Interface to be implemented by a MessageDriven bean handling the execution of&lt;BR /&gt; * a job.&lt;BR /&gt; * &lt;BR /&gt; * @author Daniel Meyer&lt;BR /&gt; * &lt;BR /&gt; */&lt;BR /&gt;public interface JobExecutionHandler {&lt;BR /&gt;&lt;BR /&gt;&amp;nbsp; public void executeJob(String jobId, CommandExecutor commandExecutor);&lt;BR /&gt;&lt;BR /&gt;}&lt;/CODE&gt;&lt;BR /&gt;&lt;SPAN&gt;Then we have one (1!) MDB deployed as part of the platform. &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;So what our JCA job executor does is, &lt;/SPAN&gt;&lt;BR /&gt;&lt;UL&gt;&lt;LI&gt;it uses a thread pool provided by the application server (JCA Work Manager = standardized &amp;amp; portable across vendors)&lt;/LI&gt;&lt;BR /&gt;&lt;LI&gt;the thread pool is used to schedule acquisitions (you can have multiple acquisitions, one acquisition serving one or more engines)&lt;/LI&gt;&lt;BR /&gt;&lt;LI&gt;the thread pool is used to execute jobs.&lt;/LI&gt;&lt;BR /&gt;&lt;LI&gt;executor threads invoke the MDB implementing the above shown interface in a *SYNCHRONOUS* way. (This behaves exactly as the activiti job executor with full support for exclusive jobs. I implemented exclusive Jobs and asynchronous continuations in activiti and wrote the documentation on it, so I should know, right?)&lt;/LI&gt;&lt;BR /&gt;&lt;LI&gt;the MDB runs the default activiti org.activiti.engine.impl.cmd.ExecuteJobsCmd&lt;/LI&gt;&lt;BR /&gt;&lt;LI&gt;our platform handles the "context switch" form the platform application into your process application transparently (this is an orthogonal concern).&lt;/LI&gt;&lt;BR /&gt;&lt;LI&gt;in your process you just write &amp;lt;serviceTask activiti:delegateExpression="${nameOfMyCDIBean}" /&amp;gt; and we make sure the thread calling your bean is a legal container thread being decorated with the correct context, behaving exactly as if some EJB inside your application would invoke that bean.&lt;/LI&gt;&lt;BR /&gt;&lt;LI&gt;our job executor implements the same interface as the activiti job executor (looks the same).&lt;/LI&gt;&lt;/UL&gt;&lt;SPAN&gt;The problems this solves:&lt;/SPAN&gt;&lt;BR /&gt;&lt;UL&gt;&lt;LI&gt;Resources can be configured in the application server, even @ runtime (you can add more threads at runtime)&lt;/LI&gt;&lt;BR /&gt;&lt;LI&gt;An MDB is a legal entry point to the Application server, meaning that your thread will be decorated with the right context by the application server. This includes security, the request context for your @RequestScoped CDI beans, Naming …&lt;/LI&gt;&lt;BR /&gt;&lt;LI&gt;If you have multiple process engines (some of our clients use 50+ for multi tenancy you can still have a singe, shared thread pool for these process engines. If you use the default activiti job executor you end up with something like 500 threads and 50 threads polling the database, your DBA will kill you)&lt;/LI&gt;&lt;BR /&gt;&lt;LI&gt;you can implement advanced strategies for load balancing, scheduling etc. This is something we will be working on heavily in the months to come.&lt;/LI&gt;&lt;/UL&gt;&lt;SPAN&gt;See:&lt;/SPAN&gt;&lt;BR /&gt;&lt;UL&gt;&lt;LI&gt;&lt;A href="https://app.camunda.com/confluence/display/foxUserGuide/Advanced+Job+Executor" rel="nofollow noopener noreferrer"&gt;https://app.camunda.com/confluence/display/foxUserGuide/Advanced+Job+Executor&lt;/A&gt;&lt;/LI&gt;&lt;BR /&gt;&lt;LI&gt;&lt;A href="https://app.camunda.com/confluence/display/foxUserGuide/Configuration+of+the+fox+platform#Configurationofthefoxplatform-JobExecutorandJobAcquisitionConfiguration" rel="nofollow noopener noreferrer"&gt;https://app.camunda.com/confluence/display/foxUserGuide/Configuration+of+the+fox+platform#Configurationofthefoxplatform-JobExecutorandJobAcquisitionConfiguration&lt;/A&gt;&lt;/LI&gt;&lt;BR /&gt;&lt;LI&gt;&lt;A href="https://app.camunda.com/confluence/display/foxUserGuide/Install+fox+platform+on+Glassfish+3.1#InstallfoxplatformonGlassfish31-ConfigurationviaAdministrationConsole" rel="nofollow noopener noreferrer"&gt;https://app.camunda.com/confluence/display/foxUserGuide/Install+fox+platform+on+Glassfish+3.1#InstallfoxplatformonGlassfish31-ConfigurationviaAdministrationConsole&lt;/A&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 03 Aug 2012 06:18:43 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/using-cdi-from-jobexecutor/m-p/102008#M70909</guid>
      <dc:creator>meyerd</dc:creator>
      <dc:date>2012-08-03T06:18:43Z</dc:date>
    </item>
    <item>
      <title>Re: Using CDI from JobExecutor</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/using-cdi-from-jobexecutor/m-p/102009#M70910</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;thank you daniel, for your detailed explanation! &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;this solutions sound like a really comprehensive solution (especially the "your dba will kill you" argument is convincing&amp;nbsp; &lt;img id="smileyvery-happy" class="emoticon emoticon-smileyvery-happy" src="https://connect.hyland.com/i/smilies/16x16_smiley-very-happy.png" alt="Smiley Very Happy" title="Smiley Very Happy" /&gt;)&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;daniel&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 03 Aug 2012 08:44:43 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/using-cdi-from-jobexecutor/m-p/102009#M70910</guid>
      <dc:creator>dguggi</dc:creator>
      <dc:date>2012-08-03T08:44:43Z</dc:date>
    </item>
    <item>
      <title>Re: Using CDI from JobExecutor</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/using-cdi-from-jobexecutor/m-p/102010#M70911</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;The argument is convincing, but…..&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;The current jobexecutor can also be improved to do a lot less polling… Honestly, the current implementation is suboptimal. In a poc I changed it once and got 500% more throughput if lots of async calls are used.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 04 Aug 2012 19:48:57 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/using-cdi-from-jobexecutor/m-p/102010#M70911</guid>
      <dc:creator>ronald_van_kuij</dc:creator>
      <dc:date>2012-08-04T19:48:57Z</dc:date>
    </item>
    <item>
      <title>Re: Using CDI from JobExecutor</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/using-cdi-from-jobexecutor/m-p/102011#M70912</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;hi!&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;what is exactly suboptimal in activiti's current implementation - we plan to use the jobexecutor with lots of async-continuations, so I'd be interested how to improve throughput.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;btw. are there any plans to optimize the jobexecutor referring to your poc?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;ty, daniel&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 06 Aug 2012 07:35:50 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/using-cdi-from-jobexecutor/m-p/102011#M70912</guid>
      <dc:creator>dguggi</dc:creator>
      <dc:date>2012-08-06T07:35:50Z</dc:date>
    </item>
    <item>
      <title>Re: Using CDI from JobExecutor</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/using-cdi-from-jobexecutor/m-p/102012#M70913</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;The jobexecutor polls the database for selecting jobs every second. Often (certainly if you have only one jobexecutor) the jobs will be pinned to this specific jobexecutor. Inserting the job is 1 query per job,&amp;nbsp; selecting jobs is one query and pinning the jobs is 1 query. If you assume the server that wrote the job will be the one executing it, you can 'pin' it immediately, reducing the results of the 'select jobs' statement and thus processing&amp;nbsp; and remove one 'update' statement per job.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;All this, and some smaller optimizations, resulted in a much higher troughput, at least in the case of not to complex async services. If the processing time of the services themselves is significantly higher than the database actions, your millage will be a lot less. &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Keep in mind that the jobexcutor was initially meant for timed things that you needed to process in the future. So in that respect, the implementation is not bad, not at all. It is just suboptimal for pure async things.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I do not know if I still have the code for this and if so, it will need to be cleaned up since it was also a trial to use JCA but that unfortunately stopped due to ending of the internal project.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 06 Aug 2012 08:58:20 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/using-cdi-from-jobexecutor/m-p/102012#M70913</guid>
      <dc:creator>ronald_van_kuij</dc:creator>
      <dc:date>2012-08-06T08:58:20Z</dc:date>
    </item>
    <item>
      <title>Re: Using CDI from JobExecutor</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/using-cdi-from-jobexecutor/m-p/102013#M70914</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi Ronald.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I think even the current open source implementation is a bit better than what you describe. And there is an optimization to give yourself a hint internally if a job is created on your note, no query needed. And especially in fox we even have improved the approach and we have a pretty good throughput &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Cheers Bernd&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 06 Aug 2012 19:29:13 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/using-cdi-from-jobexecutor/m-p/102013#M70914</guid>
      <dc:creator>bernd_ruecker</dc:creator>
      <dc:date>2012-08-06T19:29:13Z</dc:date>
    </item>
    <item>
      <title>Re: Using CDI from JobExecutor</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/using-cdi-from-jobexecutor/m-p/102014#M70915</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;The opensource version of the Fox JobExecutor? Cool… Will definately have a look then. We had some additional improvements to that helped troughput but I do not recall the details. It was never finished though…&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks though for mentioning. I read good things about Fox and since it was almost a year ago I gave it a try, I will do that again soon. &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Cheers,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Ronald&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 07 Aug 2012 00:11:03 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/using-cdi-from-jobexecutor/m-p/102014#M70915</guid>
      <dc:creator>ronald_van_kuij</dc:creator>
      <dc:date>2012-08-07T00:11:03Z</dc:date>
    </item>
    <item>
      <title>Re: Using CDI from JobExecutor</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/using-cdi-from-jobexecutor/m-p/102015#M70916</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;The coolest stuff is only in EE (but as EE customer you get all the sources). Sorry for that, but we have to keep some enterprise stuff to customers only, but that helps to keep the business model healthy and makes our open source engagement possible (currently we are developing with 5 people full time on Activiti/fox!).&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 07 Aug 2012 04:40:29 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/using-cdi-from-jobexecutor/m-p/102015#M70916</guid>
      <dc:creator>bernd_ruecker</dc:creator>
      <dc:date>2012-08-07T04:40:29Z</dc:date>
    </item>
    <item>
      <title>Re: Using CDI from JobExecutor</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/using-cdi-from-jobexecutor/m-p/102016#M70917</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I know, don't blame you, not at all…&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 07 Aug 2012 06:26:49 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/using-cdi-from-jobexecutor/m-p/102016#M70917</guid>
      <dc:creator>ronald_van_kuij</dc:creator>
      <dc:date>2012-08-07T06:26:49Z</dc:date>
    </item>
    <item>
      <title>Re: Using CDI from JobExecutor</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/using-cdi-from-jobexecutor/m-p/102017#M70918</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;can you describe how to 'pin' the job immediately?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 03 Aug 2014 15:40:09 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/using-cdi-from-jobexecutor/m-p/102017#M70918</guid>
      <dc:creator>mahavirj</dc:creator>
      <dc:date>2014-08-03T15:40:09Z</dc:date>
    </item>
  </channel>
</rss>

