Sure no problem, I'll have a look and see what's going on. I'm using the latest source from SVN built and prepared for Eclipse using the instructions on the CXF website.
On Mon, Apr 28, 2008 at 4:41 PM, Sergey Beryozkin <[EMAIL PROTECTED]> wrote: > Hi > > I'm a bit busy with the other work at the moment so I don't have time to > debug. I'm just saying that I'm surprised :-) > that something I'd expect to work is not working. Are you using the latest > 2.1 snapshot ? Any chance you can debug a JAXRSInvoker it and see what's > happening ? > > Cheers, Sergey > > > > > > Just checked this by running it through TCPMon and I'm actually getting a > 500: > > > > HTTP/1.1 500 Internal Server Error > > Server: Apache-Coyote/1.1 > > Content-Type: text/xml;charset=UTF-8 > > Content-Length: 201 > > Date: Mon, 28 Apr 2008 15:12:56 GMT > > Connection: close > > > > <ns1:XMLFault > xmlns:ns1="http://cxf.apache.org/bindings/xformat"><ns1:faultstring > > > xmlns:ns1="http://cxf.apache.org/bindings/xformat">javax.ws.rs.WebApplicationException</ns1:faultstring></ns1:XMLFault> > > > > Am I doing the right thing by throwing the WebApplicationException? > > > > > > On Mon, Apr 28, 2008 at 4:06 PM, Brad <[EMAIL PROTECTED]> wrote: > > > > > Hi, > > > > > > I've got a basic test application which I'm trying to get to return > > > HTTP error codes. In th eapplication I'm doing this: > > > > > > throw new WebApplicationException(HttpURLConnection.HTTP_FORBIDDEN); > > > > > > Which gives me this in my browser: > > > > > > <ns1:XMLFault xmlns:ns1="http://cxf.apache.org/bindings/xformat"> > > > <ns1:faultstring > > > > xmlns:ns1="http://cxf.apache.org/bindings/xformat">javax.ws.rs.WebApplicationException</ns1:faultstring> > > > </ns1:XMLFault> > > > > > > I was expecting to see HTTP error 403. The resource class usess > > > application/xml for ProducesMime and ConsumesMime, is that what's > > > stopping me from seeing the HTTP error? > > > > > > Thanks, > > > Brad. > > > > > > > > > > > ---------------------------- > IONA Technologies PLC (registered in Ireland) > Registered Number: 171387 > Registered Address: The IONA Building, Shelbourne Road, Dublin 4, Ireland >
