[Issue 1255] New - Accept HTTP Header should be "text/xml"

View: New views
3 Messages — Rating Filter:   Alert me  

[Issue 1255] New - Accept HTTP Header should be "text/xml"

by germm :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

https://wsit.dev.java.net/issues/show_bug.cgi?id=1255
                 Issue #|1255
                 Summary|Accept HTTP Header should be "text/xml"
               Component|wsit
                 Version|current
                Platform|All
              OS/Version|All
                     URL|
                  Status|NEW
       Status whiteboard|
                Keywords|
              Resolution|
              Issue type|DEFECT
                Priority|P3
            Subcomponent|jaxws-runtime
             Assigned to|jitu
             Reported by|germm






------- Additional comments from germm@... Thu Sep 17 12:00:56 +0000 2009 -------
I'm developing a client application which uses metro to call a webservice with
the SOAP over HTTP protocol. I saw that metro sets the "Accept" HTTP Header in
the HTTP Request to "text/xml, multipart/related, text/html, image/gif,
image/jpeg, *; q=.2, */*; q=.2".

But the StreamSOAPCodec refuses to process a HTTP Response which has a
Content-Type other than "text/html".

IMHO, the "Accept" HTTP Header should be set to "text/xml" in the HTTP Request.

See the following HTTP Request/Response log:

---[HTTP request - ...]---
Content-type: text/xml;charset="utf-8"
Soapaction: "echoOperation"
Accept: text/xml, multipart/related, text/html, image/gif, image/jpeg, *; q=.2,
*/*; q=.2
<?xml version="1.0" ?><S:Envelope
xmlns:S="http://schemas.xmlsoap.org/soap/envelope/">

---[HTTP response - ... - 500]---
null: HTTP/1.1 500 Internal Server Error
Cache-control: no-cache
Content-type: text/html

com.sun.xml.internal.ws.server.UnsupportedMediaException: Unsupported
Content-Type: text/html Supported ones are: [text/xml]
        at
com.sun.xml.internal.ws.encoding.StreamSOAPCodec.decode(StreamSOAPCodec.java:284)
        at
com.sun.xml.internal.ws.encoding.StreamSOAPCodec.decode(StreamSOAPCodec.java:118)
        at
com.sun.xml.internal.ws.encoding.SOAPBindingCodec.decode(SOAPBindingCodec.java:278)
        at
com.sun.xml.internal.ws.transport.http.client.HttpTransportPipe.process(HttpTransportPipe.java:180)
        at
com.sun.xml.internal.ws.transport.http.client.HttpTransportPipe.processRequest(HttpTransportPipe.java:83)
        at
com.sun.xml.internal.ws.transport.DeferredTransportPipe.processRequest(DeferredTransportPipe.java:105)
        at com.sun.xml.internal.ws.api.pipe.Fiber.__doRun(Fiber.java:587)
        at com.sun.xml.internal.ws.api.pipe.Fiber._doRun(Fiber.java:546)
        at com.sun.xml.internal.ws.api.pipe.Fiber.doRun(Fiber.java:531)
        at com.sun.xml.internal.ws.api.pipe.Fiber.runSync(Fiber.java:428)
        at com.sun.xml.internal.ws.client.Stub.process(Stub.java:211)
        at com.sun.xml.internal.ws.client.sei.SEIStub.doProcess(SEIStub.java:124)
        at
com.sun.xml.internal.ws.client.sei.SyncMethodHandler.invoke(SyncMethodHandler.java:98)
        at
com.sun.xml.internal.ws.client.sei.SyncMethodHandler.invoke(SyncMethodHandler.java:78)
        at com.sun.xml.internal.ws.client.sei.SEIStub.invoke(SEIStub.java:107)
        at $Proxy31.echoOperation(Unknown Source)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@...
For additional commands, e-mail: issues-help@...


[Issue 1255] Accept HTTP Header should be "text/xml"

by scm_issue_link :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

https://wsit.dev.java.net/issues/show_bug.cgi?id=1255






------- Additional comments from scm_issue_link@... Fri Oct 30 01:21:43 +0000 2009 -------
Code changed in jax-ws-sources
User: jitu
Path:
 /jax-ws-sources/jaxws-ri/rt/src/com/sun/xml/ws/encoding/SOAPBindingCodec.java (1.6.2.3)
 http://fisheye5.cenqua.com/changelog/jax-ws-sources/?cs=jaxws22:jitu:20091030012112

Log:
[WSIT-1255] Cleaning up the Accept header.
* It sends only text/xml, multipart/related for SOAP 1.1
* It sends only application/soap+xml, multipart/related for SOAP 1.2
Issue number:  
Obtained from:
Submitted by:  
Reviewed by:  



---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@...
For additional commands, e-mail: issues-help@...


[Issue 1255] Accept HTTP Header should be "text/xml"

by jitu-4 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

https://wsit.dev.java.net/issues/show_bug.cgi?id=1255



User jitu changed the following:

                What    |Old value                 |New value
================================================================================
                  Status|NEW                       |RESOLVED
--------------------------------------------------------------------------------
              Resolution|                          |FIXED
--------------------------------------------------------------------------------
        Target milestone|not determined            |2.0
--------------------------------------------------------------------------------




------- Additional comments from jitu@... Fri Oct 30 01:22:37 +0000 2009 -------
Marking it as fixed.

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@...
For additional commands, e-mail: issues-help@...