geronimo-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From David Jencks <david_jen...@yahoo.com>
Subject Re: security constraint question
Date Tue, 22 Sep 2009 07:42:43 GMT
Hi Ben,

First of all, you appear to have replied to a message with questions  
on completely unrelated subjects.  In the future please start a new  
thread instead.

On Sep 21, 2009, at 8:33 PM, LiangBen wrote:

> Hi,Devs
>
> Recently, I am working on Geronimo WADI clustering but I have  
> encountered some problems when I configured the WADI over static  
> member configuration following the linkhttp://cwiki.apache.org/GMOxDOC22/wadi-clustering.html
>
> Steps:
> 1.Setup 2 nodes in the same physical workstation one is 8080 which  
> is the master node and another is 8090.
> 2.Change the module <module name="org.apache.geronimo.configs/wadi- 
> clustering/2.2-SNAPSHOT/car" in the config.xml  to
>
> NODE1 is like this:
> <module name="org.apache.geronimo.configs/wadi-clustering/2.2- 
> SNAPSHOT/car">
>         <gbean name="DefaultBackingStrategyFactory">
>             <attribute name="nbReplica">${ReplicaCount}</attribute>
>         </gbean>
>         <gbean name="DefaultDispatch erHolder">
>             <attribute name="endPointURI">${EndPointURI}</attribute>
>             <attribute name="clusterName">${WADIClusterName}</ 
> attribute>
>         </gbean>
>         <gbean name="org.apache.geronimo.configs/wadi-clustering/2.2- 
> SNAPSHOT/car?ServiceModule=org.apache.geronimo.configs/wadi- 
> clustering/2.2-SNAPSHOT/car,j2eeType=GBean,name=firstStaticMember"  
> gbeanInfo="org.apache.geronimo.clustering.wadi.WadiStaticMember">
>             <attribute  
> name="className">org.apache.catalina.tribes.membership.StaticMember</ 
> attribute>
>             <attribute name="port">4003</attribute>
>             <attribute name="securePort">-1</attribute>
>             <attribute name="domain">test-domain</attribute>
>             <attribute  
> name="UniqueId">0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0</attribute>
>             <attribute name="host">9.123.233.67</attribute>
>             <reference name="nextWadiStaticMember">
>                <pattern>
>                  <groupId>org.apache.geronimo.configs</groupId>
>                  <artifactId>wadi-clustering</artifactId>
>                  <version>2.2-SNAPSHOT</version>
>                  <type>car</type>
>                  <name>secondStaticMember</name>
>                </pattern>
>             </reference>
>
>         </gbean>
> </module>
>
>
> NODE2 is like this:
> <module name="org.apache.geronimo.configs/wadi-clustering/2.2- 
> SNAPSHOT/car" load="false">
>         <gbean name="DefaultBackingStrategyFactory">
>             <attribute name="nbReplica">${ReplicaCount}</attribute>
>         </gbean>
>         <gbean name="DefaultDispatcherHolder">
>             <attribute name="disableMCastService">tr ue</attribute>
>             <attribute name="receiverPort">4003</attribute>
>             <reference name="staticMember">
>                 <pattern>
>                     <groupId>org.apache.geronimo.configs</groupId>
>                     <artifactId>wadi-clustering</artifactId>
>                     <version>2.2-SNAPSHOT</version>
>                    ;  <type>car</type>
>                     <name>firstStaticMember</name>
>                 </pattern>
>             </reference>
>         </gbean>
>         <gbean name="org.apache.geronimo.configs/wadi-clustering/2.2- 
> SNAPSHOT/car?ServiceModule=org.apache.geronimo.configs/wadi- 
> clustering/2.2-SNAPSHOT/car,j2eeType=GBean,name=secondStaticMember"  
> gbeanInfo="org.apache.geronimo.clustering.wadi.WadiStaticMember">
>             <attribute  
> name="className">org.apache.catalina.tribes.membership.StaticMember</ 
> attribute>
>          ;    <attribute name="port">4001</attribute>
>             <attribute name="securePort">-1</attribute>
>             <attribute name="domain">test-domain</attribute>
>             <attribute  
> name="UniqueId">0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1</attribute>
>             <attribute name="host">9.123.233.67</attribute>
>             <reference name="nextWadiStaticMember"/>
>         </gbean>
>     </module>
>
>
> But when I start the module org.apache.geronimo.configs/wadi- 
> clustering/2.2-SNAPSHOT/car of the NODE 2 then I got a failure   
> which is Lifecycle operation failed. And the exceptions are
>
> org.apache.geronimo.kernel.config.LifecycleException: start of  
> org.apache.geronimo.configs/wadi-clustering/2.2-SNAPSHOT/car failed
>     at  
> org 
> .apache 
> .geronimo 
> .kernel 
> .config 
> .SimpleConfigurationManager 
> .startConfiguration(SimpleConfigurationManager.java:562)
>     at  
> org 
> .apache 
> .geronimo 
> .kernel 
> .config 
> .SimpleConfigurationManager 
> .startConfiguration(SimpleConfigurationManager.java:527)
>     at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>     at  
> sun 
> .reflect 
> .NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
>     at  
> sun 
> .reflect 
> .DelegatingMethodAccessorImpl 
> .invoke(DelegatingMethodAccessorImpl.java:37)
>     at java.lang.reflect.Method.invoke(Method.java:599)
>     at  
> org 
> .apache 
> .geronimo 
> .gbean 
> .runtime.ReflectionMethodInvoker.invoke(ReflectionMethodInvoker.java: 
> 34)
>     at  
> org 
> .apache 
> .geronimo.gbean.runtime.GBeanOperation.invoke(GBeanOperation.java:130)
>     at  
> org 
> .apache 
> .geronimo.gbean.runtime.GBeanInstance.invoke(GBeanInstance.java:815)
>     at  
> org.apache.geronimo.gbean.runtime.RawInvoker.invoke(RawInvoker.java: 
> 57)
>     at  
> org 
> .apache 
> .geronimo 
> .kernel.basic.RawOperationInvoker.invoke(RawOperationInvoker.java:35)
>     at  
> org 
> .apache 
> .geronimo 
> .kernel 
> .basic.ProxyMethodInterceptor.intercept(ProxyMethodInterceptor.java: 
> 96)
>     at org.apache.geronimo.kernel.config.EditableConfigurationManager 
> $$EnhancerByCGLIB$$79d07ec2.startConfiguration(<generated>)
>     at  
> org 
> .apache 
> .geronimo 
> .console 
> .configmanager 
> .ConfigManagerPortlet.processAction(ConfigManagerPortlet.java:157)
>     at org.apache.pluto.core.PortletServle  
> t.dispatch(PortletServlet.java:218)
>     at  
> org.apache.pluto.core.PortletServlet.doGet(PortletServlet.java:139)
>     at javax.servlet.http.HttpServlet.service(HttpServlet.java:693)
>     at javax.servlet.http.HttpServlet.service(HttpServlet.java:806)
>     at  
> org 
> .apache 
> .catalina 
> .core 
> .ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java: 
> 290)
>     at  
> org 
> .apache 
> .catalina 
> .core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>     at  
> org 
> .apache 
> .catalina 
> .core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:646)
>     at  
> org 
> .apache 
> .catalina 
> .core.ApplicationDispatcher.doInclude(ApplicationDispatcher.java:551)
>     at  
> org 
> .apache 
> .catalina 
> .core.ApplicationDispatcher.include(ApplicationDispatcher.java:488)
>     at  
> org 
> .apache 
> .pluto 
> .core 
> .DefaultPortletInvokerService.invoke(DefaultPortletInvokerService.j  
> ava:167)
>     at  
> org 
> .apache 
> .pluto 
> .core 
> .DefaultPortletInvokerService 
> .action(DefaultPortletInvokerService.java:85)
>     at  
> org 
> .apache 
> .pluto.core.PortletContainerImpl.doAction(PortletContainerImpl.java: 
> 217)
>     at  
> org 
> .apache 
> .pluto.driver.PortalDriverServlet.doGet(PortalDriverServlet.java:121)
>     at javax.servlet.http.HttpServlet.service(HttpServlet.java:693)
>     at javax.servlet.http.HttpServlet.service(HttpServlet.java:806)
>     at  
> org 
> .apache 
> .catalina 
> .core 
> .ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java: 
> 290)
>     at  
> org 
> .apache 
> .catalina 
> .core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>     at  
> org 
> .apache 
> .geronimo 
> .console 
> .filter.PlutoURLRebuildFilter.doFilter(PlutoURLRebuildFilter.java:48)
>     at  
> org 
> .apache 
> .catalina 
> .core 
> .ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.j  
> ava:235)
>     at  
> org 
> .apache 
> .catalina 
> .core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>     at  
> org 
> .apache 
> .geronimo.console.filter.XSSXSRFFilter.doFilter(XSSXSRFFilter.java: 
> 125)
>     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: 
> 233)
>     at  
> org 
> .apache 
> .catalina.core.StandardContextValve.invoke(StandardContextValve.java: 
> 191)
>     at  
> org 
> .apache 
> .geronimo.tomcat.security.SecurityValve.invoke(SecurityValve.java:88)
>     at  
> org 
> .apache 
> .geronimo 
> .tomcat 
> .security.jacc.JACCSecurityValve.invoke(JACCSecurityValve.java:54)
>     at org.apache.geronimo.tomcat.GeronimoStandardContext$Sys  
> temMethodValve.invoke(GeronimoStandardContext.java:420)
>     at  
> org 
> .apache 
> .geronimo 
> .tomcat 
> .valve.GeronimoBeforeAfterValve.invoke(GeronimoBeforeAfterValve.java: 
> 47)
>     at  
> org 
> .apache 
> .catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
>     at  
> org 
> .apache 
> .catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
>     at  
> org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java: 
> 567)
>     at  
> org 
> .apache 
> .catalina.core.StandardEngineValve.invoke(StandardEngineValve.java: 
> 109)
>     at  
> org 
> .apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java: 
> 293)
>     at  
> org 
> .apache.coyote.http11.Http11Processor.process(Http11Processor.java: 
> 849)
>     at org.apache.coyote.http11.Http11Protocol 
> $Http11ConnectionHandler.process(Http11Protocol.java:583)
>     at org.apache.tomcat.util.net.JIoEndpoint$SocketProc  
> essor.run(JIoEndpoint.java:361)
>     at org.apache.geronimo.pool.ThreadPool$1.run(ThreadPool.java:214)
>     at org.apache.geronimo.pool.ThreadPool 
> $ContextClassLoaderRunnable.run(ThreadPool.java:344)
>     at java.util.concurrent.ThreadPoolExecutor 
> $Worker.runTask(ThreadPoolExecutor.java:896)
>     at java.util.concurrent.ThreadPoolExecutor 
> $Worker.run(ThreadPoolExecutor.java:918)
>     at java.lang.Thread.run(Thread.java:735)
> Caused by: org.apache.geronimo.kernel.config.InvalidConfigException:  
> Unable to resolve reference "staticMember" in gbean  
> org.apache.geronimo.configs/wadi-clustering/2.2-SNAPSHOT/car? 
> ServiceModule=org.apache.geronimo.configs/wadi-clustering/2.2- 
> SNAPSHOT/car,j2eeType=GBean,name=DefaultDispatcherHolder to a gbean  
> matching the pattern [org.apache.geronimo.configs/wadi-clustering/ 
> 2.2-SNAPSHOT/car?name=firstStaticMember#]
>     at org.apache.geronimo.kernel.conf  
> ig.ConfigurationUtil.preprocessGBeanData(ConfigurationUtil.java:380)
>     at  
> org 
> .apache 
> .geronimo 
> .kernel 
> .config 
> .ConfigurationUtil.startConfigurationGBeans(ConfigurationUtil.java: 
> 438)
>     at  
> org 
> .apache 
> .geronimo 
> .kernel 
> .config 
> .KernelConfigurationManager.start(KernelConfigurationManager.java:190)
>     at  
> org 
> .apache 
> .geronimo 
> .kernel 
> .config 
> .SimpleConfigurationManager 
> .startConfiguration(SimpleConfigurationManager.java:546)
>     ... 55 more
> Caused by: org.apache.geronimo.kernel.GBeanNotFoundException: No  
> matches for referencePatterns: [org.apache.geronimo.configs/wadi- 
> clustering/2.2-SNAPSHOT/car?name=firstStaticMember#]
>     at  
> org 
> .apache 
> .geronimo 
> .kernel.config.Configuration.findGBeanData(Configuration.java:688)
>     at  
> org 
> .apache 
> .geronimo.kernel.config.Configuration.findGBean(Configuration.java: 
> 661)
>     at org.apache.geronimo.kernel.config.Configuration.findGBea  
> n(Configuration.java:656)
>     at  
> org 
> .apache 
> .geronimo 
> .kernel 
> .config.ConfigurationUtil.preprocessGBeanData(ConfigurationUtil.java: 
> 375)
>     ... 58 more
>
>

The documentation is not entirely clear to me, but:

1. GBean references only work within the VM geronimo is running in.   
So in Node1, all the references need to be to gbeans deployed in  
node1, and in node2, all the references need to be to gbeans deployed  
in node2.  In Node1 your firstStaticMember gbean refers to a  
secondStaticMember with is not deployed on node1.  Similarly, on node2  
DefaultDispatcherHolder has a reference to a firstStaticMember but the  
gbean is called secondStaticMember.  This is the immediate cause of  
the exception.

2. the documentation is not at all clear but you might need a  
staticMember gbean for the node itself, i.e. 2 staticMember gbeans on  
each node.

Hope this helps
david jencks

> I really need your help to figure out the errors.
> Thanks
>
> Ben
>
>
> 与任何您希望的人分享您的回忆。 任何您希望的人。


Mime
View raw message