RE: wsdl generation ala Xfire
Yes, you can do that with Aegis or Jaxb binding. (Xfire defaults to Aegis). -Original Message- From: Dave Kallstrom [mailto:[EMAIL PROTECTED] Sent: Monday, July 23, 2007 1:58 PM To: cxf-user@incubator.apache.org Subject: wsdl generation ala Xfire We are thinking about migrating from Xfire to CXF. There is one thing that I cannot find in the documentation for CXF. Is there a way to get the wsdl from cxf like we do with xfire by appending ?wsdl to the endpoint url without ever having to actually write a wsdl? -- Dave Kallstrom Princeton Retirement Group, Inc - Important Terms This E-mail is not intended for distribution to, or use by, any person or entity in any location where such distribution or use would be contrary to law or regulation, or which would subject Princeton Retirement Group, Inc. or any affiliate to any registration requirement within such location. This E-mail may contain privileged or confidential information or may otherwise be protected by work product immunity or other legal rules. No confidentiality or privilege is waived or lost by any mistransmission. Access, copying or re-use of information by non-intended or non-authorized recipients is prohibited. If you are not an intended recipient of this E-mail, please notify the sender, delete it and do not read, act upon, print, disclose, copy, retain or redistribute any portion of this E-mail. The transmission and content of this E-mail cannot be guaranteed to be secure or error-free. Therefore, we cannot represent that the information in this E-mail is complete, accurate, uncorrupted, timely or free of viruses, and Princeton Retirement Group, Inc. cannot accept any liability for E-mails that have been altered in the course of delivery. Princeton Retirement Group, Inc. reserves the right to monitor, review and retain all electronic communications, including E-mail, traveling through its networks and systems (subject to and in accordance with local laws). If any of your details are incorrect or if you no longer wish to receive mailings such as this by E-mail please contact the sender by reply E-mail.
RE: Newbie Question
Complex types should be handled automatically as a rule. If you're using Aegis binding, then you don't have to do anything. If you're using JAXB, you should just be able to add annotations on the service class and you'll be go to go for a basic start. You may find you need to add various annotations depending on how complex your type is and what your interoperability requirements are. There are also other options/annotations when you need to get more specific on your wsdl, service, etc. -Original Message- From: Mark Babcock [mailto:[EMAIL PROTECTED] Sent: Thursday, July 19, 2007 4:15 PM To: cxf-user@incubator.apache.org Subject: Newbie Question I have worked through the examples on the wiki and looked at the tutorials. I'm looking for help on howto create a complex type. I have a method that I want to return a java bean and more specifically an array of java beans. Can someone please help me with this. Interface UserBean[] getBean(); Princeton Retirement Group, Inc - Important Terms This E-mail is not intended for distribution to, or use by, any person or entity in any location where such distribution or use would be contrary to law or regulation, or which would subject Princeton Retirement Group, Inc. or any affiliate to any registration requirement within such location. This E-mail may contain privileged or confidential information or may otherwise be protected by work product immunity or other legal rules. No confidentiality or privilege is waived or lost by any mistransmission. Access, copying or re-use of information by non-intended or non-authorized recipients is prohibited. If you are not an intended recipient of this E-mail, please notify the sender, delete it and do not read, act upon, print, disclose, copy, retain or redistribute any portion of this E-mail. The transmission and content of this E-mail cannot be guaranteed to be secure or error-free. Therefore, we cannot represent that the information in this E-mail is complete, accurate, uncorrupted, timely or free of viruses, and Princeton Retirement Group, Inc. cannot accept any liability for E-mails that have been altered in the course of delivery. Princeton Retirement Group, Inc. reserves the right to monitor, review and retain all electronic communications, including E-mail, traveling through its networks and systems (subject to and in accordance with local laws). If any of your details are incorrect or if you no longer wish to receive mailings such as this by E-mail please contact the sender by reply E-mail.
RE: Web Method not returning correctly
Can I set the wsdl and the the service bean? I'm getting an error when it loads the wsdl saying it can't find the service, but that maybe since java2wsdk splits the wsdl into two files and maybe it's not loading the second one. -Original Message- From: Daniel Kulp [mailto:[EMAIL PROTECTED] Sent: Thursday, July 19, 2007 2:21 PM To: Clough, Samuel (USPC.PRG.Atlanta) Cc: cxf-user@incubator.apache.org Subject: Re: Web Method not returning correctly Oh. shoot. I gave the wrong instructions... :-( Use the java2wsdl tool with the -s option. Not the wsdl2java tool. Sorry about that. (you can add the -classdir option if you want as well to have the generated classes compiled) Looking at the soap message, what I described is correct. The soap message is not valid according to the schema in the wsdl. Dan On Thursday 19 July 2007 14:15, Clough, Samuel (USPC.PRG.Atlanta) wrote: > I went ahead and ran wsdl2java against the current wsdl that Jaxb is > generating. Should I go ahead and just use those replacement classes? > > -Original Message- > From: Daniel Kulp [mailto:[EMAIL PROTECTED] > Sent: Thursday, July 19, 2007 1:51 PM > To: cxf-user@incubator.apache.org > Cc: Clough, Samuel (USPC.PRG.Atlanta) > Subject: Re: Web Method not returning correctly > > > Samuel, > > Could you send the soap message? > > I'm willing to bet this is related to CXF-802 and CXF-655 which I'm > still > battling with. My expectation is that the "completedLogId" element > in the response soap message is ending up qualified instead of > unqualified like the schema states it should be..NET is probably > just looking for the unqualified version. (as it should) > > The main workaround for most of the "Java First" cases is to run > wsdl2java with the -s flag to generate the wrapper types. The > runtime should then pick up those wrappers and use those which should > make the messages correct. > > Dan > > On Thursday 19 July 2007 13:37, Clough, Samuel (USPC.PRG.Atlanta) wrote: > > Well, I've sniffed this with tcpmon and executed it via soapui. In > > both cases, I'm seeing the correct value come back in the response, > > but for some reason .NET is not reading it. Do I need to set some > > sort of annotation to ensure .NET compatibility? I would think > > things are fine. I see literal in the wsdl and the server is getting > > the request from .NET correctly, .NET is just not parsing the > > response correctly apparently. > > > > _ > > > > From: Clough, Samuel (USPC.PRG.Atlanta) > > Sent: Thursday, July 19, 2007 11:54 AM > > To: cxf-user@incubator.apache.org > > Subject: Web Method not returning correctly > > > > > > I'm trying to track down a problem. I have a method that takes a > > long and boolean parameter and then returns a long. The method was > > working just fine when I was using Aegis binding with the > > ServerFactoryBean. For some reason, Aegis was generating invalid > > wsdl (another thread I posted yesterday) related to other methods in > > the class and since I've been unable to get Aegis to create good > > wsdl for the class, I just put some basic annotations on the class > > and hosted it using JaxB via the JaxWsServerFactoryBean. The wsdl > > is good and the .NET clients have no problems consuming it. > > However, the method in question returns the correct long value on > > the Java server, but the .NET client now always sees zero as the > > return value when it calls the service. It worked properly before > > using Aegis binding and I know the long value is still being > > populated correctly from the logs. I'm assuming this is some sort > > of serialization issue, but is there an annotation I'm missing? > > Where should I be looking for the problem? The signature for the > > method in question is: > > @WebMethod > > > > public @WebResult(name="completedLogId") long > > finishImport(@WebParam(name="logId") long logId, > > @WebParam(name="rejectsOccurred")boolean rejectsOccurred) throws > > Exception > > > > > > The full wsdl for the service is: > > > xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"; > > xmlns:ns1="http://services.afp.prg.com/"; > > xmlns:ns2="http://schemas.xmlsoap.org/soap/http"; > > xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"; > > xmlns:xsd="http://www.w3.org/2001/XMLSchema"; > > name="AFPManagerServiceService" > > targetNamespace="http://services.afp.prg.com/";> > &g
RE: Web Method not returning correctly
So I should setup the JaxWsServerFactoryBean to use the generated wsdl rather than what JAXB is creating? Looking at the generated java classes from the wsdl, would just using an annotation like this on the methods fix the problem rather than needing an external wsdl? @WebResult(targetNamespace = "", name = "completedLogId") -Original Message- From: Daniel Kulp [mailto:[EMAIL PROTECTED] Sent: Thursday, July 19, 2007 2:21 PM To: Clough, Samuel (USPC.PRG.Atlanta) Cc: cxf-user@incubator.apache.org Subject: Re: Web Method not returning correctly Oh. shoot. I gave the wrong instructions... :-( Use the java2wsdl tool with the -s option. Not the wsdl2java tool. Sorry about that. (you can add the -classdir option if you want as well to have the generated classes compiled) Looking at the soap message, what I described is correct. The soap message is not valid according to the schema in the wsdl. Dan On Thursday 19 July 2007 14:15, Clough, Samuel (USPC.PRG.Atlanta) wrote: > I went ahead and ran wsdl2java against the current wsdl that Jaxb is > generating. Should I go ahead and just use those replacement classes? > > -Original Message- > From: Daniel Kulp [mailto:[EMAIL PROTECTED] > Sent: Thursday, July 19, 2007 1:51 PM > To: cxf-user@incubator.apache.org > Cc: Clough, Samuel (USPC.PRG.Atlanta) > Subject: Re: Web Method not returning correctly > > > Samuel, > > Could you send the soap message? > > I'm willing to bet this is related to CXF-802 and CXF-655 which I'm > still > battling with. My expectation is that the "completedLogId" element > in the response soap message is ending up qualified instead of > unqualified like the schema states it should be..NET is probably > just looking for the unqualified version. (as it should) > > The main workaround for most of the "Java First" cases is to run > wsdl2java with the -s flag to generate the wrapper types. The > runtime should then pick up those wrappers and use those which should > make the messages correct. > > Dan > > On Thursday 19 July 2007 13:37, Clough, Samuel (USPC.PRG.Atlanta) wrote: > > Well, I've sniffed this with tcpmon and executed it via soapui. In > > both cases, I'm seeing the correct value come back in the response, > > but for some reason .NET is not reading it. Do I need to set some > > sort of annotation to ensure .NET compatibility? I would think > > things are fine. I see literal in the wsdl and the server is getting > > the request from .NET correctly, .NET is just not parsing the > > response correctly apparently. > > > > _ > > > > From: Clough, Samuel (USPC.PRG.Atlanta) > > Sent: Thursday, July 19, 2007 11:54 AM > > To: cxf-user@incubator.apache.org > > Subject: Web Method not returning correctly > > > > > > I'm trying to track down a problem. I have a method that takes a > > long and boolean parameter and then returns a long. The method was > > working just fine when I was using Aegis binding with the > > ServerFactoryBean. For some reason, Aegis was generating invalid > > wsdl (another thread I posted yesterday) related to other methods in > > the class and since I've been unable to get Aegis to create good > > wsdl for the class, I just put some basic annotations on the class > > and hosted it using JaxB via the JaxWsServerFactoryBean. The wsdl > > is good and the .NET clients have no problems consuming it. > > However, the method in question returns the correct long value on > > the Java server, but the .NET client now always sees zero as the > > return value when it calls the service. It worked properly before > > using Aegis binding and I know the long value is still being > > populated correctly from the logs. I'm assuming this is some sort > > of serialization issue, but is there an annotation I'm missing? > > Where should I be looking for the problem? The signature for the > > method in question is: > > @WebMethod > > > > public @WebResult(name="completedLogId") long > > finishImport(@WebParam(name="logId") long logId, > > @WebParam(name="rejectsOccurred")boolean rejectsOccurred) throws > > Exception > > > > > > The full wsdl for the service is: > > > xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"; > > xmlns:ns1="http://services.afp.prg.com/"; > > xmlns:ns2="http://schemas.xmlsoap.org/soap/http"; > > xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"; > > xmlns:xsd="http://www.w3.org/2001/XMLSchema"; > > name="AFPMana
RE: Web Method not returning correctly
I went ahead and ran wsdl2java against the current wsdl that Jaxb is generating. Should I go ahead and just use those replacement classes? -Original Message- From: Daniel Kulp [mailto:[EMAIL PROTECTED] Sent: Thursday, July 19, 2007 1:51 PM To: cxf-user@incubator.apache.org Cc: Clough, Samuel (USPC.PRG.Atlanta) Subject: Re: Web Method not returning correctly Samuel, Could you send the soap message? I'm willing to bet this is related to CXF-802 and CXF-655 which I'm still battling with. My expectation is that the "completedLogId" element in the response soap message is ending up qualified instead of unqualified like the schema states it should be..NET is probably just looking for the unqualified version. (as it should) The main workaround for most of the "Java First" cases is to run wsdl2java with the -s flag to generate the wrapper types. The runtime should then pick up those wrappers and use those which should make the messages correct. Dan On Thursday 19 July 2007 13:37, Clough, Samuel (USPC.PRG.Atlanta) wrote: > Well, I've sniffed this with tcpmon and executed it via soapui. In > both cases, I'm seeing the correct value come back in the response, > but for some reason .NET is not reading it. Do I need to set some > sort of annotation to ensure .NET compatibility? I would think things > are fine. I see literal in the wsdl and the server is getting the > request from .NET correctly, .NET is just not parsing the response > correctly apparently. > > _ > > From: Clough, Samuel (USPC.PRG.Atlanta) > Sent: Thursday, July 19, 2007 11:54 AM > To: cxf-user@incubator.apache.org > Subject: Web Method not returning correctly > > > I'm trying to track down a problem. I have a method that takes a long > and boolean parameter and then returns a long. The method was working > just fine when I was using Aegis binding with the ServerFactoryBean. > For some reason, Aegis was generating invalid wsdl (another thread I > posted yesterday) related to other methods in the class and since I've > been unable to get Aegis to create good wsdl for the class, I just put > some basic annotations on the class and hosted it using JaxB via the > JaxWsServerFactoryBean. The wsdl is good and the .NET clients have no > problems consuming it. However, the method in question returns the > correct long value on the Java server, but the .NET client now always > sees zero as the return value when it calls the service. It worked > properly before using Aegis binding and I know the long value is still > being populated correctly from the logs. I'm assuming this is some > sort of serialization issue, but is there an annotation I'm missing? > Where should I be looking for the problem? The signature for the > method in question is: > @WebMethod > > public @WebResult(name="completedLogId") long > finishImport(@WebParam(name="logId") long logId, > @WebParam(name="rejectsOccurred")boolean rejectsOccurred) throws > Exception > > > The full wsdl for the service is: > xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"; > xmlns:ns1="http://services.afp.prg.com/"; > xmlns:ns2="http://schemas.xmlsoap.org/soap/http"; > xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"; > xmlns:xsd="http://www.w3.org/2001/XMLSchema"; > name="AFPManagerServiceService" > targetNamespace="http://services.afp.prg.com/";> > > http://www.w3.org/2001/XMLSchema"; > xmlns="http://services.afp.prg.com/"; > attributeFormDefault="unqualified" elementFormDefault="unqualified" > targetNamespace="http://services.afp.prg.com/";> > > > > > > > > > > > > > > > > type="getDataWarningsResponse"/> > > > type="xs:string"/> > > > > > > > > > > > > > > > > > > > > > > > > > > type="afpImportInfo"/> > > > > > > > > > > > name="parameters"> > > > > > > > > > > > > > > > > > > > > > >name="getDataWarnings"> > > >name="getDataWarningsResponse"> > > > > > >name="finishImportResponse"> > > > > > > >name="getImportsResponse"> > > > >type=&qu
RE: Web Method not returning correctly
Here's the soap response via tcpmon: HTTP/1.1 100 Continue HTTP/1.1 200 OK Content-Type: text/xml SOAPAction: "" Content-Length: 278 Server: Jetty(6.1.3) http://schemas.xmlsoap.org/soap/envelope/";>http://services.afp.prg.com/";>http://services.afp.prg.com/";>12276 -Original Message- From: Daniel Kulp [mailto:[EMAIL PROTECTED] Sent: Thursday, July 19, 2007 1:51 PM To: cxf-user@incubator.apache.org Cc: Clough, Samuel (USPC.PRG.Atlanta) Subject: Re: Web Method not returning correctly Samuel, Could you send the soap message? I'm willing to bet this is related to CXF-802 and CXF-655 which I'm still battling with. My expectation is that the "completedLogId" element in the response soap message is ending up qualified instead of unqualified like the schema states it should be..NET is probably just looking for the unqualified version. (as it should) The main workaround for most of the "Java First" cases is to run wsdl2java with the -s flag to generate the wrapper types. The runtime should then pick up those wrappers and use those which should make the messages correct. Dan On Thursday 19 July 2007 13:37, Clough, Samuel (USPC.PRG.Atlanta) wrote: > Well, I've sniffed this with tcpmon and executed it via soapui. In > both cases, I'm seeing the correct value come back in the response, > but for some reason .NET is not reading it. Do I need to set some > sort of annotation to ensure .NET compatibility? I would think things > are fine. I see literal in the wsdl and the server is getting the > request from .NET correctly, .NET is just not parsing the response > correctly apparently. > > _ > > From: Clough, Samuel (USPC.PRG.Atlanta) > Sent: Thursday, July 19, 2007 11:54 AM > To: cxf-user@incubator.apache.org > Subject: Web Method not returning correctly > > > I'm trying to track down a problem. I have a method that takes a long > and boolean parameter and then returns a long. The method was working > just fine when I was using Aegis binding with the ServerFactoryBean. > For some reason, Aegis was generating invalid wsdl (another thread I > posted yesterday) related to other methods in the class and since I've > been unable to get Aegis to create good wsdl for the class, I just put > some basic annotations on the class and hosted it using JaxB via the > JaxWsServerFactoryBean. The wsdl is good and the .NET clients have no > problems consuming it. However, the method in question returns the > correct long value on the Java server, but the .NET client now always > sees zero as the return value when it calls the service. It worked > properly before using Aegis binding and I know the long value is still > being populated correctly from the logs. I'm assuming this is some > sort of serialization issue, but is there an annotation I'm missing? > Where should I be looking for the problem? The signature for the > method in question is: > @WebMethod > > public @WebResult(name="completedLogId") long > finishImport(@WebParam(name="logId") long logId, > @WebParam(name="rejectsOccurred")boolean rejectsOccurred) throws > Exception > > > The full wsdl for the service is: > xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"; > xmlns:ns1="http://services.afp.prg.com/"; > xmlns:ns2="http://schemas.xmlsoap.org/soap/http"; > xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"; > xmlns:xsd="http://www.w3.org/2001/XMLSchema"; > name="AFPManagerServiceService" > targetNamespace="http://services.afp.prg.com/";> > > http://www.w3.org/2001/XMLSchema"; > xmlns="http://services.afp.prg.com/"; > attributeFormDefault="unqualified" elementFormDefault="unqualified" > targetNamespace="http://services.afp.prg.com/";> > > > > > > > > > > > > > > > > type="getDataWarningsResponse"/> > > > type="xs:string"/> > > > > > > > > > > > > > > > > > > > > > > > > > > type="afpImportInfo"/> > > > > > > > > > > > name="parameters"> > > > > > > > > > > > > > > > > > > > > > >name="getDataWarnings"> > > >name="getDataWarningsResponse"> > > > > > >name="finishImportRespo
RE: Web Method not returning correctly
Well, I've sniffed this with tcpmon and executed it via soapui. In both cases, I'm seeing the correct value come back in the response, but for some reason .NET is not reading it. Do I need to set some sort of annotation to ensure .NET compatibility? I would think things are fine. I see literal in the wsdl and the server is getting the request from .NET correctly, .NET is just not parsing the response correctly apparently. _ From: Clough, Samuel (USPC.PRG.Atlanta) Sent: Thursday, July 19, 2007 11:54 AM To: cxf-user@incubator.apache.org Subject: Web Method not returning correctly I'm trying to track down a problem. I have a method that takes a long and boolean parameter and then returns a long. The method was working just fine when I was using Aegis binding with the ServerFactoryBean. For some reason, Aegis was generating invalid wsdl (another thread I posted yesterday) related to other methods in the class and since I've been unable to get Aegis to create good wsdl for the class, I just put some basic annotations on the class and hosted it using JaxB via the JaxWsServerFactoryBean. The wsdl is good and the .NET clients have no problems consuming it. However, the method in question returns the correct long value on the Java server, but the .NET client now always sees zero as the return value when it calls the service. It worked properly before using Aegis binding and I know the long value is still being populated correctly from the logs. I'm assuming this is some sort of serialization issue, but is there an annotation I'm missing? Where should I be looking for the problem? The signature for the method in question is: @WebMethod public @WebResult(name="completedLogId") long finishImport(@WebParam(name="logId") long logId, @WebParam(name="rejectsOccurred")boolean rejectsOccurred) throws Exception The full wsdl for the service is: http://schemas.xmlsoap.org/wsdl/"; xmlns:ns1="http://services.afp.prg.com/"; xmlns:ns2="http://schemas.xmlsoap.org/soap/http"; xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"; xmlns:xsd="http://www.w3.org/2001/XMLSchema"; name="AFPManagerServiceService" targetNamespace="http://services.afp.prg.com/";> http://www.w3.org/2001/XMLSchema"; xmlns="http://services.afp.prg.com/"; attributeFormDefault="unqualified" elementFormDefault="unqualified" targetNamespace="http://services.afp.prg.com/";> http://schemas.xmlsoap.org/soap/http"/> http://patlhapdev01.prg.us.ml.com:8192/afpmanager/2007/07/AFPM anagerService"/> Princeton Retirement Group, Inc - Important Terms This E-mail is not intended for distribution to, or use by, any person or entity in any location where such distribution or use would be contrary to law or regulation, or which would subject Princeton Retirement Group, Inc. or any affiliate to any registration requirement within such location. This E-mail may contain privileged or confidential information or may otherwise be protected by work product immunity or other legal rules. No confidentiality or privilege is waived or lost by any mistransmission. Access, copying or re-use of information by non-intended or non-authorized recipients is prohibited. If you are not an intended recipient of this E-mail, please notify the sender, delete it and do not read, act upon, print, disclose, copy, retain or redistribute any portion of this E-mail. The transmission and content of this E-mail cannot be guaranteed to be secure or error-free. Therefore, we cannot represent that the information in this E-mail is complete, accurate, uncorrupted, timely or free of viruses, and Princeton Retirement Group, Inc. cannot accept any liability for E-mails that have been altered in the course of delivery. Princeton Retirement Group, Inc. reserves the right to monitor, review and retain all electronic communications, including E-mail, traveling through its networks and systems (subject to and in accordance with local laws). If any of your details are incorrect or if you no longer wish to receive mailings such as this by E-mail please contact the sender by reply E-mail.
Web Method not returning correctly
I'm trying to track down a problem. I have a method that takes a long and boolean parameter and then returns a long. The method was working just fine when I was using Aegis binding with the ServerFactoryBean. For some reason, Aegis was generating invalid wsdl (another thread I posted yesterday) related to other methods in the class and since I've been unable to get Aegis to create good wsdl for the class, I just put some basic annotations on the class and hosted it using JaxB via the JaxWsServerFactoryBean. The wsdl is good and the .NET clients have no problems consuming it. However, the method in question returns the correct long value on the Java server, but the .NET client now always sees zero as the return value when it calls the service. It worked properly before using Aegis binding and I know the long value is still being populated correctly from the logs. I'm assuming this is some sort of serialization issue, but is there an annotation I'm missing? Where should I be looking for the problem? The signature for the method in question is: @WebMethod public @WebResult(name="completedLogId") long finishImport(@WebParam(name="logId") long logId, @WebParam(name="rejectsOccurred")boolean rejectsOccurred) throws Exception The full wsdl for the service is: http://schemas.xmlsoap.org/wsdl/"; xmlns:ns1="http://services.afp.prg.com/"; xmlns:ns2="http://schemas.xmlsoap.org/soap/http"; xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"; xmlns:xsd="http://www.w3.org/2001/XMLSchema"; name="AFPManagerServiceService" targetNamespace="http://services.afp.prg.com/";> http://www.w3.org/2001/XMLSchema"; xmlns="http://services.afp.prg.com/"; attributeFormDefault="unqualified" elementFormDefault="unqualified" targetNamespace="http://services.afp.prg.com/";> http://schemas.xmlsoap.org/soap/http"/> http://patlhapdev01.prg.us.ml.com:8192/afpmanager/2007/07/AFPM anagerService"/> Princeton Retirement Group, Inc - Important Terms This E-mail is not intended for distribution to, or use by, any person or entity in any location where such distribution or use would be contrary to law or regulation, or which would subject Princeton Retirement Group, Inc. or any affiliate to any registration requirement within such location. This E-mail may contain privileged or confidential information or may otherwise be protected by work product immunity or other legal rules. No confidentiality or privilege is waived or lost by any mistransmission. Access, copying or re-use of information by non-intended or non-authorized recipients is prohibited. If you are not an intended recipient of this E-mail, please notify the sender, delete it and do not read, act upon, print, disclose, copy, retain or redistribute any portion of this E-mail. The transmission and content of this E-mail cannot be guaranteed to be secure or error-free. Therefore, we cannot represent that the information in this E-mail is complete, accurate, uncorrupted, timely or free of viruses, and Princeton Retirement Group, Inc. cannot accept any liability for E-mails that have been altered in the course of delivery. Princeton Retirement Group, Inc. reserves the right to monitor, review and retain all electronic communications, including E-mail, traveling through its networks and systems (subject to and in accordance with local laws). If any of your details are incorrect or if you no longer wish to receive mailings such as this by E-mail please contact the sender by reply E-mail.
RE: WSDL Generation problem using Aegis binding
No. -Original Message- From: Benson Margulies [mailto:[EMAIL PROTECTED] Sent: Wednesday, July 18, 2007 3:07 PM To: cxf-user@incubator.apache.org Subject: RE: WSDL Generation problem using Aegis binding Is there a .aegis.xml file in the neighborhood of your problem? > -Original Message- > From: Clough, Samuel (USPC.PRG.Atlanta) > [mailto:[EMAIL PROTECTED] > Sent: Wednesday, July 18, 2007 3:02 PM > To: cxf-user@incubator.apache.org > Subject: RE: WSDL Generation problem using Aegis binding > > Thanks for the clarification. I wonder what's making Aegis omit the > namespace. I found it odd since Aegis doesn't seem to generate the > element node for another service I looked at, but your explanation makes > perfect sense. > > -Original Message- > From: omatzura [mailto:[EMAIL PROTECTED] > Sent: Wednesday, July 18, 2007 2:57 PM > To: cxf-user@incubator.apache.org > Subject: Re: WSDL Generation problem using Aegis binding > > > Hi Samuel, > > Just to clarify the error: an element definition like this is fine, the > problem in this particular case is that the type for the element is not > namespace qualified, so it basically means that for the > > > > element, the type getDataWarnings is expected to be in the default > namespace > (which is the xmlschema namespace, as the error message implies.. ) > > What's missing is a namespace-prefix declaration for the target > namespace > and then that prefix on your elements' type.. ie > > http://www.w3.org/2001/XMLSchema"; > attributeFormDefault="qualified" elementFormDefault="qualified" > targetNamespace="http://service.afp.prg.com/";> > > should be something like > > http://www.w3.org/2001/XMLSchema"; > attributeFormDefault="qualified" elementFormDefault="qualified" > targetNamespace="http://service.afp.prg.com/"; > xmlns:tns="http://service.afp.prg.com/";> > > and the element should then be > > > > Don't know if this helps you resolve the error, but maybe at least > understand it in more detail.. > > kind regards, and thanks for using soapUI ! > > /Ole > eviware.com > > > Clough, Samuel (USPC.PRG.Atlanta) wrote: > > > > Below is a snippet of the WSDL that's getting generated using Aegis > > binding with the embedded server and causing errors. We're doing Java > > first development, no annotations or anything as these are all > internal > > appsl. When the .NET client tried to connect we were getting a > bizarre > > error which I believe I have been able to track down using soapui. At > > the bottom of this message is a fragment of the wsdl generated. I am > > very green at wsdl, but the problem seems to be that for every complex > > type being defined in the schema, before the complexType node there is > > an "element" node by the same name. SoapUI is what led me to this > > conclusion because it rasies an error trying to pull in the wsdl that > > the type is not defined at http://www.w3.org/2001/XMLSchema. So, I > > believe the "element" node that is preceding each complexType node is > an > > error. The bizarre thing is that we have other classes generating > wsdl > > just fine and on those services there is not element node preceding > each > > complexType node of the same name. Any clue what could be causing > this > > error? > > > > > xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"; > > xmlns:ns1="http://service.afp.prg.com/"; > > xmlns:ns2="http://schemas.xmlsoap.org/soap/http"; > > xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"; > > xmlns:xsd="http://www.w3.org/2001/XMLSchema"; name="AFPManagerService" > > targetNamespace="http://service.afp.prg.com/";> > > > > http://www.w3.org/2001/XMLSchema"; > > attributeFormDefault="qualified" elementFormDefault="qualified" > > targetNamespace="http://service.afp.prg.com/";> > > > > > > > nillable="true" type="string"/> > > > > > > > > > > > > > > > > > > > > > > > > type="getDataWarningsResponse"/> > > > > > > > type="ArrayOfString"/> > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > --
RE: WSDL Generation problem using Aegis binding
Thanks for the clarification. I wonder what's making Aegis omit the namespace. I found it odd since Aegis doesn't seem to generate the element node for another service I looked at, but your explanation makes perfect sense. -Original Message- From: omatzura [mailto:[EMAIL PROTECTED] Sent: Wednesday, July 18, 2007 2:57 PM To: cxf-user@incubator.apache.org Subject: Re: WSDL Generation problem using Aegis binding Hi Samuel, Just to clarify the error: an element definition like this is fine, the problem in this particular case is that the type for the element is not namespace qualified, so it basically means that for the element, the type getDataWarnings is expected to be in the default namespace (which is the xmlschema namespace, as the error message implies.. ) What's missing is a namespace-prefix declaration for the target namespace and then that prefix on your elements' type.. ie http://www.w3.org/2001/XMLSchema"; attributeFormDefault="qualified" elementFormDefault="qualified" targetNamespace="http://service.afp.prg.com/";> should be something like http://www.w3.org/2001/XMLSchema"; attributeFormDefault="qualified" elementFormDefault="qualified" targetNamespace="http://service.afp.prg.com/"; xmlns:tns="http://service.afp.prg.com/";> and the element should then be Don't know if this helps you resolve the error, but maybe at least understand it in more detail.. kind regards, and thanks for using soapUI ! /Ole eviware.com Clough, Samuel (USPC.PRG.Atlanta) wrote: > > Below is a snippet of the WSDL that's getting generated using Aegis > binding with the embedded server and causing errors. We're doing Java > first development, no annotations or anything as these are all internal > appsl. When the .NET client tried to connect we were getting a bizarre > error which I believe I have been able to track down using soapui. At > the bottom of this message is a fragment of the wsdl generated. I am > very green at wsdl, but the problem seems to be that for every complex > type being defined in the schema, before the complexType node there is > an "element" node by the same name. SoapUI is what led me to this > conclusion because it rasies an error trying to pull in the wsdl that > the type is not defined at http://www.w3.org/2001/XMLSchema. So, I > believe the "element" node that is preceding each complexType node is an > error. The bizarre thing is that we have other classes generating wsdl > just fine and on those services there is not element node preceding each > complexType node of the same name. Any clue what could be causing this > error? > > xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"; > xmlns:ns1="http://service.afp.prg.com/"; > xmlns:ns2="http://schemas.xmlsoap.org/soap/http"; > xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"; > xmlns:xsd="http://www.w3.org/2001/XMLSchema"; name="AFPManagerService" > targetNamespace="http://service.afp.prg.com/";> > > http://www.w3.org/2001/XMLSchema"; > attributeFormDefault="qualified" elementFormDefault="qualified" > targetNamespace="http://service.afp.prg.com/";> > > > nillable="true" type="string"/> > > > > > > > > > > > > > > > type="ArrayOfString"/> > > > > > > > > > > > > > > > > > > > > Princeton Retirement Group, Inc - Important Terms > This E-mail is not intended for distribution to, or use by, any person or > entity in any location where such distribution or use would be contrary to > law or regulation, or which would subject Princeton Retirement Group, Inc. > or any affiliate to any registration requirement within such location. > This E-mail may contain privileged or confidential information or may > otherwise be protected by work product immunity or other legal rules. No > confidentiality or privilege is waived or lost by any mistransmission. > Access, copying or re-use of information by non-intended or non-authorized > recipients is prohibited. If you are not an intended recipient of this > E-mail, please notify the sender, delete it and do not read, act upon, > print, disclose, copy, retain or redistribute any portion of this E-mail. > The transmission and content of this E-mail cannot be guaranteed to be > secure or error-free. Therefore, we cannot represent that the information > in this E-mail is complete, accurate, uncorrupted, timely o
RE: How to enable mtom on the embedded server?
Thanks, that's exactly what I was looking for. -Original Message- From: Dan Diephouse [mailto:[EMAIL PROTECTED] Sent: Wednesday, July 18, 2007 12:23 PM To: cxf-user@incubator.apache.org Subject: Re: How to enable mtom on the embedded server? Hi Samuel, You CAN use MTOM with Aegis still. I updated our documentation to reflect this: http://cwiki.apache.org/confluence/display/CXF20DOC/MTOM+Attachments An excerpt: If you're using the simple frontend you can set the mtom-enabled property on your ServerFactoryBean or ClientProxyFactoryBean: Map props = new HashMap(); props.put("mtom-enabled", Boolean.TRUE); // Boolean.TRUE or "true" will work as the property value here ClientProxyFactoryBean pf = new ClientProxyFactoryBean(); pf.setPropertyies(props); YourClient client = (YourClient) pf.create(); ServerFactoryBean sf = new ServerFactoryBean(); sf.setPropertyies(props); ... sf.create(); Similarly, you can use the XML configuration: http://www.springframework.org/schema/beans"; xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; xmlns:simple="http://cxf.apache.org/simple"; xsi:schemaLocation=" http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.0.xsd http://cxf.apache.org/simple http://cxf.apache.org/schema/simple.xsd";> http://localhost/HelloWorld";> http://localhost/HelloWorld";> Cheers, - Dan On 7/18/07, Clough, Samuel (USPC.PRG.Atlanta) <[EMAIL PROTECTED]> wrote: > > Thanks, that helps. Just so I understand this, does this mean CXF no > longer supports using MTOM via Aegis binding when using the embedded > Jetty instance like Xfire did? > > -Original Message- > From: Freeman Fang [mailto:[EMAIL PROTECTED] > Sent: Tuesday, July 17, 2007 10:28 PM > To: cxf-user@incubator.apache.org > Subject: Re: How to enable mtom on the embedded server? > > Hi Samuel, > > javax.xml.ws.soap.SOAPBinding is class from jax-ws api, so you need make > your service jaxws compatible > add jaxws BindingType annotation into your TestServiceImpl > @BindingType (value = SoapBinding.SOAP11HTTP_MTOM_BINDING) > And use JaxWsServerFactoryBean instead of ServerFactoryBean to create > your server. > You can get more details from JaxWsServerFactoryBean. > > Best Regards > Freeman > > > > > Clough, Samuel (USPC.PRG.Atlanta) wrote: > > Ok, I'm trying to add this to a service hosted by the > ServerFactoryBean > > (the way specified in the Xfire migration guide) . > > > > If I do the following to get to the binding to turn on MTOM: > > > > ServerFactoryBean sf = new ServerFactoryBean(); > > > > sf.getServiceFactory().setDataBinding(new AegisDatabinding()); > > sf.setServiceBean(new TestServiceImpl()); > > sf.setServiceClass(TestService.class); > > sf.setAddress("http://localhost:8192/test/TestService";); > > sf.create(); > > > > SoapBinding binding = (SoapBinding) > > sf.getServer().getEndpoint().getBinding(); > > > > I'm getting back a type of org.apache.cxf.binding.soap.SoapBinding > which > > has no option to turn on MTOM that I can see. According to the > > documentation, I need to get back a type of > > javax.xml.ws.soap.SOAPBinding. How do I start the service so that I'm > > getting SOAPBinding and can turn on the MTOM? > > > > -Original Message- > > From: Christopher Moesel [mailto:[EMAIL PROTECTED] > > Sent: Tuesday, July 17, 2007 12:05 PM > > To: cxf-user@incubator.apache.org > > Subject: RE: How to enable mtom on the embedded server? > > > > Hi Samuel, > > > > Have you looked at the MTOM documentation in the user guide? > > http://cwiki.apache.org/CXF20DOC/mtom.html > > > > If so, then what information is missing (or incorrect) that you need? > > > > -Chris > > > > -Original Message- > > From: Clough, Samuel (USPC.PRG.Atlanta) > > [mailto:[EMAIL PROTECTED] > > Sent: Tuesday, July 17, 2007 10:39 AM > > To: cxf-user@incubator.apache.org > > Subject: RE: How to enable mtom on the embedded server? > > > > We're trying to convert some services off of XFire and onto CXF. On > > XFire, the following would automatically enable MTOM for any types in > a > > service that returned a byte array: > > > > Service service = serviceFactory.create(FeedbackFilesService.class); > > service.setInvoker(new BeanInvoker(new FeedbackFilesServiceImpl())); > > > > //enable MTOM to send the file contents more efficiently. > > service.setProperty("mtom-enabl
WSDL Generation problem using Aegis binding
Below is a snippet of the WSDL that's getting generated using Aegis binding with the embedded server and causing errors. We're doing Java first development, no annotations or anything as these are all internal appsl. When the .NET client tried to connect we were getting a bizarre error which I believe I have been able to track down using soapui. At the bottom of this message is a fragment of the wsdl generated. I am very green at wsdl, but the problem seems to be that for every complex type being defined in the schema, before the complexType node there is an "element" node by the same name. SoapUI is what led me to this conclusion because it rasies an error trying to pull in the wsdl that the type is not defined at http://www.w3.org/2001/XMLSchema. So, I believe the "element" node that is preceding each complexType node is an error. The bizarre thing is that we have other classes generating wsdl just fine and on those services there is not element node preceding each complexType node of the same name. Any clue what could be causing this error? http://schemas.xmlsoap.org/wsdl/"; xmlns:ns1="http://service.afp.prg.com/"; xmlns:ns2="http://schemas.xmlsoap.org/soap/http"; xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"; xmlns:xsd="http://www.w3.org/2001/XMLSchema"; name="AFPManagerService" targetNamespace="http://service.afp.prg.com/";> http://www.w3.org/2001/XMLSchema"; attributeFormDefault="qualified" elementFormDefault="qualified" targetNamespace="http://service.afp.prg.com/";> Princeton Retirement Group, Inc - Important Terms This E-mail is not intended for distribution to, or use by, any person or entity in any location where such distribution or use would be contrary to law or regulation, or which would subject Princeton Retirement Group, Inc. or any affiliate to any registration requirement within such location. This E-mail may contain privileged or confidential information or may otherwise be protected by work product immunity or other legal rules. No confidentiality or privilege is waived or lost by any mistransmission. Access, copying or re-use of information by non-intended or non-authorized recipients is prohibited. If you are not an intended recipient of this E-mail, please notify the sender, delete it and do not read, act upon, print, disclose, copy, retain or redistribute any portion of this E-mail. The transmission and content of this E-mail cannot be guaranteed to be secure or error-free. Therefore, we cannot represent that the information in this E-mail is complete, accurate, uncorrupted, timely or free of viruses, and Princeton Retirement Group, Inc. cannot accept any liability for E-mails that have been altered in the course of delivery. Princeton Retirement Group, Inc. reserves the right to monitor, review and retain all electronic communications, including E-mail, traveling through its networks and systems (subject to and in accordance with local laws). If any of your details are incorrect or if you no longer wish to receive mailings such as this by E-mail please contact the sender by reply E-mail.
RE: How to enable mtom on the embedded server?
Thanks, that helps. Just so I understand this, does this mean CXF no longer supports using MTOM via Aegis binding when using the embedded Jetty instance like Xfire did? -Original Message- From: Freeman Fang [mailto:[EMAIL PROTECTED] Sent: Tuesday, July 17, 2007 10:28 PM To: cxf-user@incubator.apache.org Subject: Re: How to enable mtom on the embedded server? Hi Samuel, javax.xml.ws.soap.SOAPBinding is class from jax-ws api, so you need make your service jaxws compatible add jaxws BindingType annotation into your TestServiceImpl @BindingType (value = SoapBinding.SOAP11HTTP_MTOM_BINDING) And use JaxWsServerFactoryBean instead of ServerFactoryBean to create your server. You can get more details from JaxWsServerFactoryBean. Best Regards Freeman Clough, Samuel (USPC.PRG.Atlanta) wrote: > Ok, I'm trying to add this to a service hosted by the ServerFactoryBean > (the way specified in the Xfire migration guide) . > > If I do the following to get to the binding to turn on MTOM: > > ServerFactoryBean sf = new ServerFactoryBean(); > > sf.getServiceFactory().setDataBinding(new AegisDatabinding()); > sf.setServiceBean(new TestServiceImpl()); > sf.setServiceClass(TestService.class); > sf.setAddress("http://localhost:8192/test/TestService";); > sf.create(); > > SoapBinding binding = (SoapBinding) > sf.getServer().getEndpoint().getBinding(); > > I'm getting back a type of org.apache.cxf.binding.soap.SoapBinding which > has no option to turn on MTOM that I can see. According to the > documentation, I need to get back a type of > javax.xml.ws.soap.SOAPBinding. How do I start the service so that I'm > getting SOAPBinding and can turn on the MTOM? > > -Original Message- > From: Christopher Moesel [mailto:[EMAIL PROTECTED] > Sent: Tuesday, July 17, 2007 12:05 PM > To: cxf-user@incubator.apache.org > Subject: RE: How to enable mtom on the embedded server? > > Hi Samuel, > > Have you looked at the MTOM documentation in the user guide? > http://cwiki.apache.org/CXF20DOC/mtom.html > > If so, then what information is missing (or incorrect) that you need? > > -Chris > > -Original Message- > From: Clough, Samuel (USPC.PRG.Atlanta) > [mailto:[EMAIL PROTECTED] > Sent: Tuesday, July 17, 2007 10:39 AM > To: cxf-user@incubator.apache.org > Subject: RE: How to enable mtom on the embedded server? > > We're trying to convert some services off of XFire and onto CXF. On > XFire, the following would automatically enable MTOM for any types in a > service that returned a byte array: > > Service service = serviceFactory.create(FeedbackFilesService.class); > service.setInvoker(new BeanInvoker(new FeedbackFilesServiceImpl())); > > //enable MTOM to send the file contents more efficiently. > service.setProperty("mtom-enabled", "true"); > > I cannot find how to do that easily using the new ServerFactoryBean > approach. How do I enable MTOM on a service using the embedded HTTP > server? > > > Princeton Retirement Group, Inc - Important Terms > This E-mail is not intended for distribution to, or use by, any person > or entity in any location where such distribution or use would be > contrary to law or regulation, or which would subject Princeton > Retirement Group, Inc. or any affiliate to any registration requirement > within such location. > This E-mail may contain privileged or confidential information or may > otherwise be protected by work product immunity or other legal rules. No > confidentiality or privilege is waived or lost by any mistransmission. > Access, copying or re-use of information by non-intended or > non-authorized recipients is prohibited. If you are not an intended > recipient of this E-mail, please notify the sender, delete it and do not > read, act upon, print, disclose, copy, retain or redistribute any > portion of this E-mail. > The transmission and content of this E-mail cannot be guaranteed to be > secure or error-free. Therefore, we cannot represent that the > information in this E-mail is complete, accurate, uncorrupted, timely or > free of viruses, and Princeton Retirement Group, Inc. cannot accept any > liability for E-mails that have been altered in the course of delivery. > Princeton Retirement Group, Inc. reserves the right to monitor, review > and retain all electronic communications, including E-mail, traveling > through its networks and systems (subject to and in accordance with > local laws). If any of your details are incorrect or if you no longer > wish to receive mailings such as this by E-mail please contact the > sender by reply E-mail. > > -
RE: How to enable mtom on the embedded server?
Ok, I'm trying to add this to a service hosted by the ServerFactoryBean (the way specified in the Xfire migration guide) . If I do the following to get to the binding to turn on MTOM: ServerFactoryBean sf = new ServerFactoryBean(); sf.getServiceFactory().setDataBinding(new AegisDatabinding()); sf.setServiceBean(new TestServiceImpl()); sf.setServiceClass(TestService.class); sf.setAddress("http://localhost:8192/test/TestService";); sf.create(); SoapBinding binding = (SoapBinding) sf.getServer().getEndpoint().getBinding(); I'm getting back a type of org.apache.cxf.binding.soap.SoapBinding which has no option to turn on MTOM that I can see. According to the documentation, I need to get back a type of javax.xml.ws.soap.SOAPBinding. How do I start the service so that I'm getting SOAPBinding and can turn on the MTOM? -Original Message- From: Christopher Moesel [mailto:[EMAIL PROTECTED] Sent: Tuesday, July 17, 2007 12:05 PM To: cxf-user@incubator.apache.org Subject: RE: How to enable mtom on the embedded server? Hi Samuel, Have you looked at the MTOM documentation in the user guide? http://cwiki.apache.org/CXF20DOC/mtom.html If so, then what information is missing (or incorrect) that you need? -Chris -Original Message----- From: Clough, Samuel (USPC.PRG.Atlanta) [mailto:[EMAIL PROTECTED] Sent: Tuesday, July 17, 2007 10:39 AM To: cxf-user@incubator.apache.org Subject: RE: How to enable mtom on the embedded server? We're trying to convert some services off of XFire and onto CXF. On XFire, the following would automatically enable MTOM for any types in a service that returned a byte array: Service service = serviceFactory.create(FeedbackFilesService.class); service.setInvoker(new BeanInvoker(new FeedbackFilesServiceImpl())); //enable MTOM to send the file contents more efficiently. service.setProperty("mtom-enabled", "true"); I cannot find how to do that easily using the new ServerFactoryBean approach. How do I enable MTOM on a service using the embedded HTTP server? Princeton Retirement Group, Inc - Important Terms This E-mail is not intended for distribution to, or use by, any person or entity in any location where such distribution or use would be contrary to law or regulation, or which would subject Princeton Retirement Group, Inc. or any affiliate to any registration requirement within such location. This E-mail may contain privileged or confidential information or may otherwise be protected by work product immunity or other legal rules. No confidentiality or privilege is waived or lost by any mistransmission. Access, copying or re-use of information by non-intended or non-authorized recipients is prohibited. If you are not an intended recipient of this E-mail, please notify the sender, delete it and do not read, act upon, print, disclose, copy, retain or redistribute any portion of this E-mail. The transmission and content of this E-mail cannot be guaranteed to be secure or error-free. Therefore, we cannot represent that the information in this E-mail is complete, accurate, uncorrupted, timely or free of viruses, and Princeton Retirement Group, Inc. cannot accept any liability for E-mails that have been altered in the course of delivery. Princeton Retirement Group, Inc. reserves the right to monitor, review and retain all electronic communications, including E-mail, traveling through its networks and systems (subject to and in accordance with local laws). If any of your details are incorrect or if you no longer wish to receive mailings such as this by E-mail please contact the sender by reply E-mail.
RE: How to enable mtom on the embedded server?
I have looked at that doc. I was trying to see if there was a simple setting like what Xfire had that would activate it on byte[] property. We're doing Java first dev since all the services here are in house and nothing uses Annotations right now for the services, so I was trying to do it without adding any xml or a new annotation. It does look like I can get to the server through the serverfactorybean and grab the endpoint and enable mtom support on the server from there. -Original Message- From: Christopher Moesel [mailto:[EMAIL PROTECTED] Sent: Tuesday, July 17, 2007 12:05 PM To: cxf-user@incubator.apache.org Subject: RE: How to enable mtom on the embedded server? Hi Samuel, Have you looked at the MTOM documentation in the user guide? http://cwiki.apache.org/CXF20DOC/mtom.html If so, then what information is missing (or incorrect) that you need? -Chris -Original Message- From: Clough, Samuel (USPC.PRG.Atlanta) [mailto:[EMAIL PROTECTED] Sent: Tuesday, July 17, 2007 10:39 AM To: cxf-user@incubator.apache.org Subject: RE: How to enable mtom on the embedded server? We're trying to convert some services off of XFire and onto CXF. On XFire, the following would automatically enable MTOM for any types in a service that returned a byte array: Service service = serviceFactory.create(FeedbackFilesService.class); service.setInvoker(new BeanInvoker(new FeedbackFilesServiceImpl())); //enable MTOM to send the file contents more efficiently. service.setProperty("mtom-enabled", "true"); I cannot find how to do that easily using the new ServerFactoryBean approach. How do I enable MTOM on a service using the embedded HTTP server? Princeton Retirement Group, Inc - Important Terms This E-mail is not intended for distribution to, or use by, any person or entity in any location where such distribution or use would be contrary to law or regulation, or which would subject Princeton Retirement Group, Inc. or any affiliate to any registration requirement within such location. This E-mail may contain privileged or confidential information or may otherwise be protected by work product immunity or other legal rules. No confidentiality or privilege is waived or lost by any mistransmission. Access, copying or re-use of information by non-intended or non-authorized recipients is prohibited. If you are not an intended recipient of this E-mail, please notify the sender, delete it and do not read, act upon, print, disclose, copy, retain or redistribute any portion of this E-mail. The transmission and content of this E-mail cannot be guaranteed to be secure or error-free. Therefore, we cannot represent that the information in this E-mail is complete, accurate, uncorrupted, timely or free of viruses, and Princeton Retirement Group, Inc. cannot accept any liability for E-mails that have been altered in the course of delivery. Princeton Retirement Group, Inc. reserves the right to monitor, review and retain all electronic communications, including E-mail, traveling through its networks and systems (subject to and in accordance with local laws). If any of your details are incorrect or if you no longer wish to receive mailings such as this by E-mail please contact the sender by reply E-mail.
RE: Wrong number of Arguments Error
Wow, thanks for that. Should I go ahead and build my own patched Aegis, or should I wait for you to finish your testing to make sure this is all we need? What project owns the Aegis code now? -Original Message- From: Daniel Kulp [mailto:[EMAIL PROTECTED] Sent: Tuesday, July 17, 2007 11:47 AM To: cxf-user@incubator.apache.org Cc: Clough, Samuel (USPC.PRG.Atlanta) Subject: Re: Wrong number of Arguments Error Samuel, I managed to track this down. It's a bug in the DepthXMLStreamReader that isn't getting the "END_ELEMENT" events lined up correctly in the Aegis binding.Thus, while reading the first object, it's sucking in all the rest of the data so it doesn't deserialize the second parameter. It then tries to invoke your method with only one parameter. I'm testing a fix now.It's a very simple fix. Change the getElementText() method to look like: public String getElementText() throws XMLStreamException { String ret = reader.getElementText(); depth--; return ret; } According to the spec, the getElementText() method consumes the characters and end events and leaves it in the "end" position. This. takes care of keeping the depth correct. In anycase, this probably affects Aegis really badly. Not sure how much of anything in Aegis has worked. Dan On Tuesday 17 July 2007 08:46, Clough, Samuel (USPC.PRG.Atlanta) wrote: > Every time I send this with a code zip attached it is bounced as spam, > so I'll try to send you the code zip offline. > > This is a java first case. What we are doing is hooking up > applications that are completely internal, so the wsdl is not so much > of a concern per se for this application because there are no outside > consumers. We're simply trying to connect a few applications in a > loosely coupled way. > > Any help would be GREATLY appreciated as I was in the middle of the > Xfire learning curve and decided to switch to CXF for the future > growth and I'm a little lost and this error is so vague I can't get > anything on it and google hasn't helped much. We're firing up the > service using these calls: > > AegisDatabinding binding = new AegisDatabinding(); > DefaultTypeMappingRegistry tmr = > (DefaultTypeMappingRegistry) binding.getTypeMappingRegistry(); > Configuration config = tmr.getConfiguration(); > config.setDefaultMinOccurs(1); > config.setDefaultNillable(false); > sf.getServiceFactory().setDataBinding(binding); > sf.setServiceBean(serviceBean); > sf.setServiceClass(serviceClass); > sf.setAddress("http://localhost:8192/omnitranmanager/2007/07/OmniTranS >er vice"); > sf.create(); > > The stack trace: > > INFO: Interceptor has thrown exception, unwinding now > org.apache.cxf.interceptor.Fault: wrong number of arguments > at > org.apache.cxf.service.invoker.AbstractInvoker.invoke(AbstractInvoker. >ja va:88) > at > org.apache.cxf.service.invoker.AbstractInvoker.invoke(AbstractInvoker. >ja va:56) > at > org.apache.cxf.interceptor.ServiceInvokerInterceptor$1.run(ServiceInvo >ke rInterceptor.java:56) > at > org.apache.cxf.workqueue.SynchronousExecutor.execute(SynchronousExecut >or .java:37) > at > org.apache.cxf.interceptor.ServiceInvokerInterceptor.handleMessage(Ser >vi ceInvokerInterceptor.java:87) > at > org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseIntercepto >rC hain.java:206) > at > org.apache.cxf.transport.MultipleEndpointObserver.onMessage(MultipleEn >dp ointObserver.java:82) > at > org.apache.cxf.transport.http_jetty.JettyHTTPDestination.serviceReques >t( JettyHTTPDestination.java:253) > at > org.apache.cxf.transport.http_jetty.JettyHTTPDestination.doService(Jet >ty HTTPDestination.java:213) > at > org.apache.cxf.transport.http_jetty.JettyHTTPHandler.handle(JettyHTTPH >an dler.java:54) > at > org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:71 >2) at > org.mortbay.jetty.handler.ContextHandlerCollection.handle(ContextHandl >er Collection.java:211) > at > org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:13 >9) at org.mortbay.jetty.Server.handle(Server.java:285) > at > org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:502 >) at > org.mortbay.jetty.HttpConnection$RequestHandler.content(HttpConnection >.j ava:835) > at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:641) > at > org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:202) > at > org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:378) > at > org.mortbay.io.nio.SelectChannel
RE: How to enable mtom on the embedded server?
We're trying to convert some services off of XFire and onto CXF. On XFire, the following would automatically enable MTOM for any types in a service that returned a byte array: Service service = serviceFactory.create(FeedbackFilesService.class); service.setInvoker(new BeanInvoker(new FeedbackFilesServiceImpl())); //enable MTOM to send the file contents more efficiently. service.setProperty("mtom-enabled", "true"); I cannot find how to do that easily using the new ServerFactoryBean approach. How do I enable MTOM on a service using the embedded HTTP server? Princeton Retirement Group, Inc - Important Terms This E-mail is not intended for distribution to, or use by, any person or entity in any location where such distribution or use would be contrary to law or regulation, or which would subject Princeton Retirement Group, Inc. or any affiliate to any registration requirement within such location. This E-mail may contain privileged or confidential information or may otherwise be protected by work product immunity or other legal rules. No confidentiality or privilege is waived or lost by any mistransmission. Access, copying or re-use of information by non-intended or non-authorized recipients is prohibited. If you are not an intended recipient of this E-mail, please notify the sender, delete it and do not read, act upon, print, disclose, copy, retain or redistribute any portion of this E-mail. The transmission and content of this E-mail cannot be guaranteed to be secure or error-free. Therefore, we cannot represent that the information in this E-mail is complete, accurate, uncorrupted, timely or free of viruses, and Princeton Retirement Group, Inc. cannot accept any liability for E-mails that have been altered in the course of delivery. Princeton Retirement Group, Inc. reserves the right to monitor, review and retain all electronic communications, including E-mail, traveling through its networks and systems (subject to and in accordance with local laws). If any of your details are incorrect or if you no longer wish to receive mailings such as this by E-mail please contact the sender by reply E-mail.
RE: Wrong number of Arguments Error
Every time I send this with a code zip attached it is bounced as spam, so I'll try to send you the code zip offline. This is a java first case. What we are doing is hooking up applications that are completely internal, so the wsdl is not so much of a concern per se for this application because there are no outside consumers. We're simply trying to connect a few applications in a loosely coupled way. Any help would be GREATLY appreciated as I was in the middle of the Xfire learning curve and decided to switch to CXF for the future growth and I'm a little lost and this error is so vague I can't get anything on it and google hasn't helped much. We're firing up the service using these calls: AegisDatabinding binding = new AegisDatabinding(); DefaultTypeMappingRegistry tmr = (DefaultTypeMappingRegistry) binding.getTypeMappingRegistry(); Configuration config = tmr.getConfiguration(); config.setDefaultMinOccurs(1); config.setDefaultNillable(false); sf.getServiceFactory().setDataBinding(binding); sf.setServiceBean(serviceBean); sf.setServiceClass(serviceClass); sf.setAddress("http://localhost:8192/omnitranmanager/2007/07/OmniTranSer vice"); sf.create(); The stack trace: INFO: Interceptor has thrown exception, unwinding now org.apache.cxf.interceptor.Fault: wrong number of arguments at org.apache.cxf.service.invoker.AbstractInvoker.invoke(AbstractInvoker.ja va:88) at org.apache.cxf.service.invoker.AbstractInvoker.invoke(AbstractInvoker.ja va:56) at org.apache.cxf.interceptor.ServiceInvokerInterceptor$1.run(ServiceInvoke rInterceptor.java:56) at org.apache.cxf.workqueue.SynchronousExecutor.execute(SynchronousExecutor .java:37) at org.apache.cxf.interceptor.ServiceInvokerInterceptor.handleMessage(Servi ceInvokerInterceptor.java:87) at org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorC hain.java:206) at org.apache.cxf.transport.MultipleEndpointObserver.onMessage(MultipleEndp ointObserver.java:82) at org.apache.cxf.transport.http_jetty.JettyHTTPDestination.serviceRequest( JettyHTTPDestination.java:253) at org.apache.cxf.transport.http_jetty.JettyHTTPDestination.doService(Jetty HTTPDestination.java:213) at org.apache.cxf.transport.http_jetty.JettyHTTPHandler.handle(JettyHTTPHan dler.java:54) at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:712) at org.mortbay.jetty.handler.ContextHandlerCollection.handle(ContextHandler Collection.java:211) at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:139) at org.mortbay.jetty.Server.handle(Server.java:285) at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:502) at org.mortbay.jetty.HttpConnection$RequestHandler.content(HttpConnection.j ava:835) at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:641) at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:202) at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:378) at org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java: 368) at org.mortbay.thread.BoundedThreadPool$PoolThread.run(BoundedThreadPool.ja va:442) Caused by: java.lang.IllegalArgumentException: wrong number of arguments at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.jav a:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessor Impl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at org.apache.cxf.service.invoker.AbstractInvoker.invoke(AbstractInvoker.ja va:69) -Original Message- From: Daniel Kulp [mailto:[EMAIL PROTECTED] Sent: Monday, July 16, 2007 4:23 PM To: cxf-user@incubator.apache.org Subject: Re: Wrong number of Arguments Error Is this a "java first" case or a "wsdl first" case? Are there headers or soap w/ attachments involved? Also, is it a "wrapped" doc/lit, "bare" doc/lit, or rpc/lit? If it's a java first case with a wrapped doc/lit endpoint, can you try running java2wsdl with the "-s dir" flags to generate the wrapper types. That SHOULD work better. Is there anyway you can send along the wsdl and the service interface/class? (You can send to me privately if that's preferred) If I can get a reproduceable test case, it should be much easier to debug. Dan On Monday 16 July 2007 15:56, Clough, Samuel (USPC.PRG.Atlanta) wrote: > I'm looking for any help I can get on debugging a "wrong number of > arguments error." I'm getting from a cxf service hosted via the > embedded Jetty server. We just started a new project and used XFire > for the web services and then ripped it out and put in CXF and don't > have much experience w
RE: Getting the HTTP server off the bus
I think it would be helpful on a wiki... -Original Message- From: Benson Margulies [mailto:[EMAIL PROTECTED] Sent: Monday, July 16, 2007 8:55 PM To: cxf-user@incubator.apache.org Subject: RE: Getting the HTTP server off the bus Well, you can ignore the first paragraph. The rest of my analysis turned out to be correct. Would anyone care to see the following on a wiki? EndpointInfo ei = new EndpointInfo(); ei.setAddress(serviceFactory.getAddress()); Destination destination = df.getDestination(ei); JettyHTTPDestination jettyDestination = (JettyHTTPDestination) destination; ServerEngine engine = jettyDestination.getEngine(); Handler handler = engine.getServant(new URL(serviceFactory.getAddress())); org.mortbay.jetty.Server server = handler.getServer(); Handler serverHandler = server.getHandler(); ContextHandlerCollection contextHandlerCollection = (ContextHandlerCollection)serverHandler; HandlerList handlerList = new HandlerList(); ResourceHandler resourceHandler = new ResourceHandler(); handlerList.addHandler(resourceHandler); handlerList.addHandler(contextHandlerCollection); server.setHandler(handlerList); handlerList.start(); File staticContentFile = new File(staticContentPath); URL targetURL = new URL("file://" + staticContentFile.getCanonicalPath()); FileResource fileResource = new FileResource(targetURL); resourceHandler.setBaseResource(fileResource); > -Original Message- > From: Benson Margulies [mailto:[EMAIL PROTECTED] > Sent: Monday, July 16, 2007 8:48 PM > To: cxf-user@incubator.apache.org > Subject: RE: Getting the HTTP server off the bus > > Dan and Willem, > > It looks to me like I'm fairly nearly stuck until you let me fully > control the server wiring unless I'm willing to do some fairly extensive > rewiring of your wiring. > > The jetty doc isn't precisely helpful here, but I have reached the > following tentative view of the situation: > > As things are, the org.mortbay.jetty.Server has, as its singular > handler, a ContextHandlerCollection, which has (at least one) > ContextHandler. ContextHandlers are all about Servlet contexts, of > course. > > Once a ContextHandlerCollection has at least one ContextHandler, it > ignores any ordinary handlers that it has when handling any request that > begins with '/'. > > So, to get a ResourceHandler into the game, I think that I'd have to > create a HandlerList and have that point off to the > ContextHandlerCollection as well as the ResourceHandler, and install it > as the server's handler. > > I have a giant feeling here that there's something basic I'm missing > about Jetty that is supposed to make this easier, but I'm pretty near to > accusing the folks who run the Jetty web site of intentionally making > the version 6 docs less helpful than the version 5 docs to sell more > consulting. > > Probably just sour grapes on my part. > > --benson Princeton Retirement Group, Inc - Important Terms This E-mail is not intended for distribution to, or use by, any person or entity in any location where such distribution or use would be contrary to law or regulation, or which would subject Princeton Retirement Group, Inc. or any affiliate to any registration requirement within such location. This E-mail may contain privileged or confidential information or may otherwise be protected by work product immunity or other legal rules. No confidentiality or privilege is waived or lost by any mistransmission. Access, copying or re-use of information by non-intended or non-authorized recipients is prohibited. If you are not an intended recipient of this E-mail, please notify the sender, delete it and do not read, act upon, print, disclose, copy, retain or redistribute any portion of this E-mail. The transmission and content of this E-mail cannot be guaranteed to be secure or error-free. Therefore, we cannot represent that the information in this E-mail is complete, accurate, uncorrupted, timely or free of viruses, and Princeton Retirement Group, Inc. cannot accept any liability for E-mails that have been altered in the course of delivery. Princeton Retirement Group, Inc. reserves the right to monitor, review and retain all electronic communications, including E-mail, traveling through its networks and systems (subject to and in accordance with local laws). If any of your details are incorrect or if you no longer wish to receive mailings such as this by E-mail please contact the sender by reply E-mail.
RE: Specifying port for the example server
If you're creating multiple services off the embedded http server, just pass the port in the url. If it's different it will automatically listen off of that port for that endpoint. -Original Message- From: Lukas Zapletal [mailto:[EMAIL PROTECTED] Sent: Tuesday, July 17, 2007 6:45 AM To: cxf-user@incubator.apache.org Subject: Specifying port for the example server Hello, can I change the port of the standalone http server? I would like to run two servers on one machine. Thanks -- Lukas Zapletal http://lukas.zapletalovi.com Princeton Retirement Group, Inc - Important Terms This E-mail is not intended for distribution to, or use by, any person or entity in any location where such distribution or use would be contrary to law or regulation, or which would subject Princeton Retirement Group, Inc. or any affiliate to any registration requirement within such location. This E-mail may contain privileged or confidential information or may otherwise be protected by work product immunity or other legal rules. No confidentiality or privilege is waived or lost by any mistransmission. Access, copying or re-use of information by non-intended or non-authorized recipients is prohibited. If you are not an intended recipient of this E-mail, please notify the sender, delete it and do not read, act upon, print, disclose, copy, retain or redistribute any portion of this E-mail. The transmission and content of this E-mail cannot be guaranteed to be secure or error-free. Therefore, we cannot represent that the information in this E-mail is complete, accurate, uncorrupted, timely or free of viruses, and Princeton Retirement Group, Inc. cannot accept any liability for E-mails that have been altered in the course of delivery. Princeton Retirement Group, Inc. reserves the right to monitor, review and retain all electronic communications, including E-mail, traveling through its networks and systems (subject to and in accordance with local laws). If any of your details are incorrect or if you no longer wish to receive mailings such as this by E-mail please contact the sender by reply E-mail.
Wrong number of Arguments Error
I'm looking for any help I can get on debugging a "wrong number of arguments error." I'm getting from a cxf service hosted via the embedded Jetty server. We just started a new project and used XFire for the web services and then ripped it out and put in CXF and don't have much experience with either so I'm definitely on the wrong end of the learning curve. Anyway, for one service that takes an simple object as a parameter is constantly throwing "wrong number of arguments" The stack track points all the way down the Sun reflection calls. I've tried stripping out the boolean and Date properties until I'm left with just 7 String properties and I'm still getting the error every time the service is called. Does anyone have any idea how I can debug this further? I just can't find what is causing the problem and I've spent about 7 hours on this now. Other calls on the same service class work fine and if I strip the parameter class down to just one or two string properties it works. Any help would be greatly appreciated! Princeton Retirement Group, Inc - Important Terms This E-mail is not intended for distribution to, or use by, any person or entity in any location where such distribution or use would be contrary to law or regulation, or which would subject Princeton Retirement Group, Inc. or any affiliate to any registration requirement within such location. This E-mail may contain privileged or confidential information or may otherwise be protected by work product immunity or other legal rules. No confidentiality or privilege is waived or lost by any mistransmission. Access, copying or re-use of information by non-intended or non-authorized recipients is prohibited. If you are not an intended recipient of this E-mail, please notify the sender, delete it and do not read, act upon, print, disclose, copy, retain or redistribute any portion of this E-mail. The transmission and content of this E-mail cannot be guaranteed to be secure or error-free. Therefore, we cannot represent that the information in this E-mail is complete, accurate, uncorrupted, timely or free of viruses, and Princeton Retirement Group, Inc. cannot accept any liability for E-mails that have been altered in the course of delivery. Princeton Retirement Group, Inc. reserves the right to monitor, review and retain all electronic communications, including E-mail, traveling through its networks and systems (subject to and in accordance with local laws). If any of your details are incorrect or if you no longer wish to receive mailings such as this by E-mail please contact the sender by reply E-mail.