Sorry for annoying, but I had no luck since yet )-:

here's what I have done:


  | testportal.sar/META-INF/jboss-service.xml
  | 
  | <server>
  |     <mbean code="de.ameo.TestPortalCommandFactory"
  |             name="portal:commandFactory=SomeTestPortal" xmbean-dd=""
  |             
xmbean-code="org.jboss.portal.jems.as.system.JBossServiceModelMBean">
  |             <xmbean />
  |             <depends optional-attribute-name="Container"
  |                     proxy-type="attribute">
  |                     portal:container=PortalObject
  |             </depends>
  |     </mbean>
  | 
  | </server>
  | 


  | The factory:
  | public class TestPortalCommandFactory extends AbstractCommandFactory {
  | 
  |     
  |        private PortalObjectContainer container;
  | 
  |        public PortalObjectContainer getContainer()
  |        {
  |           return container;
  |        }
  | 
  |        public void setContainer(PortalObjectContainer container)
  |        {
  |           this.container = container;
  |        }
  | 
  |     public ControllerCommand doMapping(ControllerContext controllerContext,
  |                     ServerInvocation invocation, String host, String 
contextPath,
  |                     String requestPath) {
  | 
  |             Portal portal = (Portal) 
container.getContext().getPortal("testportal");
  |      
  |             if (portal == null) {
  |                     throw new IllegalStateException("Default portal does 
not exist");
  |             }
  |             Page page = portal.getPage("startpage");
  |             if (page == null) { 
  |                     throw new IllegalStateException("Default page does not 
exist");
  |             }
  |             PortalObjectId id = page.getId();
  |             return new ViewPageCommand(id);
  | 
  |     }
  | }
  | 

Nothing happens. The factory is not invoked after login. During debugging I 
cannot see some invokation of DefaultCommandPortalFactory, which should call my 
TestPortalCommandFactory. Although in the JMX console I can see that the 
factory is registerd. What I'm doing wrong ? 

greetings,
ameo

View the original post : 
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4111182#4111182

Reply to the post : 
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4111182
_______________________________________________
jboss-user mailing list
[email protected]
https://lists.jboss.org/mailman/listinfo/jboss-user

Reply via email to