You are viewing a plain text version of this content. The canonical link for it is here.
Posted to soap-dev@ws.apache.org by Steven McDowall <sj...@aptest.com> on 2000/07/17 21:42:19 UTC
Small change to SOAPAction header...No Quotes!
I ran across a small problem when I tried to get a soap client to connect to
a
"real" soap server..
I need to have a SOAPAction header generated of the form :
SOAPAction: FOO
WHere "FOO" changes depending on certain conditions..However, when I issue
invoke(url, "FOO") it comes out ...
SOAPAction: "FOO"
Note the double quotes.. I recommend highly that we change the code (see
below) to
NOT automatically issue the action around double quotes for the following
reasons:
1) It is very rare to see any HTTP header surround in quotes
2) Some SOAP servers don't want the quotes (at least 1 I know of)
and most importantly ..
3) Whereas the user can explicitly send quotes to invoke:
invoke( url, '\"FOO\"'), there is no way to NOT send quotes in
the current scheme of things.. THis is a bad thing.. :-)
So, with that in mind, here is the simple diff to change the action..
Index: SOAPHTTPConnection.java
===================================================================
RCS file:
/home/cvspublic/xml-soap/java/src/org/apache/soap/transport/http/SOAPHTTPCon
nection.java,v
retrieving revision 1.2
diff -r1.2 SOAPHTTPConnection.java
106c106
< (action != null) ? ('\"' + action + '\"') : "");
---
> (action != null) ? ( action ) : "");
---
Steven J. McDowall phone: +1 763 780-8814
ApTest fax: +1 763 786-8180
e-mail: sjm@aptest.com