|
From: Winterfeldt, D. \(IT\) <Dav...@mo...> - 2007-05-08 17:23:22
|
I'm not sure if this would have been more appropriate for the user list or not. If it is, please let me know and I will resend to that list. I'm using version Spring 2.0.3. I'd like to delegate parsing from within a custom parser back to the default Spring beans parsing to leverage default Spring functionality. =20 <mesh:process-remote id=3D"testRemote"> <property name=3D"sender"><ref = local=3D"helloServiceSender"/></property> </mesh:process-remote> =20 When I call parserContext.getDelegate().parseCustomElement(element, builder.getBeanDefinition()) in my custom parser, I get an exception. org.springframework.beans.factory.parsing.BeanDefinitionParsingException : Configuration problem: Unable to locate NamespaceHandler for namespace [http://www.springframework.org/schema/beans] Offending resource: class path resource [com/ms/bfservices/mesh/controller/config/refs-applicationContext.xml] =20 When I debug this, the default namespace for Spring isn't in DefaultNamepsaceHandler.handlerMappings (below is it's contents). I would think at this point that even if the default namespace isn't registered, it would still pass the default handler back.=20 DefaultNamespaceHandler public NamespaceHandler resolve(String namespaceUri) { return (NamespaceHandler) this.handlerMappings.get(namespaceUri); } =20 Contents of handlerMappings {http://www.springframework.org/schema/jee=3Dorg.springframework.ejb.conf= i g.JeeNamespaceHandler@d3ade7 <http://www.springframework.org/schema/jee=3Dorg.springframework.ejb.conf= i g.JeeNamespaceHandler@d3ade7>=20 =20 http://www.springframework.org/schema/util=3Dorg.springframework.beans.fa= c tory.xml.UtilNamespaceHandler@13e4a5a <http://www.springframework.org/schema/util=3Dorg.springframework.beans.f= a ctory.xml.UtilNamespaceHandler@13e4a5a>=20 =20 http://www.springmodules.org/validation/bean/validator=3Dorg.springmodule= s .validation.bean.conf.namespace.ValidatorNamespaceHandler@8390b0 <http://www.springmodules.org/validation/bean/validator=3Dorg.springmodul= e s.validation.bean.conf.namespace.ValidatorNamespaceHandler@8390b0>=20 =20 http://www.springframework.org/schema/aop=3Dorg.springframework.aop.confi= g .AopNamespaceHandler@19050a0 <http://www.springframework.org/schema/aop=3Dorg.springframework.aop.conf= i g.AopNamespaceHandler@19050a0>=20 =20 http://www.morganstanley.com/schema/bfservices/mesh=3Dcom.ms.bfservices.m= e sh.beandef.MeshNameSpaceHandler@ec898a <http://www.morganstanley.com/schema/bfservices/mesh=3Dcom.ms.bfservices.= m esh.beandef.MeshNameSpaceHandler@ec898a>=20 =20 http://www.springframework.org/schema/tx=3Dorg.springframework.transactio= n .config.TxNamespaceHandler@13a0212 <http://www.springframework.org/schema/tx=3Dorg.springframework.transacti= o n.config.TxNamespaceHandler@13a0212>=20 =20 http://www.springframework.org/schema/p=3Dorg.springframework.beans.facto= r y.xml.SimplePropertyNamespaceHandler@15e0c2b <http://www.springframework.org/schema/p=3Dorg.springframework.beans.fact= o ry.xml.SimplePropertyNamespaceHandler@15e0c2b> } =20 Thanks for any help. David -------------------------------------------------------- NOTICE: If received in error, please destroy and notify sender. Sender = does not intend to waive confidentiality or privilege. Use of this email = is prohibited when received in error. |