Author: ron.sigal(a)jboss.com
Date: 2009-08-29 23:24:24 -0400 (Sat, 29 Aug 2009)
New Revision: 5407
Modified:
remoting2/branches/2.2/docs/guide/en/chap5.xml
Log:
JBREM-1145: Added discussion of "remotingContentType" return header.
Modified: remoting2/branches/2.2/docs/guide/en/chap5.xml
===================================================================
--- remoting2/branches/2.2/docs/guide/en/chap5.xml 2009-08-30 00:47:21 UTC (rev 5406)
+++ remoting2/branches/2.2/docs/guide/en/chap5.xml 2009-08-30 03:24:24 UTC (rev 5407)
@@ -562,8 +562,8 @@
(application/octet-stream).</para>
<para>The handlers receiving http invocations can also set the response
- code, response message, and response headers. To do this, will need to get
- the return payload map from the InvocationRequest passed (via its
+ code, response message, response headers, and content-type. To do this, will
+ need to get the return payload map from the InvocationRequest passed (via its
getReturnPayload() method). Then populate this map with whatever
properties needed. For response code and message, will need to use the
following keys for the map:</para>
@@ -3202,6 +3202,22 @@
<code>org.jboss.remoting.Remoting.PASS_CONFIG_MAP_TO_MARSHAL_FACTORY</code>
(actual value "passConfigMapToMarshalFactory") is set to
"true".</para>
+ <bridgehead>Http marshalling</bridgehead>
+ <para>By default, the http, https, servlet, and sslservlet transports use
+ <classname>org.jboss.remoting.marshal.http.HTTPMarshaller</classname>
and
+ <classname>org.jboss.remoting.marshal.http.HTTPUnMarshaller</classname>,
+ which are distinct from their parent classes
+
<classname>org.jboss.remoting.marshal.serializable.SerializableMarshaller</classname>
+ and
<classname>org.jboss.remoting.marshal.serializable.SerializableUnMarshaller</classname>
+ only insofar as they treat Strings as a special case in the interest of efficiency.
+ However, prior to release 2.2.3.SP1,
<classname>HTTPUnMarshaller</classname> incorrectly
+ uses the content-type set by the
<classname>ServerInvocationHandler</classname> (if
+ any), which would normally apply to the application payload of a response rather
+ than the type of the envelope. As of release 2.2.3.SP1, this behavior remains the
+ default, but it can be corrected by setting the parameter
+
<code>org.jboss.remoting.transport.http.HTTPMetadataConstants.USE_REMOTING_CONTENT_TYPE</code>
+ (actual value "useRemotingContentType") to "true".</para>
+
<bridgehead>Compression marshalling</bridgehead>
<para>A compression marshaller/unmarshaller is available as well which
@@ -6677,6 +6693,16 @@
should throw an exception instead of the orginal error handling behavior of
returning an error message.</para>
+ <para><emphasis
role="bold">USE_REMOTING_CONTENT_TYPE</emphasis> (actual value
+ is 'useRemotingContentType') - key indicating if
+ <classname>org.jboss.remoting.marshal.http.HTTPUnMarshaller</classname>
+ should determine that it is reading a String by using the "content-type"
+ return header (if set to "false") or the "remotingContentType"
header
+ if set to "true". The default value is "false", to avoid
introducing any
+ inconsistent behavior between versions, but, if the
+ <classname>org.jboss.remoting.ServerInvocationHandler</classname> sets
+ the content-type return header, then this parameter should be set to
"true".</para>
+
<para></para>
<para>For every http client request made from remoting client, a remoting
Show replies by date