<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html>
<body link="#355491" alink="#4262a1" vlink="#355491" style="background: #e2e2e2; margin: 0; padding: 20px;">

<div>
        <table cellpadding="0" bgcolor="#FFFFFF" border="0" cellspacing="0" style="border: 1px solid #dadada; margin-bottom: 30px; width: 100%; -moz-border-radius: 6px; -webkit-border-radius: 6px;">
                <tbody>
                        <tr>

                                <td>

                                        <table border="0" cellpadding="0" cellspacing="0" bgcolor="#FFFFFF" style="border: solid 2px #ccc; background: #dadada; width: 100%; -moz-border-radius: 6px; -webkit-border-radius: 6px;">
                                                <tbody>
                                                        <tr>
                                                                <td bgcolor="#000000" valign="middle" height="58px" style="border-bottom: 1px solid #ccc; padding: 20px; -moz-border-radius-topleft: 3px; -moz-border-radius-topright: 3px; -webkit-border-top-right-radius: 5px; -webkit-border-top-left-radius: 5px;">
                                                                        <h1 style="color: #333333; font: bold 22px Arial, Helvetica, sans-serif; margin: 0; display: block !important;">
                                                                        <!-- To have a header image/logo replace the name below with your img tag -->
                                                                        <!-- Email clients will render the images when the message is read so any image -->
                                                                        <!-- must be made available on a public server, so that all recipients can load the image. -->
                                                                        <a href="http://community.jboss.org/index.jspa" style="text-decoration: none; color: #E1E1E1">JBoss Community</a></h1>
                                                                </td>

                                                        </tr>
                                                        <tr>
                                                                <td bgcolor="#FFFFFF" style="font: normal 12px Arial, Helvetica, sans-serif; color:#333333; padding: 20px;  -moz-border-radius-bottomleft: 4px; -moz-border-radius-bottomright: 4px; -webkit-border-bottom-right-radius: 5px; -webkit-border-bottom-left-radius: 5px;"><h3 style="margin: 10px 0 5px; font-size: 17px; font-weight: normal;">
    JBPM 5.1 Final Release with jboss-5.1.0.GA embedded server - Users/Roles/Groups Management
</h3>
<span style="margin-bottom: 10px;">
    created by <a href="http://community.jboss.org/people/priyakpandey">priyakpandey</a> in <i>jBPM</i> - <a href="http://community.jboss.org/message/611989#611989">View the full discussion</a>
</span>
<hr style="margin: 20px 0; border: none; background-color: #dadada; height: 1px;">

<div class="jive-rendered-content"><p>Hi,</p><p>I am using the JBPM 5.1 Final version which is released recently for one of the customer which is supposed to goLive very soon.</p><p>I hve few important things which is difficult to handle,</p><p>1. org.jbpm.DemoTaskService - loads all the users and the groups present in the LoadUsers.mvel and LoadGroups.mvel in the TaskServiceSession. </p><p>&#160;&#160;&#160;&#160; 1.1. Practically this is going to be huge performance hit incase of even small size organization with 100 - 150 user/groups.&#160; </p><p>&#160;&#160;&#160;&#160; 1.2. Is there any way / flag by which the user details of only that particular user is loaded who is accessing the server? </p><p>&#160;&#160;&#160;&#160; 1.3 Why it needs to load all the users/groups in the session?</p><p>&#160;&#160;&#160;&#160;&#160; 1.4 It is currently loads .mvel file to load users/groups? Is there any other version of this class which accees DB?</p><p>&#160;&#160;&#160;&#160;&#160; 1.5 When i comment loading of users and groups and try to start a process, it gives following error in the jboss-5.1.0.GA\server\default\log\server.log. It creates the process instance but task is not created.</p><p>&#160;&#160; </p><table><tbody><tr><td style=";">2011-06-25 20:34:24,351 INFO&#160; [STDOUT] (http-localhost%2F127.0.0.1-8080-1) ERROR 25-06 20:34:24,350 (RepositoryServlet.java:doAuthorizedAction:78)</td><td style=";"> </td></tr></tbody></table><p>java.lang.NullPointerException</p><table><tbody><tr><td style=";"><br/></td><td style=";">at java.io.OutputStream.write(OutputStream.java:58)</td></tr><tr><td style=";"><br/></td><td style=";">at org.drools.guvnor.server.files.FileManagerUtils.loadBinaryPackage(FileManagerUtils.java:188)</td></tr><tr><td style=";"><br/></td><td style=";">at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)</td></tr><tr><td style=";"><br/></td><td style=";">at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)</td></tr><tr><td style=";"><br/></td><td style=";">at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)</td></tr><tr><td style=";"><br/></td><td style=";">at java.lang.reflect.Method.invoke(Method.java:597)</td></tr><tr><td style=";"><br/></td><td style=";">at org.jboss.seam.util.Reflections.invoke(Reflections.java:22)</td></tr><tr><td style=";"><br/></td><td style=";">at org.jboss.seam.intercept.RootInvocationContext.proceed(RootInvocationContext.java:31)</td></tr><tr><td style=";"><br/></td><td style=";">at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:56)</td></tr><tr><td style=";"><br/></td><td style=";">at org.jboss.seam.transaction.RollbackInterceptor.aroundInvoke(RollbackInterceptor.java:28)</td></tr><tr><td style=";"><br/></td><td style=";">at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:68)</td></tr><tr><td style=";"><br/></td><td style=";">at org.jboss.seam.core.BijectionInterceptor.aroundInvoke(BijectionInterceptor.java:77)</td></tr><tr><td style=";"><br/></td><td style=";">at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:68)</td></tr><tr><td style=";"><br/></td><td style=";">at org.jboss.seam.core.MethodContextInterceptor.aroundInvoke(MethodContextInterceptor.java:44)</td></tr><tr><td style=";"><br/></td><td style=";">at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:68)</td></tr><tr><td style=";"><br/></td><td style=";">at org.jboss.seam.security.SecurityInterceptor.aroundInvoke(SecurityInterceptor.java:157)</td></tr><tr><td style=";"><br/></td><td style=";">at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:68)</td></tr><tr><td style=";"><br/></td><td style=";">at org.jboss.seam.intercept.RootInterceptor.invoke(RootInterceptor.java:107)</td></tr><tr><td style=";"><br/></td><td style=";">at org.jboss.seam.intercept.JavaBeanInterceptor.interceptInvocation(JavaBeanInterceptor.java:166)</td></tr><tr><td style=";"><br/></td><td style=";">at org.jboss.seam.intercept.JavaBeanInterceptor.invoke(JavaBeanInterceptor.java:102)</td></tr><tr><td style=";"><br/></td><td style=";">at org.drools.guvnor.server.files.FileManagerUtils_$$_javassist_3.loadBinaryPackage(FileManagerUtils_$$_javassist_3.java)</td></tr><tr><td style=";"><br/></td><td style=";">at org.drools.guvnor.server.files.PackageDeploymentServlet$1.execute(PackageDeploymentServlet.java:269)</td></tr><tr><td style=";"><br/></td><td style=";">at org.drools.guvnor.server.files.RepositoryServlet.doAuthorizedAction(RepositoryServlet.java:76)</td></tr><tr><td style=";"><br/></td><td style=";">at org.drools.guvnor.server.files.PackageDeploymentServlet.doGet(PackageDeploymentServlet.java:135)</td></tr><tr><td style=";"><br/></td><td style=";">at javax.servlet.http.HttpServlet.service(HttpServlet.java:625)</td></tr><tr><td style=";"><br/></td><td style=";">at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)</td></tr><tr><td style=";"><br/></td><td style=";">at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)</td></tr><tr><td style=";"><br/></td><td style=";">at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)</td></tr><tr><td style=";"><br/></td><td style=";">at org.jboss.seam.web.ContextFilter$1.process(ContextFilter.java:42)</td></tr><tr><td style=";"><br/></td><td style=";">at org.jboss.seam.servlet.ContextualHttpServletRequest.run(ContextualHttpServletRequest.java:53)</td></tr><tr><td style=";"><br/></td><td style=";">at org.jboss.seam.web.ContextFilter.doFilter(ContextFilter.java:37)</td></tr><tr><td style=";"><br/></td><td style=";">at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)</td></tr><tr><td style=";"><br/></td><td style=";">at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)</td></tr><tr><td style=";"><br/></td><td style=";">at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)</td></tr><tr><td style=";"><br/></td><td style=";">at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)</td></tr><tr><td style=";"><br/></td><td style=";">at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)</td></tr><tr><td style=";"><br/></td><td style=";">at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:235)</td></tr><tr><td style=";"><br/></td><td style=";">at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)</td></tr><tr><td style=";"><br/></td><td style=";">at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:190)</td></tr><tr><td style=";"><br/></td><td style=";">at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:92)</td></tr><tr><td style=";"><br/></td><td style=";">at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(SecurityContextEstablishmentValve.java:126)</td></tr><tr><td style=";"><br/></td><td style=";">at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:70)</td></tr><tr><td style=";"><br/></td><td style=";">at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)</td></tr><tr><td style=";"><br/></td><td style=";">at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)</td></tr><tr><td style=";"><br/></td><td style=";">at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)</td></tr><tr><td style=";"><br/></td><td style=";">at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)</td></tr><tr><td style=";"><br/></td><td style=";">at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:330)</td></tr><tr><td style=";"><br/></td><td style=";">at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:829)</td></tr><tr><td style=";"><br/></td><td style=";">at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:598)</td></tr><tr><td style=";"><br/></td><td style=";">at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)</td></tr><tr><td style=";"><br/></td><td style=";"><p>at java.lang.Thread.run(Thread.java:662)</p></td></tr></tbody></table><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>2. org.jbpm.integration.console.TaskManagement - loads user roles from Roles.properties</p><p>&#160;&#160;&#160; 2.1 Loads all the users roles and in 'Map&lt;String, List&lt;String&gt;&gt; groupListMap'. Again, Why all the users roles are loaded on startup?</p><p>&#160;&#160;&#160; 2.2 Is there any option to defer the loading until it is required?</p><p>&#160;&#160;&#160; 2.3&#160; Is there any option to point to DB instead of property file?</p><p>&#160;&#160;&#160; 2.4 When I change the user role to load for the particular user then task is getting created but it throws exception in the server.log.</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>I have noticed that whatever changes i need to make, i have to go through the series of classes modify, recompile and then make it work. Is there any pluggable way where-in i just need to implement the interface and specify the implementation class in the configuration file and JBPM should work.</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>Any help on this would be appreciated as this is critical and we need to deliver it to a client.</p><p>Thank you in advance.</p></div>

<div style="background-color: #f4f4f4; padding: 10px; margin-top: 20px;">
    <p style="margin: 0;">Reply to this message by <a href="http://community.jboss.org/message/611989#611989">going to Community</a></p>
        <p style="margin: 0;">Start a new discussion in jBPM at <a href="http://community.jboss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2034">Community</a></p>
</div></td>
                        </tr>
                    </tbody>
                </table>


                </td>
            </tr>
        </tbody>
    </table>

</div>

</body>
</html>