[jboss-dev-forums] [Design of POJO Server] - Re: Deploying ValidatorFactory

stan.silvert@jboss.com do-not-reply at jboss.com
Mon Aug 17 16:16:31 EDT 2009


"wolfc" wrote : You can't bind in java:comp, because you haven't established the right context. (You need to know the component and establish it currently via ENCFactory.pushContextId(id). It's going to change into something like ENCFactory.pushComponent(component).)
  | public String createName(DeploymentUnit unit, ValidatorFactory factory)
  |   | {
  |   |    return "java:comp/env/" + unit.getSimpleName(); // TODO - fix this
  |   | }
  | You are probably better off binding it into global JNDI.
  | 
  | Another way which I'm looking into (for EJB3) is binding an ObjectFactory which starts the (on-demand) MC bean on lookup. The binding itself isn't a performance issue.
  | 
  | For the dependency something must supply jndi:name though. Or the bean name which does the binding should come from a resolver.
JSF requires that a VF reference be put into application scope.  Because I don't yet have a JSFDeployer, I do this in our JSF ServletContextListener.  The only way I can do it is to create the VF myself or get it from JNDI.

So where are we with the JNDI part?

Stan

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

Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4250016



More information about the jboss-dev-forums mailing list