The problem here is that I more or less rewrote the relevant code here for 2.2. So now I will have to grab a 2.1.4 tree and see if I cannot concoct a fix for you. Just this instant, the entire ASF svn server is out celebrating presidents' day, so it won't happen for a few days.
The lack of the @WebService could result in failing to set some things up. On Mon, Feb 16, 2009 at 2:38 PM, relphie <[email protected]> wrote: > > > So I created a simple test case, and it passed ... > I double checked, and I had not annotated the interface with @WebService > After adding that, it failed with the namespace message in both 2.1.3 and > 2.1.4 > Then, I changed to cxf 2.2, and it passed (i.e. no null pointer message). > > Anyway, here it is: https://issues.apache.org/jira/browse/CXF-2044 > > > > bimargulies wrote: >> >> Dan fixed it on the trunk and merged it down, so that's not an issue. >> >> Well, I thought I'd propagated some of the examples of custom type >> mapping from the unit tests to the samples, but no such luck. >> >> Somehow, you've managed to get the code to call getMinOccurs without >> ever call getTypeInfo. I could patch the obvious here, but I'd rather >> have a test case to wrestle with. >> >> >> Can you make a JIRA with attached code? If not, I'll eventually >> reconstruct from your email. >> >> On Mon, Feb 16, 2009 at 1:27 PM, relphie <[email protected]> wrote: >>> >>> >>> FYI, i think you might need to copy this fix into trunk: >>> http://www.nabble.com/After-updating-to-2.1.4:-No-DestinationFactory-was-found-for-the-namespace-http:--schemas.xmlsoap.org-soap-http-td21952242.html >>> >>> With 2.2-SNAPSHOT, I get a null pointer, something wrong with my BeanType >>> config? >>> >>> Caused by: java.lang.NullPointerException >>> at >>> org.apache.cxf.aegis.type.basic.BeanType.getMinOccurs(BeanType.java:593) >>> at >>> org.apache.cxf.aegis.databinding.AegisDatabinding.initializeMessage(AegisDatabinding.java:351) >>> at >>> org.apache.cxf.aegis.databinding.AegisDatabinding.initializeOperation(AegisDatabinding.java:299) >>> at >>> org.apache.cxf.aegis.databinding.AegisDatabinding.initialize(AegisDatabinding.java:266) >>> at >>> org.apache.cxf.service.factory.ReflectionServiceFactoryBean.buildServiceFromClass(ReflectionServiceFactoryBean.java:371) >>> at >>> org.apache.cxf.jaxws.support.JaxWsServiceFactoryBean.buildServiceFromClass(JaxWsServiceFactoryBean.java:525) >>> at >>> org.apache.cxf.service.factory.ReflectionServiceFactoryBean.initializeServiceModel(ReflectionServiceFactoryBean.java:422) >>> at >>> org.apache.cxf.service.factory.ReflectionServiceFactoryBean.create(ReflectionServiceFactoryBean.java:190) >>> at >>> org.apache.cxf.jaxws.support.JaxWsServiceFactoryBean.create(JaxWsServiceFactoryBean.java:164) >>> at >>> org.apache.cxf.frontend.AbstractWSDLBasedEndpointFactory.createEndpoint(AbstractWSDLBasedEndpointFactory.java:100) >>> at >>> org.apache.cxf.frontend.ClientFactoryBean.create(ClientFactoryBean.java:52) >>> at >>> org.apache.cxf.frontend.ClientProxyFactoryBean.create(ClientProxyFactoryBean.java:102) >>> at >>> org.apache.cxf.jaxws.JaxWsProxyFactoryBean.create(JaxWsProxyFactoryBean.java:115) >>> >>> >>> bimargulies wrote: >>>> >>>> The immediate exception is evidence of some pretty interesting >>>> confusion, insofar as the 'schema schema' is being added to the schema >>>> collection twice. >>>> >>>> Can I ask you to grab a 2.2 snapshot and see what you see? >>>> >>>> If not that, how about a JIRA with a self-contained test case? >>>> >>>> >>>> On Mon, Feb 16, 2009 at 12:59 PM, relphie <[email protected]> wrote: >>>>> >>>>> Hello, I am having problems registering custom type mappings in CXF 2.1 >>>>> with >>>>> an Aegis databinding. Previously in CXF 2.0, my type mappings were >>>>> registered successfully. >>>>> >>>>> My basic need is that I have a service that returns a Map, keyed by a >>>>> bean >>>>> interface. I needed to tell cxf what implementation to use for the >>>>> keys >>>>> so >>>>> that hashcode and equals were implemented correctly. >>>>> >>>>> Now, my service is throwing exception on startup, and it only occurs >>>>> when >>>>> I >>>>> add my custom type mappings: >>>>> >>>>> Caused by: org.apache.ws.commons.schema.XmlSchemaException: Schema name >>>>> conflict in collection. Namespace: http://www.w3.org/2001/XMLSchema >>>>> at >>>>> org.apache.ws.commons.schema.SchemaBuilder.handleXmlSchemaElement(SchemaBuilder.java:104) >>>>> at >>>>> org.apache.ws.commons.schema.SchemaBuilder.build(SchemaBuilder.java:83) >>>>> >>>>> Is there a better way to tell CXF what class to use for the map key, or >>>>> can >>>>> someone point out what I need to change in my configuration code? Here >>>>> is >>>>> what I am currently doing: >>>>> >>>>> JaxWsProxyFactoryBean clientFactory = new >>>>> JaxWsProxyFactoryBean(); >>>>> clientFactory.setAddress(url); >>>>> >>>>> clientFactory.setServiceClass(com.cerner.healthe.organization.service.OrganizationService.class); >>>>> >>>>> AegisDatabinding dataBinding = new AegisDatabinding(); >>>>> OrganizationAliasTypeRegistrar typeRegistrar = new >>>>> OrganizationAliasTypeRegistrar(); >>>>> typeRegistrar.setDataBinding(dataBinding); >>>>> typeRegistrar.register(); >>>>> clientFactory.setDataBinding(dataBinding); >>>>> >>>>> organizationClient = (OrganizationService) >>>>> clientFactory.create(); >>>>> >>>>> And the registrar: >>>>> >>>>> public class OrganizationAliasTypeRegistrar { >>>>> private AegisDatabinding dataBinding; >>>>> >>>>> /** >>>>> * Registers the ImpreciseDateTimeType to the data binding. >>>>> */ >>>>> public void register() { >>>>> dataBinding.getAegisContext().getTypeMapping().register( >>>>> OrganizationAliasType.TYPE_CLASS, >>>>> OrganizationAliasType.QNAME, >>>>> new OrganizationAliasType()); >>>>> } >>>>> >>>>> /** >>>>> * Sets the data binding. >>>>> * >>>>> * @param dataBinding >>>>> * The data binding to set. >>>>> */ >>>>> public void setDataBinding(AegisDatabinding dataBinding) { >>>>> this.dataBinding = dataBinding; >>>>> } >>>>> } >>>>> -- >>>>> View this message in context: >>>>> http://www.nabble.com/Aegis-Type-Mapping-tp22042434p22042434.html >>>>> Sent from the cxf-user mailing list archive at Nabble.com. >>>>> >>>>> >>>> >>>> >>> >>> -- >>> View this message in context: >>> http://www.nabble.com/Aegis-Type-Mapping-tp22042434p22042931.html >>> Sent from the cxf-user mailing list archive at Nabble.com. >>> >>> >> >> > > -- > View this message in context: > http://www.nabble.com/Aegis-Type-Mapping-tp22042434p22044248.html > Sent from the cxf-user mailing list archive at Nabble.com. > >
