[JBoss jBPM] - Pitfalls when using Groups with the same name
by dleerob
Hi,
There are a few pitfalls we are facing when we have groups with the same name (we may have groups with the same name, because they may be department names from different companies).
1) When using the IdentitySession method getGroupByName(String), it will only return the name of one group. What if we have multiple groups with the same name?
2) In the jbpm-console, when adding a user to a group, you can only type in the group name, but how does the console know which group to add the user membership to if there are two groups with the same name?
Are these just current limitations? How have others handled this?
I'm guessing we will need to develop our own way to handle these situations? i.e not using the getGroupByName method, but rather create your own hibernate query or use other API methods and filter the resulting lists accordingly, and using your own webapp and the Jbpm API's to add user memberships to groups?
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4099743#4099743
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4099743
18Â years, 6Â months
[Installation, Configuration & DEPLOYMENT] - Problems with installation and deployment of jboss aop
by abdujaparov
Hi I'm been trying for a week to run a web service with jboss aop on jboss, but I've a lot of problem.
1)I've followed the installation guide of jboss 1.5.6 on jboss4.2.1 for jdk5.0. I've copied the directory "C:\jboss-aop_1.5.6.GA\jboss-40-install\jboss-aop-jdk50.deployer" in the directory "C:\jboss-4.2.1.GA\server\default\deploy\jboss-aop-jdk50.deployer";
2) I've removed the file common-softvaluehashmap.jar from "C:\jboss-4.2.1.GA\server\default\deploy\jboss-aop-jdk50.deployer";
3)I've moved the file javassist.jar from "C:\jboss-4.2.1.GA\server\default\deploy\jboss-aop-jdk50.deployer" to C:\jboss-4.2.1.GA\server\default\lib;
4) I've setted "true" and "true" in the file "C:\jboss-4.2.1.GA\server\default\deploy\jboss-aop-jdk50.deployer\META-INF\jboss-service.xml"
5) I've copied the file pluggable-instrumentor.jar of the directory "C:\jboss-aop_1.5.6.GA\lib-50" to "C:\jboss-4.2.1.GA\bin" ant I've added the following line in the run.bat : "set JAVA_OPTS=%JAVA_OPTS% -Dprogram.name=%PROGNAME% -javaagent:pluggable-instrumentor.jar";
6) I've created a *.aop file with this structure:
*directory META-INF with this jboss-aop.xml:
Code:
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
*directory servizio with the class:
-ServizioInterceptor.class (My interceptor)
-Servizio$somma_N33762007832218886856.class (class generated by jboss aop ide in eclipse)
7)The war file of my web service (in this war I've included also the fille:
Servizio$somma_N33762007832218886856.class
When I start jboss I've not errors but when I invoke a method of the web service jboss print this error:
Code:
09:07:38,363 ERROR [[Servizio]] Servlet.service() for servlet Servizio threw exception
java.lang.IllegalArgumentException
at sun.reflect.UnsafeStaticObjectFieldAccessorImpl.set(UnsafeStaticObjectFieldAccessorImpl.java:61)
at java.lang.reflect.Field.set(Field.java:656)
at org.jboss.aop.ClassAdvisor.initializeMethodChain(ClassAdvisor.java:464)
at org.jboss.aop.ClassAdvisor.createInterceptorChains(ClassAdvisor.java:594)
at org.jboss.aop.ClassAdvisor.access$300(ClassAdvisor.java:82)
at org.jboss.aop.ClassAdvisor$1.run(ClassAdvisor.java:299)
at java.security.AccessController.doPrivileged(Native Method)
at org.jboss.aop.ClassAdvisor.attachClass(ClassAdvisor.java:271)
at org.jboss.aop.AspectManager.initialiseClassAdvisor(AspectManager.java:591)
at org.jboss.aop.AspectManager.getAdvisor(AspectManager.java:579)
at servizio.Servizio.(Servizio.java)
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java
:27)
at java.lang.reflect.Constructor.newInstance(Constructor.java:494)
at java.lang.Class.newInstance0(Class.java:350)
at java.lang.Class.newInstance(Class.java:303)
at org.jboss.wsf.container.jboss42.DefaultInvocationHandler.getTargetBean(DefaultInvocationHandler.
java:75)
at org.jboss.wsf.container.jboss42.DefaultInvocationHandler.invoke(DefaultInvocationHandler.java:90
)
at org.jboss.ws.core.server.ServiceEndpointInvoker.invoke(ServiceEndpointInvoker.java:220)
at org.jboss.wsf.stack.jbws.RequestHandlerImpl.processRequest(RequestHandlerImpl.java:408)
at org.jboss.wsf.stack.jbws.RequestHandlerImpl.handleRequest(RequestHandlerImpl.java:272)
at org.jboss.wsf.stack.jbws.RequestHandlerImpl.doPost(RequestHandlerImpl.java:189)
at org.jboss.wsf.stack.jbws.RequestHandlerImpl.handleHttpRequest(RequestHandlerImpl.java:122)
at org.jboss.wsf.stack.jbws.EndpointServlet.service(EndpointServlet.java:84)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290
)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235
)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:230)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:179)
at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:84)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:104)
at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:157)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:241)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:580)
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
at java.lang.Thread.run(Thread.java:595)
What does this error mean? How can I resolve?
I've configured correctly jbossaop on jboss?
But above all, how can I run my aop on my web service? This last question it's the most important because without aop run I cannot work on my project and I'm been blocking on these errors for a week.
Please help me, thanks.
Bye Bye.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4099740#4099740
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4099740
18Â years, 6Â months
[JBoss Seam] - session refresh
by panky_p
Hi,
I am trying to add a page in my demo application for that my bean contains
| @Entity
| @Scope(SESSION)
| @Name("myPage")
| @Table(name="my_page")
| public class MyPage implements Serializable {
|
| @Id @GeneratedValue
| @Column(name="page_id")
| private Integer pageId;
|
and
@Stateful
| @Scope(ScopeType.CONVERSATION)
| @Name("surveyManager")
| public class PageAction implements PageManager {
|
| @In(required=true)
| @Out(required=true)
| private MyPage myPage;
| @In(create=true)
| private EntityManager em;
| .......
|
|
and to add page i am using
| public String add(MyPage myPage) {
| try {
| em.persist(myPage);
| em.flush();
| }catch (Exception ex){ }
| }
When I try to add first page it works fine but when I try to add another page It gives error because of session object it brings old pageId and not the new one I also tried it by making @Stateless but still it wont work, but I need the session should remain and pageId should be new.
Is it possible??
Any hints???
Thanks
panky_p
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4099739#4099739
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4099739
18Â years, 6Â months