[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

microsoft.public.dotnet.framework.remoting

Binary of HTTP config issues

cduden

9/1/2004 12:29:00 AM

I have tried:

Server Web.config:
<system.runtime.remoting>
<application>
<channels>
<channel ref="http">
<serverProviders>
<formatter ref="binary" typeFilterLevel="Full" />
</serverProviders>
</channel>
</channels>
<service>
<wellknown mode="SingleCall" type="NFC.UserManagement.UserManager,
NFC.UserManagement" objectUri="UserManager.rem" />
</service>


</application>
</system.runtime.remoting>

Windows Client:

<system.runtime.remoting>
<application>
<channels>
<channel type="System.Runtime.Remoting.Channels.Http.HttpChannel,
System.Runtime.Remoting"/>
<clientProviders>
<formatter
type="System.Runtime.Remoting.Channels.BinaryClientFormatterSinkProvider,
System.Runtime.Remoting" />
</clientProviders>
</channel>
</channels>
</application>
</system.runtime.remoting>


AND:

Server web config:
<channels>
<channel ref="http">
<serverProviders>
<formatter ref="binary" typeFilterLevel="Full" />
</serverProviders>
</channel>
</channels>


Client config:
<system.runtime.remoting>
<application>
<channels>
<channel ref="http" port="0">
<clientProviders>
<formatter ref="binary" />
</clientProviders>
</channel>
</channels>
</application>
</system.runtime.remoting>

AND Countless other permutations. Using TCPTrace I can see what is being
sent and recieved -- it is either SOAP or it doesn't work. Consequently
the same calls work if I use the following:


SERVER:
<channels>
<channel ref="http">
<serverProviders>
<provider ref="wsdl" />
<formatter ref="soap" typeFilterLevel="Full" />
</serverProviders>
</channel>
</channels>

CLIENT:

<channels>
<channel ref="http" port="0">
<clientProviders>
<formatter ref="soap" />
</clientProviders>
</channel>
</channels>

Using the soap formater. If I attempt to specify the client formatter and
leave the server empty then it works but inspecting the payload reveals that
it is using SOAP. When I try to force binary it fails with the following
error:

Additional information: System.ArgumentNullException: No message was
deserialized prior to calling the DispatchChannelSink.

Parameter name: requestMsg

at
System.Runtime.Remoting.Channels.DispatchChannelSink.ProcessMessage(IServerC
hannelSinkStack sinkStack, IMessage requestMsg, ITransportHeaders
requestHeaders, Stream requestStream, IMessage& responseMsg,
ITransportHeaders& responseHeaders, Stream& responseStream)

at
System.Runtime.Remoting.Channels.BinaryServerFormatterSink.ProcessMessage(IS
erverChannelSinkStack sinkStack, IMessage requestMsg, ITransportHeaders
requestHeaders, Stream requestStream, IMessage& responseMsg,
ITransportHeaders& responseHeaders, Stream& responseStream)

at
System.Runtime.Remoting.Channels.Http.HttpHandlerTransportSink.HandleRequest
(HttpContext context)

at
System.Runtime.Remoting.Channels.Http.HttpRemotingHandler.InternalProcessReq
uest(HttpContext context)



What am I missing here? How do I set this up to work forcing the binary
formatter over HTTP (hosted in IIS).



Thanks,

CMD


10 Answers

Sam Santiago

9/1/2004 12:55:00 AM

0

This works for me:

Server config file hosted in IIS. Nothing special since channel must be
HTTP and client will control formatting:

<system.runtime.remoting>
<application>
<service>
<activated type="My.Class, MyAssembly" />
</service>
</application>
</system.runtime.remoting>

Client Config:

<system.runtime.remoting>
<application name="OrderServicesClient">
<client url="http://localhost:8085/">
<activated type="My.Class, MyAssembly" />
</client>
<channels>
<channel ref="http" port="0">
<clientProviders>
<formatter ref="binary" />
</clientProviders>
</channel>
</channels>
</application>
</system.runtime.remoting>

Thanks,

Sam

--
_______________________________
Sam Santiago
ssantiago@n0spam-SoftiTechture.com
http://www.SoftiTe...
_______________________________
"cduden" <cduden@netfusionservices.com> wrote in message
news:u4aQht7jEHA.644@tk2msftngp13.phx.gbl...
> I have tried:
>
> Server Web.config:
> <system.runtime.remoting>
> <application>
> <channels>
> <channel ref="http">
> <serverProviders>
> <formatter ref="binary" typeFilterLevel="Full" />
> </serverProviders>
> </channel>
> </channels>
> <service>
> <wellknown mode="SingleCall" type="NFC.UserManagement.UserManager,
> NFC.UserManagement" objectUri="UserManager.rem" />
> </service>
>
>
> </application>
> </system.runtime.remoting>
>
> Windows Client:
>
> <system.runtime.remoting>
> <application>
> <channels>
> <channel type="System.Runtime.Remoting.Channels.Http.HttpChannel,
> System.Runtime.Remoting"/>
> <clientProviders>
> <formatter
> type="System.Runtime.Remoting.Channels.BinaryClientFormatterSinkProvider,
> System.Runtime.Remoting" />
> </clientProviders>
> </channel>
> </channels>
> </application>
> </system.runtime.remoting>
>
>
> AND:
>
> Server web config:
> <channels>
> <channel ref="http">
> <serverProviders>
> <formatter ref="binary" typeFilterLevel="Full" />
> </serverProviders>
> </channel>
> </channels>
>
>
> Client config:
> <system.runtime.remoting>
> <application>
> <channels>
> <channel ref="http" port="0">
> <clientProviders>
> <formatter ref="binary" />
> </clientProviders>
> </channel>
> </channels>
> </application>
> </system.runtime.remoting>
>
> AND Countless other permutations. Using TCPTrace I can see what is being
> sent and recieved -- it is either SOAP or it doesn't work. Consequently
> the same calls work if I use the following:
>
>
> SERVER:
> <channels>
> <channel ref="http">
> <serverProviders>
> <provider ref="wsdl" />
> <formatter ref="soap" typeFilterLevel="Full" />
> </serverProviders>
> </channel>
> </channels>
>
> CLIENT:
>
> <channels>
> <channel ref="http" port="0">
> <clientProviders>
> <formatter ref="soap" />
> </clientProviders>
> </channel>
> </channels>
>
> Using the soap formater. If I attempt to specify the client formatter and
> leave the server empty then it works but inspecting the payload reveals
that
> it is using SOAP. When I try to force binary it fails with the following
> error:
>
> Additional information: System.ArgumentNullException: No message was
> deserialized prior to calling the DispatchChannelSink.
>
> Parameter name: requestMsg
>
> at
>
System.Runtime.Remoting.Channels.DispatchChannelSink.ProcessMessage(IServerC
> hannelSinkStack sinkStack, IMessage requestMsg, ITransportHeaders
> requestHeaders, Stream requestStream, IMessage& responseMsg,
> ITransportHeaders& responseHeaders, Stream& responseStream)
>
> at
>
System.Runtime.Remoting.Channels.BinaryServerFormatterSink.ProcessMessage(IS
> erverChannelSinkStack sinkStack, IMessage requestMsg, ITransportHeaders
> requestHeaders, Stream requestStream, IMessage& responseMsg,
> ITransportHeaders& responseHeaders, Stream& responseStream)
>
> at
>
System.Runtime.Remoting.Channels.Http.HttpHandlerTransportSink.HandleRequest
> (HttpContext context)
>
> at
>
System.Runtime.Remoting.Channels.Http.HttpRemotingHandler.InternalProcessReq
> uest(HttpContext context)
>
>
>
> What am I missing here? How do I set this up to work forcing the binary
> formatter over HTTP (hosted in IIS).
>
>
>
> Thanks,
>
> CMD
>
>


cduden

9/1/2004 1:02:00 AM

0

I just cut and pasted your config settings into my server web config and
client appconfig. It works great for me too Sam except when I inspect the
payload of the traffic between client and server it is a soap envelope so I
don't think that the binary serialization is actually happening.


"Sam Santiago" <ssantiago@n0spam-SoftiTechture.com> wrote in message
news:%23rQMM57jEHA.3944@tk2msftngp13.phx.gbl...
> This works for me:
>
> Server config file hosted in IIS. Nothing special since channel must be
> HTTP and client will control formatting:
>
> <system.runtime.remoting>
> <application>
> <service>
> <activated type="My.Class, MyAssembly" />
> </service>
> </application>
> </system.runtime.remoting>
>
> Client Config:
>
> <system.runtime.remoting>
> <application name="OrderServicesClient">
> <client url="http://localhost:8085/">
> <activated type="My.Class, MyAssembly" />
> </client>
> <channels>
> <channel ref="http" port="0">
> <clientProviders>
> <formatter ref="binary" />
> </clientProviders>
> </channel>
> </channels>
> </application>
> </system.runtime.remoting>
>
> Thanks,
>
> Sam
>
> --
> _______________________________
> Sam Santiago
> ssantiago@n0spam-SoftiTechture.com
> http://www.SoftiTe...
> _______________________________
> "cduden" <cduden@netfusionservices.com> wrote in message
> news:u4aQht7jEHA.644@tk2msftngp13.phx.gbl...
> > I have tried:
> >
> > Server Web.config:
> > <system.runtime.remoting>
> > <application>
> > <channels>
> > <channel ref="http">
> > <serverProviders>
> > <formatter ref="binary" typeFilterLevel="Full" />
> > </serverProviders>
> > </channel>
> > </channels>
> > <service>
> > <wellknown mode="SingleCall" type="NFC.UserManagement.UserManager,
> > NFC.UserManagement" objectUri="UserManager.rem" />
> > </service>
> >
> >
> > </application>
> > </system.runtime.remoting>
> >
> > Windows Client:
> >
> > <system.runtime.remoting>
> > <application>
> > <channels>
> > <channel type="System.Runtime.Remoting.Channels.Http.HttpChannel,
> > System.Runtime.Remoting"/>
> > <clientProviders>
> > <formatter
> >
type="System.Runtime.Remoting.Channels.BinaryClientFormatterSinkProvider,
> > System.Runtime.Remoting" />
> > </clientProviders>
> > </channel>
> > </channels>
> > </application>
> > </system.runtime.remoting>
> >
> >
> > AND:
> >
> > Server web config:
> > <channels>
> > <channel ref="http">
> > <serverProviders>
> > <formatter ref="binary" typeFilterLevel="Full" />
> > </serverProviders>
> > </channel>
> > </channels>
> >
> >
> > Client config:
> > <system.runtime.remoting>
> > <application>
> > <channels>
> > <channel ref="http" port="0">
> > <clientProviders>
> > <formatter ref="binary" />
> > </clientProviders>
> > </channel>
> > </channels>
> > </application>
> > </system.runtime.remoting>
> >
> > AND Countless other permutations. Using TCPTrace I can see what is
being
> > sent and recieved -- it is either SOAP or it doesn't work.
Consequently
> > the same calls work if I use the following:
> >
> >
> > SERVER:
> > <channels>
> > <channel ref="http">
> > <serverProviders>
> > <provider ref="wsdl" />
> > <formatter ref="soap" typeFilterLevel="Full" />
> > </serverProviders>
> > </channel>
> > </channels>
> >
> > CLIENT:
> >
> > <channels>
> > <channel ref="http" port="0">
> > <clientProviders>
> > <formatter ref="soap" />
> > </clientProviders>
> > </channel>
> > </channels>
> >
> > Using the soap formater. If I attempt to specify the client formatter
and
> > leave the server empty then it works but inspecting the payload reveals
> that
> > it is using SOAP. When I try to force binary it fails with the
following
> > error:
> >
> > Additional information: System.ArgumentNullException: No message was
> > deserialized prior to calling the DispatchChannelSink.
> >
> > Parameter name: requestMsg
> >
> > at
> >
>
System.Runtime.Remoting.Channels.DispatchChannelSink.ProcessMessage(IServerC
> > hannelSinkStack sinkStack, IMessage requestMsg, ITransportHeaders
> > requestHeaders, Stream requestStream, IMessage& responseMsg,
> > ITransportHeaders& responseHeaders, Stream& responseStream)
> >
> > at
> >
>
System.Runtime.Remoting.Channels.BinaryServerFormatterSink.ProcessMessage(IS
> > erverChannelSinkStack sinkStack, IMessage requestMsg, ITransportHeaders
> > requestHeaders, Stream requestStream, IMessage& responseMsg,
> > ITransportHeaders& responseHeaders, Stream& responseStream)
> >
> > at
> >
>
System.Runtime.Remoting.Channels.Http.HttpHandlerTransportSink.HandleRequest
> > (HttpContext context)
> >
> > at
> >
>
System.Runtime.Remoting.Channels.Http.HttpRemotingHandler.InternalProcessReq
> > uest(HttpContext context)
> >
> >
> >
> > What am I missing here? How do I set this up to work forcing the binary
> > formatter over HTTP (hosted in IIS).
> >
> >
> >
> > Thanks,
> >
> > CMD
> >
> >
>
>


Sam Santiago

9/1/2004 1:16:00 AM

0

I see binary for sure. I'm using the ethereal network protocol analyzer:
http://www.eth.... The HTTP content type is Content-Type:
application/octet-stream. It's an open source analyzer so try it out.

Thanks,

Sam

--
_______________________________
Sam Santiago
ssantiago@n0spam-SoftiTechture.com
http://www.SoftiTe...
_______________________________
"cduden" <cduden@netfusionservices.com> wrote in message
news:unfrz$7jEHA.2340@TK2MSFTNGP11.phx.gbl...
> I just cut and pasted your config settings into my server web config and
> client appconfig. It works great for me too Sam except when I inspect the
> payload of the traffic between client and server it is a soap envelope so
I
> don't think that the binary serialization is actually happening.
>
>
> "Sam Santiago" <ssantiago@n0spam-SoftiTechture.com> wrote in message
> news:%23rQMM57jEHA.3944@tk2msftngp13.phx.gbl...
> > This works for me:
> >
> > Server config file hosted in IIS. Nothing special since channel must be
> > HTTP and client will control formatting:
> >
> > <system.runtime.remoting>
> > <application>
> > <service>
> > <activated type="My.Class, MyAssembly" />
> > </service>
> > </application>
> > </system.runtime.remoting>
> >
> > Client Config:
> >
> > <system.runtime.remoting>
> > <application name="OrderServicesClient">
> > <client url="http://localhost:8085/">
> > <activated type="My.Class, MyAssembly" />
> > </client>
> > <channels>
> > <channel ref="http" port="0">
> > <clientProviders>
> > <formatter ref="binary" />
> > </clientProviders>
> > </channel>
> > </channels>
> > </application>
> > </system.runtime.remoting>
> >
> > Thanks,
> >
> > Sam
> >
> > --
> > _______________________________
> > Sam Santiago
> > ssantiago@n0spam-SoftiTechture.com
> > http://www.SoftiTe...
> > _______________________________
> > "cduden" <cduden@netfusionservices.com> wrote in message
> > news:u4aQht7jEHA.644@tk2msftngp13.phx.gbl...
> > > I have tried:
> > >
> > > Server Web.config:
> > > <system.runtime.remoting>
> > > <application>
> > > <channels>
> > > <channel ref="http">
> > > <serverProviders>
> > > <formatter ref="binary" typeFilterLevel="Full" />
> > > </serverProviders>
> > > </channel>
> > > </channels>
> > > <service>
> > > <wellknown mode="SingleCall" type="NFC.UserManagement.UserManager,
> > > NFC.UserManagement" objectUri="UserManager.rem" />
> > > </service>
> > >
> > >
> > > </application>
> > > </system.runtime.remoting>
> > >
> > > Windows Client:
> > >
> > > <system.runtime.remoting>
> > > <application>
> > > <channels>
> > > <channel type="System.Runtime.Remoting.Channels.Http.HttpChannel,
> > > System.Runtime.Remoting"/>
> > > <clientProviders>
> > > <formatter
> > >
> type="System.Runtime.Remoting.Channels.BinaryClientFormatterSinkProvider,
> > > System.Runtime.Remoting" />
> > > </clientProviders>
> > > </channel>
> > > </channels>
> > > </application>
> > > </system.runtime.remoting>
> > >
> > >
> > > AND:
> > >
> > > Server web config:
> > > <channels>
> > > <channel ref="http">
> > > <serverProviders>
> > > <formatter ref="binary" typeFilterLevel="Full" />
> > > </serverProviders>
> > > </channel>
> > > </channels>
> > >
> > >
> > > Client config:
> > > <system.runtime.remoting>
> > > <application>
> > > <channels>
> > > <channel ref="http" port="0">
> > > <clientProviders>
> > > <formatter ref="binary" />
> > > </clientProviders>
> > > </channel>
> > > </channels>
> > > </application>
> > > </system.runtime.remoting>
> > >
> > > AND Countless other permutations. Using TCPTrace I can see what is
> being
> > > sent and recieved -- it is either SOAP or it doesn't work.
> Consequently
> > > the same calls work if I use the following:
> > >
> > >
> > > SERVER:
> > > <channels>
> > > <channel ref="http">
> > > <serverProviders>
> > > <provider ref="wsdl" />
> > > <formatter ref="soap" typeFilterLevel="Full" />
> > > </serverProviders>
> > > </channel>
> > > </channels>
> > >
> > > CLIENT:
> > >
> > > <channels>
> > > <channel ref="http" port="0">
> > > <clientProviders>
> > > <formatter ref="soap" />
> > > </clientProviders>
> > > </channel>
> > > </channels>
> > >
> > > Using the soap formater. If I attempt to specify the client formatter
> and
> > > leave the server empty then it works but inspecting the payload
reveals
> > that
> > > it is using SOAP. When I try to force binary it fails with the
> following
> > > error:
> > >
> > > Additional information: System.ArgumentNullException: No message was
> > > deserialized prior to calling the DispatchChannelSink.
> > >
> > > Parameter name: requestMsg
> > >
> > > at
> > >
> >
>
System.Runtime.Remoting.Channels.DispatchChannelSink.ProcessMessage(IServerC
> > > hannelSinkStack sinkStack, IMessage requestMsg, ITransportHeaders
> > > requestHeaders, Stream requestStream, IMessage& responseMsg,
> > > ITransportHeaders& responseHeaders, Stream& responseStream)
> > >
> > > at
> > >
> >
>
System.Runtime.Remoting.Channels.BinaryServerFormatterSink.ProcessMessage(IS
> > > erverChannelSinkStack sinkStack, IMessage requestMsg,
ITransportHeaders
> > > requestHeaders, Stream requestStream, IMessage& responseMsg,
> > > ITransportHeaders& responseHeaders, Stream& responseStream)
> > >
> > > at
> > >
> >
>
System.Runtime.Remoting.Channels.Http.HttpHandlerTransportSink.HandleRequest
> > > (HttpContext context)
> > >
> > > at
> > >
> >
>
System.Runtime.Remoting.Channels.Http.HttpRemotingHandler.InternalProcessReq
> > > uest(HttpContext context)
> > >
> > >
> > >
> > > What am I missing here? How do I set this up to work forcing the
binary
> > > formatter over HTTP (hosted in IIS).
> > >
> > >
> > >
> > > Thanks,
> > >
> > > CMD
> > >
> > >
> >
> >
>
>


cduden

9/1/2004 4:42:00 AM

0

Ok, Ethereal looks a bit more comprehensive than what I am using, thanks.
Assuming that it is using Binary -- if I use the following:

Server:

No channels defined, just the services

Client:
<channels>
<channel ref="http" port="0">
<clientProviders>
<formatter ref="binary" />
</clientProviders>
</channel>
</channels>

It works. Question

given that the above will function when I add the following to the server
config:

<channels>
<channel ref="http">
<serverProviders>
<formatter ref="binary" />
</serverProviders>
</channel>
</channels>
It ceases to function. Any insight in to why that is? I get the error
listed above.


"Sam Santiago" <ssantiago@n0spam-SoftiTechture.com> wrote in message
news:OTMq9E8jEHA.3696@TK2MSFTNGP15.phx.gbl...
> I see binary for sure. I'm using the ethereal network protocol analyzer:
> http://www.eth.... The HTTP content type is Content-Type:
> application/octet-stream. It's an open source analyzer so try it out.
>
> Thanks,
>
> Sam
>
> --
> _______________________________
> Sam Santiago
> ssantiago@n0spam-SoftiTechture.com
> http://www.SoftiTe...
> _______________________________
> "cduden" <cduden@netfusionservices.com> wrote in message
> news:unfrz$7jEHA.2340@TK2MSFTNGP11.phx.gbl...
> > I just cut and pasted your config settings into my server web config and
> > client appconfig. It works great for me too Sam except when I inspect
the
> > payload of the traffic between client and server it is a soap envelope
so
> I
> > don't think that the binary serialization is actually happening.
> >
> >
> > "Sam Santiago" <ssantiago@n0spam-SoftiTechture.com> wrote in message
> > news:%23rQMM57jEHA.3944@tk2msftngp13.phx.gbl...
> > > This works for me:
> > >
> > > Server config file hosted in IIS. Nothing special since channel must
be
> > > HTTP and client will control formatting:
> > >
> > > <system.runtime.remoting>
> > > <application>
> > > <service>
> > > <activated type="My.Class, MyAssembly" />
> > > </service>
> > > </application>
> > > </system.runtime.remoting>
> > >
> > > Client Config:
> > >
> > > <system.runtime.remoting>
> > > <application name="OrderServicesClient">
> > > <client url="http://localhost:8085/">
> > > <activated type="My.Class, MyAssembly" />
> > > </client>
> > > <channels>
> > > <channel ref="http" port="0">
> > > <clientProviders>
> > > <formatter ref="binary" />
> > > </clientProviders>
> > > </channel>
> > > </channels>
> > > </application>
> > > </system.runtime.remoting>
> > >
> > > Thanks,
> > >
> > > Sam
> > >
> > > --
> > > _______________________________
> > > Sam Santiago
> > > ssantiago@n0spam-SoftiTechture.com
> > > http://www.SoftiTe...
> > > _______________________________
> > > "cduden" <cduden@netfusionservices.com> wrote in message
> > > news:u4aQht7jEHA.644@tk2msftngp13.phx.gbl...
> > > > I have tried:
> > > >
> > > > Server Web.config:
> > > > <system.runtime.remoting>
> > > > <application>
> > > > <channels>
> > > > <channel ref="http">
> > > > <serverProviders>
> > > > <formatter ref="binary" typeFilterLevel="Full" />
> > > > </serverProviders>
> > > > </channel>
> > > > </channels>
> > > > <service>
> > > > <wellknown mode="SingleCall"
type="NFC.UserManagement.UserManager,
> > > > NFC.UserManagement" objectUri="UserManager.rem" />
> > > > </service>
> > > >
> > > >
> > > > </application>
> > > > </system.runtime.remoting>
> > > >
> > > > Windows Client:
> > > >
> > > > <system.runtime.remoting>
> > > > <application>
> > > > <channels>
> > > > <channel
type="System.Runtime.Remoting.Channels.Http.HttpChannel,
> > > > System.Runtime.Remoting"/>
> > > > <clientProviders>
> > > > <formatter
> > > >
> >
type="System.Runtime.Remoting.Channels.BinaryClientFormatterSinkProvider,
> > > > System.Runtime.Remoting" />
> > > > </clientProviders>
> > > > </channel>
> > > > </channels>
> > > > </application>
> > > > </system.runtime.remoting>
> > > >
> > > >
> > > > AND:
> > > >
> > > > Server web config:
> > > > <channels>
> > > > <channel ref="http">
> > > > <serverProviders>
> > > > <formatter ref="binary" typeFilterLevel="Full" />
> > > > </serverProviders>
> > > > </channel>
> > > > </channels>
> > > >
> > > >
> > > > Client config:
> > > > <system.runtime.remoting>
> > > > <application>
> > > > <channels>
> > > > <channel ref="http" port="0">
> > > > <clientProviders>
> > > > <formatter ref="binary" />
> > > > </clientProviders>
> > > > </channel>
> > > > </channels>
> > > > </application>
> > > > </system.runtime.remoting>
> > > >
> > > > AND Countless other permutations. Using TCPTrace I can see what is
> > being
> > > > sent and recieved -- it is either SOAP or it doesn't work.
> > Consequently
> > > > the same calls work if I use the following:
> > > >
> > > >
> > > > SERVER:
> > > > <channels>
> > > > <channel ref="http">
> > > > <serverProviders>
> > > > <provider ref="wsdl" />
> > > > <formatter ref="soap" typeFilterLevel="Full" />
> > > > </serverProviders>
> > > > </channel>
> > > > </channels>
> > > >
> > > > CLIENT:
> > > >
> > > > <channels>
> > > > <channel ref="http" port="0">
> > > > <clientProviders>
> > > > <formatter ref="soap" />
> > > > </clientProviders>
> > > > </channel>
> > > > </channels>
> > > >
> > > > Using the soap formater. If I attempt to specify the client
formatter
> > and
> > > > leave the server empty then it works but inspecting the payload
> reveals
> > > that
> > > > it is using SOAP. When I try to force binary it fails with the
> > following
> > > > error:
> > > >
> > > > Additional information: System.ArgumentNullException: No message was
> > > > deserialized prior to calling the DispatchChannelSink.
> > > >
> > > > Parameter name: requestMsg
> > > >
> > > > at
> > > >
> > >
> >
>
System.Runtime.Remoting.Channels.DispatchChannelSink.ProcessMessage(IServerC
> > > > hannelSinkStack sinkStack, IMessage requestMsg, ITransportHeaders
> > > > requestHeaders, Stream requestStream, IMessage& responseMsg,
> > > > ITransportHeaders& responseHeaders, Stream& responseStream)
> > > >
> > > > at
> > > >
> > >
> >
>
System.Runtime.Remoting.Channels.BinaryServerFormatterSink.ProcessMessage(IS
> > > > erverChannelSinkStack sinkStack, IMessage requestMsg,
> ITransportHeaders
> > > > requestHeaders, Stream requestStream, IMessage& responseMsg,
> > > > ITransportHeaders& responseHeaders, Stream& responseStream)
> > > >
> > > > at
> > > >
> > >
> >
>
System.Runtime.Remoting.Channels.Http.HttpHandlerTransportSink.HandleRequest
> > > > (HttpContext context)
> > > >
> > > > at
> > > >
> > >
> >
>
System.Runtime.Remoting.Channels.Http.HttpRemotingHandler.InternalProcessReq
> > > > uest(HttpContext context)
> > > >
> > > >
> > > >
> > > > What am I missing here? How do I set this up to work forcing the
> binary
> > > > formatter over HTTP (hosted in IIS).
> > > >
> > > >
> > > >
> > > > Thanks,
> > > >
> > > > CMD
> > > >
> > > >
> > >
> > >
> >
> >
>
>


cduden

9/1/2004 5:32:00 AM

0

Sam, I have spent the last hour looking at Ethereal, how do you make it
analyze traffic on the local machine, I only seem to be able to connect to
one of my network adapters and it doesn't seem to pick up traffic on the
local machine (client --> web server)


"Sam Santiago" <ssantiago@n0spam-SoftiTechture.com> wrote in message
news:OTMq9E8jEHA.3696@TK2MSFTNGP15.phx.gbl...
> I see binary for sure. I'm using the ethereal network protocol analyzer:
> http://www.eth.... The HTTP content type is Content-Type:
> application/octet-stream. It's an open source analyzer so try it out.
>
> Thanks,
>
> Sam
>
> --
> _______________________________
> Sam Santiago
> ssantiago@n0spam-SoftiTechture.com
> http://www.SoftiTe...
> _______________________________
> "cduden" <cduden@netfusionservices.com> wrote in message
> news:unfrz$7jEHA.2340@TK2MSFTNGP11.phx.gbl...
> > I just cut and pasted your config settings into my server web config and
> > client appconfig. It works great for me too Sam except when I inspect
the
> > payload of the traffic between client and server it is a soap envelope
so
> I
> > don't think that the binary serialization is actually happening.
> >
> >
> > "Sam Santiago" <ssantiago@n0spam-SoftiTechture.com> wrote in message
> > news:%23rQMM57jEHA.3944@tk2msftngp13.phx.gbl...
> > > This works for me:
> > >
> > > Server config file hosted in IIS. Nothing special since channel must
be
> > > HTTP and client will control formatting:
> > >
> > > <system.runtime.remoting>
> > > <application>
> > > <service>
> > > <activated type="My.Class, MyAssembly" />
> > > </service>
> > > </application>
> > > </system.runtime.remoting>
> > >
> > > Client Config:
> > >
> > > <system.runtime.remoting>
> > > <application name="OrderServicesClient">
> > > <client url="http://localhost:8085/">
> > > <activated type="My.Class, MyAssembly" />
> > > </client>
> > > <channels>
> > > <channel ref="http" port="0">
> > > <clientProviders>
> > > <formatter ref="binary" />
> > > </clientProviders>
> > > </channel>
> > > </channels>
> > > </application>
> > > </system.runtime.remoting>
> > >
> > > Thanks,
> > >
> > > Sam
> > >
> > > --
> > > _______________________________
> > > Sam Santiago
> > > ssantiago@n0spam-SoftiTechture.com
> > > http://www.SoftiTe...
> > > _______________________________
> > > "cduden" <cduden@netfusionservices.com> wrote in message
> > > news:u4aQht7jEHA.644@tk2msftngp13.phx.gbl...
> > > > I have tried:
> > > >
> > > > Server Web.config:
> > > > <system.runtime.remoting>
> > > > <application>
> > > > <channels>
> > > > <channel ref="http">
> > > > <serverProviders>
> > > > <formatter ref="binary" typeFilterLevel="Full" />
> > > > </serverProviders>
> > > > </channel>
> > > > </channels>
> > > > <service>
> > > > <wellknown mode="SingleCall"
type="NFC.UserManagement.UserManager,
> > > > NFC.UserManagement" objectUri="UserManager.rem" />
> > > > </service>
> > > >
> > > >
> > > > </application>
> > > > </system.runtime.remoting>
> > > >
> > > > Windows Client:
> > > >
> > > > <system.runtime.remoting>
> > > > <application>
> > > > <channels>
> > > > <channel
type="System.Runtime.Remoting.Channels.Http.HttpChannel,
> > > > System.Runtime.Remoting"/>
> > > > <clientProviders>
> > > > <formatter
> > > >
> >
type="System.Runtime.Remoting.Channels.BinaryClientFormatterSinkProvider,
> > > > System.Runtime.Remoting" />
> > > > </clientProviders>
> > > > </channel>
> > > > </channels>
> > > > </application>
> > > > </system.runtime.remoting>
> > > >
> > > >
> > > > AND:
> > > >
> > > > Server web config:
> > > > <channels>
> > > > <channel ref="http">
> > > > <serverProviders>
> > > > <formatter ref="binary" typeFilterLevel="Full" />
> > > > </serverProviders>
> > > > </channel>
> > > > </channels>
> > > >
> > > >
> > > > Client config:
> > > > <system.runtime.remoting>
> > > > <application>
> > > > <channels>
> > > > <channel ref="http" port="0">
> > > > <clientProviders>
> > > > <formatter ref="binary" />
> > > > </clientProviders>
> > > > </channel>
> > > > </channels>
> > > > </application>
> > > > </system.runtime.remoting>
> > > >
> > > > AND Countless other permutations. Using TCPTrace I can see what is
> > being
> > > > sent and recieved -- it is either SOAP or it doesn't work.
> > Consequently
> > > > the same calls work if I use the following:
> > > >
> > > >
> > > > SERVER:
> > > > <channels>
> > > > <channel ref="http">
> > > > <serverProviders>
> > > > <provider ref="wsdl" />
> > > > <formatter ref="soap" typeFilterLevel="Full" />
> > > > </serverProviders>
> > > > </channel>
> > > > </channels>
> > > >
> > > > CLIENT:
> > > >
> > > > <channels>
> > > > <channel ref="http" port="0">
> > > > <clientProviders>
> > > > <formatter ref="soap" />
> > > > </clientProviders>
> > > > </channel>
> > > > </channels>
> > > >
> > > > Using the soap formater. If I attempt to specify the client
formatter
> > and
> > > > leave the server empty then it works but inspecting the payload
> reveals
> > > that
> > > > it is using SOAP. When I try to force binary it fails with the
> > following
> > > > error:
> > > >
> > > > Additional information: System.ArgumentNullException: No message was
> > > > deserialized prior to calling the DispatchChannelSink.
> > > >
> > > > Parameter name: requestMsg
> > > >
> > > > at
> > > >
> > >
> >
>
System.Runtime.Remoting.Channels.DispatchChannelSink.ProcessMessage(IServerC
> > > > hannelSinkStack sinkStack, IMessage requestMsg, ITransportHeaders
> > > > requestHeaders, Stream requestStream, IMessage& responseMsg,
> > > > ITransportHeaders& responseHeaders, Stream& responseStream)
> > > >
> > > > at
> > > >
> > >
> >
>
System.Runtime.Remoting.Channels.BinaryServerFormatterSink.ProcessMessage(IS
> > > > erverChannelSinkStack sinkStack, IMessage requestMsg,
> ITransportHeaders
> > > > requestHeaders, Stream requestStream, IMessage& responseMsg,
> > > > ITransportHeaders& responseHeaders, Stream& responseStream)
> > > >
> > > > at
> > > >
> > >
> >
>
System.Runtime.Remoting.Channels.Http.HttpHandlerTransportSink.HandleRequest
> > > > (HttpContext context)
> > > >
> > > > at
> > > >
> > >
> >
>
System.Runtime.Remoting.Channels.Http.HttpRemotingHandler.InternalProcessReq
> > > > uest(HttpContext context)
> > > >
> > > >
> > > >
> > > > What am I missing here? How do I set this up to work forcing the
> binary
> > > > formatter over HTTP (hosted in IIS).
> > > >
> > > >
> > > >
> > > > Thanks,
> > > >
> > > > CMD
> > > >
> > > >
> > >
> > >
> >
> >
>
>


Sam Santiago

9/1/2004 5:52:00 AM

0

Not sure, but when you see the packet trace you might see that you are
getting back some kind of HTTP error response vs. a binary stream therefore
causing a bogus error.

Here's another example of using the binary formatter with IIS and HTTP:

Remoting Example: Hosting in Internet Information Services
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/cpguide/html/cpconremotingexamplehostin...

With Ethereal, once you see an HTTP packet, right click on it and select
Follow TCP Stream to view a window that's more readable. Click the Clear
button if you want to go back to full output list.

Thanks,

Sam

--
_______________________________
Sam Santiago
ssantiago@n0spam-SoftiTechture.com
http://www.SoftiTe...
_______________________________
"cduden" <cduden@netfusionservices.com> wrote in message
news:%23Yhzd69jEHA.1136@tk2msftngp13.phx.gbl...
> Ok, Ethereal looks a bit more comprehensive than what I am using, thanks.
> Assuming that it is using Binary -- if I use the following:
>
> Server:
>
> No channels defined, just the services
>
> Client:
> <channels>
> <channel ref="http" port="0">
> <clientProviders>
> <formatter ref="binary" />
> </clientProviders>
> </channel>
> </channels>
>
> It works. Question
>
> given that the above will function when I add the following to the server
> config:
>
> <channels>
> <channel ref="http">
> <serverProviders>
> <formatter ref="binary" />
> </serverProviders>
> </channel>
> </channels>
> It ceases to function. Any insight in to why that is? I get the error
> listed above.
>
>
> "Sam Santiago" <ssantiago@n0spam-SoftiTechture.com> wrote in message
> news:OTMq9E8jEHA.3696@TK2MSFTNGP15.phx.gbl...
> > I see binary for sure. I'm using the ethereal network protocol
analyzer:
> > http://www.eth.... The HTTP content type is Content-Type:
> > application/octet-stream. It's an open source analyzer so try it out.
> >
> > Thanks,
> >
> > Sam
> >
> > --
> > _______________________________
> > Sam Santiago
> > ssantiago@n0spam-SoftiTechture.com
> > http://www.SoftiTe...
> > _______________________________
> > "cduden" <cduden@netfusionservices.com> wrote in message
> > news:unfrz$7jEHA.2340@TK2MSFTNGP11.phx.gbl...
> > > I just cut and pasted your config settings into my server web config
and
> > > client appconfig. It works great for me too Sam except when I inspect
> the
> > > payload of the traffic between client and server it is a soap envelope
> so
> > I
> > > don't think that the binary serialization is actually happening.
> > >
> > >
> > > "Sam Santiago" <ssantiago@n0spam-SoftiTechture.com> wrote in message
> > > news:%23rQMM57jEHA.3944@tk2msftngp13.phx.gbl...
> > > > This works for me:
> > > >
> > > > Server config file hosted in IIS. Nothing special since channel
must
> be
> > > > HTTP and client will control formatting:
> > > >
> > > > <system.runtime.remoting>
> > > > <application>
> > > > <service>
> > > > <activated type="My.Class, MyAssembly" />
> > > > </service>
> > > > </application>
> > > > </system.runtime.remoting>
> > > >
> > > > Client Config:
> > > >
> > > > <system.runtime.remoting>
> > > > <application name="OrderServicesClient">
> > > > <client url="http://localhost:8085/">
> > > > <activated type="My.Class, MyAssembly" />
> > > > </client>
> > > > <channels>
> > > > <channel ref="http" port="0">
> > > > <clientProviders>
> > > > <formatter ref="binary" />
> > > > </clientProviders>
> > > > </channel>
> > > > </channels>
> > > > </application>
> > > > </system.runtime.remoting>
> > > >
> > > > Thanks,
> > > >
> > > > Sam
> > > >
> > > > --
> > > > _______________________________
> > > > Sam Santiago
> > > > ssantiago@n0spam-SoftiTechture.com
> > > > http://www.SoftiTe...
> > > > _______________________________
> > > > "cduden" <cduden@netfusionservices.com> wrote in message
> > > > news:u4aQht7jEHA.644@tk2msftngp13.phx.gbl...
> > > > > I have tried:
> > > > >
> > > > > Server Web.config:
> > > > > <system.runtime.remoting>
> > > > > <application>
> > > > > <channels>
> > > > > <channel ref="http">
> > > > > <serverProviders>
> > > > > <formatter ref="binary" typeFilterLevel="Full" />
> > > > > </serverProviders>
> > > > > </channel>
> > > > > </channels>
> > > > > <service>
> > > > > <wellknown mode="SingleCall"
> type="NFC.UserManagement.UserManager,
> > > > > NFC.UserManagement" objectUri="UserManager.rem" />
> > > > > </service>
> > > > >
> > > > >
> > > > > </application>
> > > > > </system.runtime.remoting>
> > > > >
> > > > > Windows Client:
> > > > >
> > > > > <system.runtime.remoting>
> > > > > <application>
> > > > > <channels>
> > > > > <channel
> type="System.Runtime.Remoting.Channels.Http.HttpChannel,
> > > > > System.Runtime.Remoting"/>
> > > > > <clientProviders>
> > > > > <formatter
> > > > >
> > >
> type="System.Runtime.Remoting.Channels.BinaryClientFormatterSinkProvider,
> > > > > System.Runtime.Remoting" />
> > > > > </clientProviders>
> > > > > </channel>
> > > > > </channels>
> > > > > </application>
> > > > > </system.runtime.remoting>
> > > > >
> > > > >
> > > > > AND:
> > > > >
> > > > > Server web config:
> > > > > <channels>
> > > > > <channel ref="http">
> > > > > <serverProviders>
> > > > > <formatter ref="binary" typeFilterLevel="Full" />
> > > > > </serverProviders>
> > > > > </channel>
> > > > > </channels>
> > > > >
> > > > >
> > > > > Client config:
> > > > > <system.runtime.remoting>
> > > > > <application>
> > > > > <channels>
> > > > > <channel ref="http" port="0">
> > > > > <clientProviders>
> > > > > <formatter ref="binary" />
> > > > > </clientProviders>
> > > > > </channel>
> > > > > </channels>
> > > > > </application>
> > > > > </system.runtime.remoting>
> > > > >
> > > > > AND Countless other permutations. Using TCPTrace I can see what
is
> > > being
> > > > > sent and recieved -- it is either SOAP or it doesn't work.
> > > Consequently
> > > > > the same calls work if I use the following:
> > > > >
> > > > >
> > > > > SERVER:
> > > > > <channels>
> > > > > <channel ref="http">
> > > > > <serverProviders>
> > > > > <provider ref="wsdl" />
> > > > > <formatter ref="soap" typeFilterLevel="Full" />
> > > > > </serverProviders>
> > > > > </channel>
> > > > > </channels>
> > > > >
> > > > > CLIENT:
> > > > >
> > > > > <channels>
> > > > > <channel ref="http" port="0">
> > > > > <clientProviders>
> > > > > <formatter ref="soap" />
> > > > > </clientProviders>
> > > > > </channel>
> > > > > </channels>
> > > > >
> > > > > Using the soap formater. If I attempt to specify the client
> formatter
> > > and
> > > > > leave the server empty then it works but inspecting the payload
> > reveals
> > > > that
> > > > > it is using SOAP. When I try to force binary it fails with the
> > > following
> > > > > error:
> > > > >
> > > > > Additional information: System.ArgumentNullException: No message
was
> > > > > deserialized prior to calling the DispatchChannelSink.
> > > > >
> > > > > Parameter name: requestMsg
> > > > >
> > > > > at
> > > > >
> > > >
> > >
> >
>
System.Runtime.Remoting.Channels.DispatchChannelSink.ProcessMessage(IServerC
> > > > > hannelSinkStack sinkStack, IMessage requestMsg, ITransportHeaders
> > > > > requestHeaders, Stream requestStream, IMessage& responseMsg,
> > > > > ITransportHeaders& responseHeaders, Stream& responseStream)
> > > > >
> > > > > at
> > > > >
> > > >
> > >
> >
>
System.Runtime.Remoting.Channels.BinaryServerFormatterSink.ProcessMessage(IS
> > > > > erverChannelSinkStack sinkStack, IMessage requestMsg,
> > ITransportHeaders
> > > > > requestHeaders, Stream requestStream, IMessage& responseMsg,
> > > > > ITransportHeaders& responseHeaders, Stream& responseStream)
> > > > >
> > > > > at
> > > > >
> > > >
> > >
> >
>
System.Runtime.Remoting.Channels.Http.HttpHandlerTransportSink.HandleRequest
> > > > > (HttpContext context)
> > > > >
> > > > > at
> > > > >
> > > >
> > >
> >
>
System.Runtime.Remoting.Channels.Http.HttpRemotingHandler.InternalProcessReq
> > > > > uest(HttpContext context)
> > > > >
> > > > >
> > > > >
> > > > > What am I missing here? How do I set this up to work forcing the
> > binary
> > > > > formatter over HTTP (hosted in IIS).
> > > > >
> > > > >
> > > > >
> > > > > Thanks,
> > > > >
> > > > > CMD
> > > > >
> > > > >
> > > >
> > > >
> > >
> > >
> >
> >
>
>


cduden

9/1/2004 4:19:00 PM

0

This will be a long post as I am going to essentially post the entire test
harness where I am observing this odd behaviour and what I am seeing in
TCPTrace (I can't get Ethereal to give me any useful information regarding
local TCP traffic on my machine).

In the Web Project called "BinaryRemotingTest":

Simple class --
using System;
using BinarayRemotingTestShared;

namespace BinaryRemotingTest
{
/// <summary>
/// Summary description for GetRandomNumber.
/// </summary>
public class GetRandomNumber: MarshalByRefObject, IGetRandomNumber
{
public GetRandomNumber()
{
}
public int GetRand()
{
System.Random rnd = new System.Random(System.Environment.TickCount);

return rnd.Next();
}
}
}

web.config:

<system.runtime.remoting>
<application>
<channels>
<channel ref="http" priority="100">
<formatter ref="binary" />
</channel>
</channels>
<service>
<wellknown mode="SingleCall" type="BinaryRemotingTest.GetRandomNumber,
BinaryRemotingTest" objectUri="Rand.rem" />
</service>
</application>
</system.runtime.remoting>

Shared Assembly between web project and windows client called
"BinarayRemotingTestShared" with a single interface

using System;

namespace BinarayRemotingTestShared
{
/// <summary>
/// Summary description for Class1.
/// </summary>
public interface IGetRandomNumber
{
int GetRand();
}
}

Windows Test client --very simple label and button that when clicked :

private void button1_Click(object sender, System.EventArgs e)
{
BinarayRemotingTestShared.IGetRandomNumber IRN =
(IGetRandomNumber)Activator.GetObject(typeof(IGetRandomNumber),@"http://loca
lhost:81/BinaryRemotingTest/Rand.rem");
this.label1.Text = IRN.GetRand().ToString();
}

Windows App Config:

<configuration>
<system.runtime.remoting>
<application>
<channels>
<channel ref="http" port="0">
<clientProviders>
<formatter ref="binary" />
</clientProviders>
</channel>
</channels>
</application>
</system.runtime.remoting>
</configuration>


NOTICE the URL is pointed to port 81. The actaul web project is on port
80 -- this is so I can insert TCPTrace between the client and server. When
I run and click the button this is what I see from TCPTrace:

POST /BinaryRemotingTest/Rand.rem HTTP/1.1
User-Agent: Mozilla/4.0+(compatible; MSIE 6.0; Windows 5.1.2600.0; MS .NET
Remoting; MS .NET CLR 1.1.4322.2032 )
Content-Type: text/xml; charset="utf-8"
SOAPAction:
"http://schemas.microsoft.com/clr/nsassem/BinarayRemotingTestShare...
omNumber/BinarayRemotingTestShared#GetRand"
Content-Length: 586
Expect: 100-continue
Connection: Keep-Alive
Host: localhost:81

<SOAP-ENV:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-inst...
xmlns:xsd="http://www.w3.org/2001/XMLSc...
xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encod...
xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envel...
xmlns:clr="http://schemas.microsoft.com/soap/encoding/clr...
SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encod...>
<SOAP-ENV:Body>
<i2:GetRand id="ref-1"
xmlns:i2="http://schemas.microsoft.com/clr/nsassem/BinarayRemoting...
..IGetRandomNumber/BinarayRemotingTestShared">
</i2:GetRand>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>

AND the response:

HTTP/1.1 100 Continue
Server: Microsoft-IIS/5.1
Date: Wed, 01 Sep 2004 16:11:36 GMT
X-Powered-By: ASP.NET

HTTP/1.1 200 OK
Server: Microsoft-IIS/5.1
Date: Wed, 01 Sep 2004 16:11:37 GMT
X-Powered-By: ASP.NET
X-AspNet-Version: 1.1.4322
Server: MS .NET Remoting, MS .NET CLR 1.1.4322.2032
Cache-Control: private
Content-Type: text/xml; charset="utf-8"
Content-Length: 933

<SOAP-ENV:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-inst...
xmlns:xsd="http://www.w3.org/2001/XMLSc...
xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encod...
xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envel...
xmlns:clr="http://schemas.microsoft.com/soap/encoding/clr...
SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encod...>
<SOAP-ENV:Header>
<h4:__CallContext href="#ref-3"
xmlns:h4="http://schemas.microsoft.com/clr/soap/messageProper...
SOAP-ENC:root="1"/>
<a1:LogicalCallContext id="ref-3"
xmlns:a1="http://schemas.microsoft.com/clr/ns/System.Runtime.Remot...
ing">
</a1:LogicalCallContext>
</SOAP-ENV:Header>
<SOAP-ENV:Body>
<i5:GetRandResponse id="ref-1"
xmlns:i5="http://schemas.microsoft.com/clr/nsassem/BinarayRemoting...
..IGetRandomNumber/BinarayRemotingTestShared">
<return>1683973258</return>
</i5:GetRandResponse>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>


This is not what I would expect to see, when I use TCP Trace to look at a
different service (windows service using tcp\binary) it essentially shows no
content for the request \ response because it was intended for use with text
types not binary, however, it does show the bytes sent and recieved.. I
would have expected to see the same thing with the test harness above,
instead what I am seeing is XML \ SOAP even though both the client and
server are configured for the binary formatter. Interestingly if I change
both the client and server to specificy the soap formatter the request response is identical in all aspects.

Any insight into what is going on would be appreciated.










"Sam Santiago" <ssantiago@n0spam-SoftiTechture.com> wrote in message
news:%238HREf%23jEHA.2812@tk2msftngp13.phx.gbl...
> Not sure, but when you see the packet trace you might see that you are
> getting back some kind of HTTP error response vs. a binary stream
therefore
> causing a bogus error.
>
> Here's another example of using the binary formatter with IIS and HTTP:
>
> Remoting Example: Hosting in Internet Information Services
>
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/cpguide/html/cpconremotingexamplehostin...
>
> With Ethereal, once you see an HTTP packet, right click on it and select
> Follow TCP Stream to view a window that's more readable. Click the Clear
> button if you want to go back to full output list.
>
> Thanks,
>
> Sam
>
> --
> _______________________________
> Sam Santiago
> ssantiago@n0spam-SoftiTechture.com
> http://www.SoftiTe...
> _______________________________
> "cduden" <cduden@netfusionservices.com> wrote in message
> news:%23Yhzd69jEHA.1136@tk2msftngp13.phx.gbl...
> > Ok, Ethereal looks a bit more comprehensive than what I am using,
thanks.
> > Assuming that it is using Binary -- if I use the following:
> >
> > Server:
> >
> > No channels defined, just the services
> >
> > Client:
> > <channels>
> > <channel ref="http" port="0">
> > <clientProviders>
> > <formatter ref="binary" />
> > </clientProviders>
> > </channel>
> > </channels>
> >
> > It works. Question
> >
> > given that the above will function when I add the following to the
server
> > config:
> >
> > <channels>
> > <channel ref="http">
> > <serverProviders>
> > <formatter ref="binary" />
> > </serverProviders>
> > </channel>
> > </channels>
> > It ceases to function. Any insight in to why that is? I get the error
> > listed above.
> >
> >
> > "Sam Santiago" <ssantiago@n0spam-SoftiTechture.com> wrote in message
> > news:OTMq9E8jEHA.3696@TK2MSFTNGP15.phx.gbl...
> > > I see binary for sure. I'm using the ethereal network protocol
> analyzer:
> > > http://www.eth.... The HTTP content type is Content-Type:
> > > application/octet-stream. It's an open source analyzer so try it out.
> > >
> > > Thanks,
> > >
> > > Sam
> > >
> > > --
> > > _______________________________
> > > Sam Santiago
> > > ssantiago@n0spam-SoftiTechture.com
> > > http://www.SoftiTe...
> > > _______________________________
> > > "cduden" <cduden@netfusionservices.com> wrote in message
> > > news:unfrz$7jEHA.2340@TK2MSFTNGP11.phx.gbl...
> > > > I just cut and pasted your config settings into my server web config
> and
> > > > client appconfig. It works great for me too Sam except when I
inspect
> > the
> > > > payload of the traffic between client and server it is a soap
envelope
> > so
> > > I
> > > > don't think that the binary serialization is actually happening.
> > > >
> > > >
> > > > "Sam Santiago" <ssantiago@n0spam-SoftiTechture.com> wrote in message
> > > > news:%23rQMM57jEHA.3944@tk2msftngp13.phx.gbl...
> > > > > This works for me:
> > > > >
> > > > > Server config file hosted in IIS. Nothing special since channel
> must
> > be
> > > > > HTTP and client will control formatting:
> > > > >
> > > > > <system.runtime.remoting>
> > > > > <application>
> > > > > <service>
> > > > > <activated type="My.Class, MyAssembly" />
> > > > > </service>
> > > > > </application>
> > > > > </system.runtime.remoting>
> > > > >
> > > > > Client Config:
> > > > >
> > > > > <system.runtime.remoting>
> > > > > <application name="OrderServicesClient">
> > > > > <client url="http://localhost:8085/">
> > > > > <activated type="My.Class, MyAssembly" />
> > > > > </client>
> > > > > <channels>
> > > > > <channel ref="http" port="0">
> > > > > <clientProviders>
> > > > > <formatter ref="binary" />
> > > > > </clientProviders>
> > > > > </channel>
> > > > > </channels>
> > > > > </application>
> > > > > </system.runtime.remoting>
> > > > >
> > > > > Thanks,
> > > > >
> > > > > Sam
> > > > >
> > > > > --
> > > > > _______________________________
> > > > > Sam Santiago
> > > > > ssantiago@n0spam-SoftiTechture.com
> > > > > http://www.SoftiTe...
> > > > > _______________________________
> > > > > "cduden" <cduden@netfusionservices.com> wrote in message
> > > > > news:u4aQht7jEHA.644@tk2msftngp13.phx.gbl...
> > > > > > I have tried:
> > > > > >
> > > > > > Server Web.config:
> > > > > > <system.runtime.remoting>
> > > > > > <application>
> > > > > > <channels>
> > > > > > <channel ref="http">
> > > > > > <serverProviders>
> > > > > > <formatter ref="binary" typeFilterLevel="Full" />
> > > > > > </serverProviders>
> > > > > > </channel>
> > > > > > </channels>
> > > > > > <service>
> > > > > > <wellknown mode="SingleCall"
> > type="NFC.UserManagement.UserManager,
> > > > > > NFC.UserManagement" objectUri="UserManager.rem" />
> > > > > > </service>
> > > > > >
> > > > > >
> > > > > > </application>
> > > > > > </system.runtime.remoting>
> > > > > >
> > > > > > Windows Client:
> > > > > >
> > > > > > <system.runtime.remoting>
> > > > > > <application>
> > > > > > <channels>
> > > > > > <channel
> > type="System.Runtime.Remoting.Channels.Http.HttpChannel,
> > > > > > System.Runtime.Remoting"/>
> > > > > > <clientProviders>
> > > > > > <formatter
> > > > > >
> > > >
> >
type="System.Runtime.Remoting.Channels.BinaryClientFormatterSinkProvider,
> > > > > > System.Runtime.Remoting" />
> > > > > > </clientProviders>
> > > > > > </channel>
> > > > > > </channels>
> > > > > > </application>
> > > > > > </system.runtime.remoting>
> > > > > >
> > > > > >
> > > > > > AND:
> > > > > >
> > > > > > Server web config:
> > > > > > <channels>
> > > > > > <channel ref="http">
> > > > > > <serverProviders>
> > > > > > <formatter ref="binary" typeFilterLevel="Full" />
> > > > > > </serverProviders>
> > > > > > </channel>
> > > > > > </channels>
> > > > > >
> > > > > >
> > > > > > Client config:
> > > > > > <system.runtime.remoting>
> > > > > > <application>
> > > > > > <channels>
> > > > > > <channel ref="http" port="0">
> > > > > > <clientProviders>
> > > > > > <formatter ref="binary" />
> > > > > > </clientProviders>
> > > > > > </channel>
> > > > > > </channels>
> > > > > > </application>
> > > > > > </system.runtime.remoting>
> > > > > >
> > > > > > AND Countless other permutations. Using TCPTrace I can see what
> is
> > > > being
> > > > > > sent and recieved -- it is either SOAP or it doesn't work.
> > > > Consequently
> > > > > > the same calls work if I use the following:
> > > > > >
> > > > > >
> > > > > > SERVER:
> > > > > > <channels>
> > > > > > <channel ref="http">
> > > > > > <serverProviders>
> > > > > > <provider ref="wsdl" />
> > > > > > <formatter ref="soap" typeFilterLevel="Full" />
> > > > > > </serverProviders>
> > > > > > </channel>
> > > > > > </channels>
> > > > > >
> > > > > > CLIENT:
> > > > > >
> > > > > > <channels>
> > > > > > <channel ref="http" port="0">
> > > > > > <clientProviders>
> > > > > > <formatter ref="soap" />
> > > > > > </clientProviders>
> > > > > > </channel>
> > > > > > </channels>
> > > > > >
> > > > > > Using the soap formater. If I attempt to specify the client
> > formatter
> > > > and
> > > > > > leave the server empty then it works but inspecting the payload
> > > reveals
> > > > > that
> > > > > > it is using SOAP. When I try to force binary it fails with the
> > > > following
> > > > > > error:
> > > > > >
> > > > > > Additional information: System.ArgumentNullException: No message
> was
> > > > > > deserialized prior to calling the DispatchChannelSink.
> > > > > >
> > > > > > Parameter name: requestMsg
> > > > > >
> > > > > > at
> > > > > >
> > > > >
> > > >
> > >
> >
>
System.Runtime.Remoting.Channels.DispatchChannelSink.ProcessMessage(IServerC
> > > > > > hannelSinkStack sinkStack, IMessage requestMsg,
ITransportHeaders
> > > > > > requestHeaders, Stream requestStream, IMessage& responseMsg,
> > > > > > ITransportHeaders& responseHeaders, Stream& responseStream)
> > > > > >
> > > > > > at
> > > > > >
> > > > >
> > > >
> > >
> >
>
System.Runtime.Remoting.Channels.BinaryServerFormatterSink.ProcessMessage(IS
> > > > > > erverChannelSinkStack sinkStack, IMessage requestMsg,
> > > ITransportHeaders
> > > > > > requestHeaders, Stream requestStream, IMessage& responseMsg,
> > > > > > ITransportHeaders& responseHeaders, Stream& responseStream)
> > > > > >
> > > > > > at
> > > > > >
> > > > >
> > > >
> > >
> >
>
System.Runtime.Remoting.Channels.Http.HttpHandlerTransportSink.HandleRequest
> > > > > > (HttpContext context)
> > > > > >
> > > > > > at
> > > > > >
> > > > >
> > > >
> > >
> >
>
System.Runtime.Remoting.Channels.Http.HttpRemotingHandler.InternalProcessReq
> > > > > > uest(HttpContext context)
> > > > > >
> > > > > >
> > > > > >
> > > > > > What am I missing here? How do I set this up to work forcing
the
> > > binary
> > > > > > formatter over HTTP (hosted in IIS).
> > > > > >
> > > > > >
> > > > > >
> > > > > > Thanks,
> > > > > >
> > > > > > CMD
> > > > > >
> > > > > >
> > > > >
> > > > >
> > > >
> > > >
> > >
> > >
> >
> >
>
>


Ken Kolda

9/1/2004 4:39:00 PM

0

The web.config you show in this message is missing the <serverProviders>
tag. I see that you have that in your earlier versions of the fiel (from
prior posts), but wanted to verify it's still there. Also, are you calling
RemotingConfiguration.Configure() on the client before fetching the remoted
object?

Ken


"cduden" <cduden@netfusionservices.com> wrote in message
news:u15e$$DkEHA.3944@tk2msftngp13.phx.gbl...
> This will be a long post as I am going to essentially post the entire test
> harness where I am observing this odd behaviour and what I am seeing in
> TCPTrace (I can't get Ethereal to give me any useful information regarding
> local TCP traffic on my machine).
>
> In the Web Project called "BinaryRemotingTest":
>
> Simple class --
> using System;
> using BinarayRemotingTestShared;
>
> namespace BinaryRemotingTest
> {
> /// <summary>
> /// Summary description for GetRandomNumber.
> /// </summary>
> public class GetRandomNumber: MarshalByRefObject, IGetRandomNumber
> {
> public GetRandomNumber()
> {
> }
> public int GetRand()
> {
> System.Random rnd = new System.Random(System.Environment.TickCount);
>
> return rnd.Next();
> }
> }
> }
>
> web.config:
>
> <system.runtime.remoting>
> <application>
> <channels>
> <channel ref="http" priority="100">
> <formatter ref="binary" />
> </channel>
> </channels>
> <service>
> <wellknown mode="SingleCall" type="BinaryRemotingTest.GetRandomNumber,
> BinaryRemotingTest" objectUri="Rand.rem" />
> </service>
> </application>
> </system.runtime.remoting>
>
> Shared Assembly between web project and windows client called
> "BinarayRemotingTestShared" with a single interface
>
> using System;
>
> namespace BinarayRemotingTestShared
> {
> /// <summary>
> /// Summary description for Class1.
> /// </summary>
> public interface IGetRandomNumber
> {
> int GetRand();
> }
> }
>
> Windows Test client --very simple label and button that when clicked :
>
> private void button1_Click(object sender, System.EventArgs e)
> {
> BinarayRemotingTestShared.IGetRandomNumber IRN =
>
(IGetRandomNumber)Activator.GetObject(typeof(IGetRandomNumber),@"http://loca
> lhost:81/BinaryRemotingTest/Rand.rem");
> this.label1.Text = IRN.GetRand().ToString();
> }
>
> Windows App Config:
>
> <configuration>
> <system.runtime.remoting>
> <application>
> <channels>
> <channel ref="http" port="0">
> <clientProviders>
> <formatter ref="binary" />
> </clientProviders>
> </channel>
> </channels>
> </application>
> </system.runtime.remoting>
> </configuration>
>
>
> NOTICE the URL is pointed to port 81. The actaul web project is on port
> 80 -- this is so I can insert TCPTrace between the client and server.
When
> I run and click the button this is what I see from TCPTrace:
>
> POST /BinaryRemotingTest/Rand.rem HTTP/1.1
> User-Agent: Mozilla/4.0+(compatible; MSIE 6.0; Windows 5.1.2600.0; MS .NET
> Remoting; MS .NET CLR 1.1.4322.2032 )
> Content-Type: text/xml; charset="utf-8"
> SOAPAction:
>
"http://schemas.microsoft.com/clr/nsassem/BinarayRemotingTestShare...
> omNumber/BinarayRemotingTestShared#GetRand"
> Content-Length: 586
> Expect: 100-continue
> Connection: Keep-Alive
> Host: localhost:81
>
> <SOAP-ENV:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-inst...
> xmlns:xsd="http://www.w3.org/2001/XMLSc...
> xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encod...
> xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envel...
> xmlns:clr="http://schemas.microsoft.com/soap/encoding/clr...
> SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encod...>
> <SOAP-ENV:Body>
> <i2:GetRand id="ref-1"
>
xmlns:i2="http://schemas.microsoft.com/clr/nsassem/BinarayRemoting...
> .IGetRandomNumber/BinarayRemotingTestShared">
> </i2:GetRand>
> </SOAP-ENV:Body>
> </SOAP-ENV:Envelope>
>
> AND the response:
>
> HTTP/1.1 100 Continue
> Server: Microsoft-IIS/5.1
> Date: Wed, 01 Sep 2004 16:11:36 GMT
> X-Powered-By: ASP.NET
>
> HTTP/1.1 200 OK
> Server: Microsoft-IIS/5.1
> Date: Wed, 01 Sep 2004 16:11:37 GMT
> X-Powered-By: ASP.NET
> X-AspNet-Version: 1.1.4322
> Server: MS .NET Remoting, MS .NET CLR 1.1.4322.2032
> Cache-Control: private
> Content-Type: text/xml; charset="utf-8"
> Content-Length: 933
>
> <SOAP-ENV:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-inst...
> xmlns:xsd="http://www.w3.org/2001/XMLSc...
> xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encod...
> xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envel...
> xmlns:clr="http://schemas.microsoft.com/soap/encoding/clr...
> SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encod...>
> <SOAP-ENV:Header>
> <h4:__CallContext href="#ref-3"
> xmlns:h4="http://schemas.microsoft.com/clr/soap/messageProper...
> SOAP-ENC:root="1"/>
> <a1:LogicalCallContext id="ref-3"
>
xmlns:a1="http://schemas.microsoft.com/clr/ns/System.Runtime.Remot...
> ing">
> </a1:LogicalCallContext>
> </SOAP-ENV:Header>
> <SOAP-ENV:Body>
> <i5:GetRandResponse id="ref-1"
>
xmlns:i5="http://schemas.microsoft.com/clr/nsassem/BinarayRemoting...
> .IGetRandomNumber/BinarayRemotingTestShared">
> <return>1683973258</return>
> </i5:GetRandResponse>
> </SOAP-ENV:Body>
> </SOAP-ENV:Envelope>
>
>
> This is not what I would expect to see, when I use TCP Trace to look at a
> different service (windows service using tcp\binary) it essentially shows
no
> content for the request \ response because it was intended for use with
text
> types not binary, however, it does show the bytes sent and recieved.. I
> would have expected to see the same thing with the test harness above,
> instead what I am seeing is XML \ SOAP even though both the client and
> server are configured for the binary formatter. Interestingly if I
change
> both the client and server to specificy the soap formatter the request > response is identical in all aspects.
>
> Any insight into what is going on would be appreciated.
>
>
>
>
>
>
>
>
>
>
> "Sam Santiago" <ssantiago@n0spam-SoftiTechture.com> wrote in message
> news:%238HREf%23jEHA.2812@tk2msftngp13.phx.gbl...
> > Not sure, but when you see the packet trace you might see that you are
> > getting back some kind of HTTP error response vs. a binary stream
> therefore
> > causing a bogus error.
> >
> > Here's another example of using the binary formatter with IIS and HTTP:
> >
> > Remoting Example: Hosting in Internet Information Services
> >
>
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/cpguide/html/cpconremotingexamplehostin...
> >
> > With Ethereal, once you see an HTTP packet, right click on it and select
> > Follow TCP Stream to view a window that's more readable. Click the
Clear
> > button if you want to go back to full output list.
> >
> > Thanks,
> >
> > Sam
> >
> > --
> > _______________________________
> > Sam Santiago
> > ssantiago@n0spam-SoftiTechture.com
> > http://www.SoftiTe...
> > _______________________________
> > "cduden" <cduden@netfusionservices.com> wrote in message
> > news:%23Yhzd69jEHA.1136@tk2msftngp13.phx.gbl...
> > > Ok, Ethereal looks a bit more comprehensive than what I am using,
> thanks.
> > > Assuming that it is using Binary -- if I use the following:
> > >
> > > Server:
> > >
> > > No channels defined, just the services
> > >
> > > Client:
> > > <channels>
> > > <channel ref="http" port="0">
> > > <clientProviders>
> > > <formatter ref="binary" />
> > > </clientProviders>
> > > </channel>
> > > </channels>
> > >
> > > It works. Question
> > >
> > > given that the above will function when I add the following to the
> server
> > > config:
> > >
> > > <channels>
> > > <channel ref="http">
> > > <serverProviders>
> > > <formatter ref="binary" />
> > > </serverProviders>
> > > </channel>
> > > </channels>
> > > It ceases to function. Any insight in to why that is? I get the
error
> > > listed above.
> > >
> > >
> > > "Sam Santiago" <ssantiago@n0spam-SoftiTechture.com> wrote in message
> > > news:OTMq9E8jEHA.3696@TK2MSFTNGP15.phx.gbl...
> > > > I see binary for sure. I'm using the ethereal network protocol
> > analyzer:
> > > > http://www.eth.... The HTTP content type is Content-Type:
> > > > application/octet-stream. It's an open source analyzer so try it
out.
> > > >
> > > > Thanks,
> > > >
> > > > Sam
> > > >
> > > > --
> > > > _______________________________
> > > > Sam Santiago
> > > > ssantiago@n0spam-SoftiTechture.com
> > > > http://www.SoftiTe...
> > > > _______________________________
> > > > "cduden" <cduden@netfusionservices.com> wrote in message
> > > > news:unfrz$7jEHA.2340@TK2MSFTNGP11.phx.gbl...
> > > > > I just cut and pasted your config settings into my server web
config
> > and
> > > > > client appconfig. It works great for me too Sam except when I
> inspect
> > > the
> > > > > payload of the traffic between client and server it is a soap
> envelope
> > > so
> > > > I
> > > > > don't think that the binary serialization is actually happening.
> > > > >
> > > > >
> > > > > "Sam Santiago" <ssantiago@n0spam-SoftiTechture.com> wrote in
message
> > > > > news:%23rQMM57jEHA.3944@tk2msftngp13.phx.gbl...
> > > > > > This works for me:
> > > > > >
> > > > > > Server config file hosted in IIS. Nothing special since channel
> > must
> > > be
> > > > > > HTTP and client will control formatting:
> > > > > >
> > > > > > <system.runtime.remoting>
> > > > > > <application>
> > > > > > <service>
> > > > > > <activated type="My.Class, MyAssembly" />
> > > > > > </service>
> > > > > > </application>
> > > > > > </system.runtime.remoting>
> > > > > >
> > > > > > Client Config:
> > > > > >
> > > > > > <system.runtime.remoting>
> > > > > > <application name="OrderServicesClient">
> > > > > > <client url="http://localhost:8085/">
> > > > > > <activated type="My.Class, MyAssembly" />
> > > > > > </client>
> > > > > > <channels>
> > > > > > <channel ref="http" port="0">
> > > > > > <clientProviders>
> > > > > > <formatter ref="binary" />
> > > > > > </clientProviders>
> > > > > > </channel>
> > > > > > </channels>
> > > > > > </application>
> > > > > > </system.runtime.remoting>
> > > > > >
> > > > > > Thanks,
> > > > > >
> > > > > > Sam
> > > > > >
> > > > > > --
> > > > > > _______________________________
> > > > > > Sam Santiago
> > > > > > ssantiago@n0spam-SoftiTechture.com
> > > > > > http://www.SoftiTe...
> > > > > > _______________________________
> > > > > > "cduden" <cduden@netfusionservices.com> wrote in message
> > > > > > news:u4aQht7jEHA.644@tk2msftngp13.phx.gbl...
> > > > > > > I have tried:
> > > > > > >
> > > > > > > Server Web.config:
> > > > > > > <system.runtime.remoting>
> > > > > > > <application>
> > > > > > > <channels>
> > > > > > > <channel ref="http">
> > > > > > > <serverProviders>
> > > > > > > <formatter ref="binary" typeFilterLevel="Full" />
> > > > > > > </serverProviders>
> > > > > > > </channel>
> > > > > > > </channels>
> > > > > > > <service>
> > > > > > > <wellknown mode="SingleCall"
> > > type="NFC.UserManagement.UserManager,
> > > > > > > NFC.UserManagement" objectUri="UserManager.rem" />
> > > > > > > </service>
> > > > > > >
> > > > > > >
> > > > > > > </application>
> > > > > > > </system.runtime.remoting>
> > > > > > >
> > > > > > > Windows Client:
> > > > > > >
> > > > > > > <system.runtime.remoting>
> > > > > > > <application>
> > > > > > > <channels>
> > > > > > > <channel
> > > type="System.Runtime.Remoting.Channels.Http.HttpChannel,
> > > > > > > System.Runtime.Remoting"/>
> > > > > > > <clientProviders>
> > > > > > > <formatter
> > > > > > >
> > > > >
> > >
> type="System.Runtime.Remoting.Channels.BinaryClientFormatterSinkProvider,
> > > > > > > System.Runtime.Remoting" />
> > > > > > > </clientProviders>
> > > > > > > </channel>
> > > > > > > </channels>
> > > > > > > </application>
> > > > > > > </system.runtime.remoting>
> > > > > > >
> > > > > > >
> > > > > > > AND:
> > > > > > >
> > > > > > > Server web config:
> > > > > > > <channels>
> > > > > > > <channel ref="http">
> > > > > > > <serverProviders>
> > > > > > > <formatter ref="binary" typeFilterLevel="Full" />
> > > > > > > </serverProviders>
> > > > > > > </channel>
> > > > > > > </channels>
> > > > > > >
> > > > > > >
> > > > > > > Client config:
> > > > > > > <system.runtime.remoting>
> > > > > > > <application>
> > > > > > > <channels>
> > > > > > > <channel ref="http" port="0">
> > > > > > > <clientProviders>
> > > > > > > <formatter ref="binary" />
> > > > > > > </clientProviders>
> > > > > > > </channel>
> > > > > > > </channels>
> > > > > > > </application>
> > > > > > > </system.runtime.remoting>
> > > > > > >
> > > > > > > AND Countless other permutations. Using TCPTrace I can see
what
> > is
> > > > > being
> > > > > > > sent and recieved -- it is either SOAP or it doesn't work.
> > > > > Consequently
> > > > > > > the same calls work if I use the following:
> > > > > > >
> > > > > > >
> > > > > > > SERVER:
> > > > > > > <channels>
> > > > > > > <channel ref="http">
> > > > > > > <serverProviders>
> > > > > > > <provider ref="wsdl" />
> > > > > > > <formatter ref="soap" typeFilterLevel="Full" />
> > > > > > > </serverProviders>
> > > > > > > </channel>
> > > > > > > </channels>
> > > > > > >
> > > > > > > CLIENT:
> > > > > > >
> > > > > > > <channels>
> > > > > > > <channel ref="http" port="0">
> > > > > > > <clientProviders>
> > > > > > > <formatter ref="soap" />
> > > > > > > </clientProviders>
> > > > > > > </channel>
> > > > > > > </channels>
> > > > > > >
> > > > > > > Using the soap formater. If I attempt to specify the client
> > > formatter
> > > > > and
> > > > > > > leave the server empty then it works but inspecting the
payload
> > > > reveals
> > > > > > that
> > > > > > > it is using SOAP. When I try to force binary it fails with
the
> > > > > following
> > > > > > > error:
> > > > > > >
> > > > > > > Additional information: System.ArgumentNullException: No
message
> > was
> > > > > > > deserialized prior to calling the DispatchChannelSink.
> > > > > > >
> > > > > > > Parameter name: requestMsg
> > > > > > >
> > > > > > > at
> > > > > > >
> > > > > >
> > > > >
> > > >
> > >
> >
>
System.Runtime.Remoting.Channels.DispatchChannelSink.ProcessMessage(IServerC
> > > > > > > hannelSinkStack sinkStack, IMessage requestMsg,
> ITransportHeaders
> > > > > > > requestHeaders, Stream requestStream, IMessage& responseMsg,
> > > > > > > ITransportHeaders& responseHeaders, Stream& responseStream)
> > > > > > >
> > > > > > > at
> > > > > > >
> > > > > >
> > > > >
> > > >
> > >
> >
>
System.Runtime.Remoting.Channels.BinaryServerFormatterSink.ProcessMessage(IS
> > > > > > > erverChannelSinkStack sinkStack, IMessage requestMsg,
> > > > ITransportHeaders
> > > > > > > requestHeaders, Stream requestStream, IMessage& responseMsg,
> > > > > > > ITransportHeaders& responseHeaders, Stream& responseStream)
> > > > > > >
> > > > > > > at
> > > > > > >
> > > > > >
> > > > >
> > > >
> > >
> >
>
System.Runtime.Remoting.Channels.Http.HttpHandlerTransportSink.HandleRequest
> > > > > > > (HttpContext context)
> > > > > > >
> > > > > > > at
> > > > > > >
> > > > > >
> > > > >
> > > >
> > >
> >
>
System.Runtime.Remoting.Channels.Http.HttpRemotingHandler.InternalProcessReq
> > > > > > > uest(HttpContext context)
> > > > > > >
> > > > > > >
> > > > > > >
> > > > > > > What am I missing here? How do I set this up to work forcing
> the
> > > > binary
> > > > > > > formatter over HTTP (hosted in IIS).
> > > > > > >
> > > > > > >
> > > > > > >
> > > > > > > Thanks,
> > > > > > >
> > > > > > > CMD
> > > > > > >
> > > > > > >
> > > > > >
> > > > > >
> > > > >
> > > > >
> > > >
> > > >
> > >
> > >
> >
> >
>
>


cduden

9/1/2004 4:54:00 PM

0

Thank you Ken, I assumed that putting the remote config entries in the
windows client application config file would eliminate the requirement to
call RemotingConfiguration.Config("filename"). As soon as I added that, it
works as I would have expected.


"Ken Kolda" <ken.kolda@elliemae-nospamplease.com> wrote in message
news:uNEXOJEkEHA.2664@TK2MSFTNGP11.phx.gbl...
> The web.config you show in this message is missing the <serverProviders>
> tag. I see that you have that in your earlier versions of the fiel (from
> prior posts), but wanted to verify it's still there. Also, are you calling
> RemotingConfiguration.Configure() on the client before fetching the
remoted
> object?
>
> Ken
>
>
> "cduden" <cduden@netfusionservices.com> wrote in message
> news:u15e$$DkEHA.3944@tk2msftngp13.phx.gbl...
> > This will be a long post as I am going to essentially post the entire
test
> > harness where I am observing this odd behaviour and what I am seeing in
> > TCPTrace (I can't get Ethereal to give me any useful information
regarding
> > local TCP traffic on my machine).
> >
> > In the Web Project called "BinaryRemotingTest":
> >
> > Simple class --
> > using System;
> > using BinarayRemotingTestShared;
> >
> > namespace BinaryRemotingTest
> > {
> > /// <summary>
> > /// Summary description for GetRandomNumber.
> > /// </summary>
> > public class GetRandomNumber: MarshalByRefObject, IGetRandomNumber
> > {
> > public GetRandomNumber()
> > {
> > }
> > public int GetRand()
> > {
> > System.Random rnd = new System.Random(System.Environment.TickCount);
> >
> > return rnd.Next();
> > }
> > }
> > }
> >
> > web.config:
> >
> > <system.runtime.remoting>
> > <application>
> > <channels>
> > <channel ref="http" priority="100">
> > <formatter ref="binary" />
> > </channel>
> > </channels>
> > <service>
> > <wellknown mode="SingleCall"
type="BinaryRemotingTest.GetRandomNumber,
> > BinaryRemotingTest" objectUri="Rand.rem" />
> > </service>
> > </application>
> > </system.runtime.remoting>
> >
> > Shared Assembly between web project and windows client called
> > "BinarayRemotingTestShared" with a single interface
> >
> > using System;
> >
> > namespace BinarayRemotingTestShared
> > {
> > /// <summary>
> > /// Summary description for Class1.
> > /// </summary>
> > public interface IGetRandomNumber
> > {
> > int GetRand();
> > }
> > }
> >
> > Windows Test client --very simple label and button that when clicked :
> >
> > private void button1_Click(object sender, System.EventArgs e)
> > {
> > BinarayRemotingTestShared.IGetRandomNumber IRN =
> >
>
(IGetRandomNumber)Activator.GetObject(typeof(IGetRandomNumber),@"http://loca
> > lhost:81/BinaryRemotingTest/Rand.rem");
> > this.label1.Text = IRN.GetRand().ToString();
> > }
> >
> > Windows App Config:
> >
> > <configuration>
> > <system.runtime.remoting>
> > <application>
> > <channels>
> > <channel ref="http" port="0">
> > <clientProviders>
> > <formatter ref="binary" />
> > </clientProviders>
> > </channel>
> > </channels>
> > </application>
> > </system.runtime.remoting>
> > </configuration>
> >
> >
> > NOTICE the URL is pointed to port 81. The actaul web project is on port
> > 80 -- this is so I can insert TCPTrace between the client and server.
> When
> > I run and click the button this is what I see from TCPTrace:
> >
> > POST /BinaryRemotingTest/Rand.rem HTTP/1.1
> > User-Agent: Mozilla/4.0+(compatible; MSIE 6.0; Windows 5.1.2600.0; MS
..NET
> > Remoting; MS .NET CLR 1.1.4322.2032 )
> > Content-Type: text/xml; charset="utf-8"
> > SOAPAction:
> >
>
"http://schemas.microsoft.com/clr/nsassem/BinarayRemotingTestShare...
> > omNumber/BinarayRemotingTestShared#GetRand"
> > Content-Length: 586
> > Expect: 100-continue
> > Connection: Keep-Alive
> > Host: localhost:81
> >
> > <SOAP-ENV:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-inst...
> > xmlns:xsd="http://www.w3.org/2001/XMLSc...
> > xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encod...
> > xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envel...
> > xmlns:clr="http://schemas.microsoft.com/soap/encoding/clr...
> > SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encod...>
> > <SOAP-ENV:Body>
> > <i2:GetRand id="ref-1"
> >
>
xmlns:i2="http://schemas.microsoft.com/clr/nsassem/BinarayRemoting...
> > .IGetRandomNumber/BinarayRemotingTestShared">
> > </i2:GetRand>
> > </SOAP-ENV:Body>
> > </SOAP-ENV:Envelope>
> >
> > AND the response:
> >
> > HTTP/1.1 100 Continue
> > Server: Microsoft-IIS/5.1
> > Date: Wed, 01 Sep 2004 16:11:36 GMT
> > X-Powered-By: ASP.NET
> >
> > HTTP/1.1 200 OK
> > Server: Microsoft-IIS/5.1
> > Date: Wed, 01 Sep 2004 16:11:37 GMT
> > X-Powered-By: ASP.NET
> > X-AspNet-Version: 1.1.4322
> > Server: MS .NET Remoting, MS .NET CLR 1.1.4322.2032
> > Cache-Control: private
> > Content-Type: text/xml; charset="utf-8"
> > Content-Length: 933
> >
> > <SOAP-ENV:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-inst...
> > xmlns:xsd="http://www.w3.org/2001/XMLSc...
> > xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encod...
> > xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envel...
> > xmlns:clr="http://schemas.microsoft.com/soap/encoding/clr...
> > SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encod...>
> > <SOAP-ENV:Header>
> > <h4:__CallContext href="#ref-3"
> > xmlns:h4="http://schemas.microsoft.com/clr/soap/messageProper...
> > SOAP-ENC:root="1"/>
> > <a1:LogicalCallContext id="ref-3"
> >
>
xmlns:a1="http://schemas.microsoft.com/clr/ns/System.Runtime.Remot...
> > ing">
> > </a1:LogicalCallContext>
> > </SOAP-ENV:Header>
> > <SOAP-ENV:Body>
> > <i5:GetRandResponse id="ref-1"
> >
>
xmlns:i5="http://schemas.microsoft.com/clr/nsassem/BinarayRemoting...
> > .IGetRandomNumber/BinarayRemotingTestShared">
> > <return>1683973258</return>
> > </i5:GetRandResponse>
> > </SOAP-ENV:Body>
> > </SOAP-ENV:Envelope>
> >
> >
> > This is not what I would expect to see, when I use TCP Trace to look at
a
> > different service (windows service using tcp\binary) it essentially
shows
> no
> > content for the request \ response because it was intended for use with
> text
> > types not binary, however, it does show the bytes sent and recieved.. I
> > would have expected to see the same thing with the test harness above,
> > instead what I am seeing is XML \ SOAP even though both the client and
> > server are configured for the binary formatter. Interestingly if I
> change
> > both the client and server to specificy the soap formatter the request > > response is identical in all aspects.
> >
> > Any insight into what is going on would be appreciated.
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >
> > "Sam Santiago" <ssantiago@n0spam-SoftiTechture.com> wrote in message
> > news:%238HREf%23jEHA.2812@tk2msftngp13.phx.gbl...
> > > Not sure, but when you see the packet trace you might see that you are
> > > getting back some kind of HTTP error response vs. a binary stream
> > therefore
> > > causing a bogus error.
> > >
> > > Here's another example of using the binary formatter with IIS and
HTTP:
> > >
> > > Remoting Example: Hosting in Internet Information Services
> > >
> >
>
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/cpguide/html/cpconremotingexamplehostin...
> > >
> > > With Ethereal, once you see an HTTP packet, right click on it and
select
> > > Follow TCP Stream to view a window that's more readable. Click the
> Clear
> > > button if you want to go back to full output list.
> > >
> > > Thanks,
> > >
> > > Sam
> > >
> > > --
> > > _______________________________
> > > Sam Santiago
> > > ssantiago@n0spam-SoftiTechture.com
> > > http://www.SoftiTe...
> > > _______________________________
> > > "cduden" <cduden@netfusionservices.com> wrote in message
> > > news:%23Yhzd69jEHA.1136@tk2msftngp13.phx.gbl...
> > > > Ok, Ethereal looks a bit more comprehensive than what I am using,
> > thanks.
> > > > Assuming that it is using Binary -- if I use the following:
> > > >
> > > > Server:
> > > >
> > > > No channels defined, just the services
> > > >
> > > > Client:
> > > > <channels>
> > > > <channel ref="http" port="0">
> > > > <clientProviders>
> > > > <formatter ref="binary" />
> > > > </clientProviders>
> > > > </channel>
> > > > </channels>
> > > >
> > > > It works. Question
> > > >
> > > > given that the above will function when I add the following to the
> > server
> > > > config:
> > > >
> > > > <channels>
> > > > <channel ref="http">
> > > > <serverProviders>
> > > > <formatter ref="binary" />
> > > > </serverProviders>
> > > > </channel>
> > > > </channels>
> > > > It ceases to function. Any insight in to why that is? I get the
> error
> > > > listed above.
> > > >
> > > >
> > > > "Sam Santiago" <ssantiago@n0spam-SoftiTechture.com> wrote in message
> > > > news:OTMq9E8jEHA.3696@TK2MSFTNGP15.phx.gbl...
> > > > > I see binary for sure. I'm using the ethereal network protocol
> > > analyzer:
> > > > > http://www.eth.... The HTTP content type is Content-Type:
> > > > > application/octet-stream. It's an open source analyzer so try it
> out.
> > > > >
> > > > > Thanks,
> > > > >
> > > > > Sam
> > > > >
> > > > > --
> > > > > _______________________________
> > > > > Sam Santiago
> > > > > ssantiago@n0spam-SoftiTechture.com
> > > > > http://www.SoftiTe...
> > > > > _______________________________
> > > > > "cduden" <cduden@netfusionservices.com> wrote in message
> > > > > news:unfrz$7jEHA.2340@TK2MSFTNGP11.phx.gbl...
> > > > > > I just cut and pasted your config settings into my server web
> config
> > > and
> > > > > > client appconfig. It works great for me too Sam except when I
> > inspect
> > > > the
> > > > > > payload of the traffic between client and server it is a soap
> > envelope
> > > > so
> > > > > I
> > > > > > don't think that the binary serialization is actually happening.
> > > > > >
> > > > > >
> > > > > > "Sam Santiago" <ssantiago@n0spam-SoftiTechture.com> wrote in
> message
> > > > > > news:%23rQMM57jEHA.3944@tk2msftngp13.phx.gbl...
> > > > > > > This works for me:
> > > > > > >
> > > > > > > Server config file hosted in IIS. Nothing special since
channel
> > > must
> > > > be
> > > > > > > HTTP and client will control formatting:
> > > > > > >
> > > > > > > <system.runtime.remoting>
> > > > > > > <application>
> > > > > > > <service>
> > > > > > > <activated type="My.Class, MyAssembly" />
> > > > > > > </service>
> > > > > > > </application>
> > > > > > > </system.runtime.remoting>
> > > > > > >
> > > > > > > Client Config:
> > > > > > >
> > > > > > > <system.runtime.remoting>
> > > > > > > <application name="OrderServicesClient">
> > > > > > > <client url="http://localhost:8085/">
> > > > > > > <activated type="My.Class, MyAssembly" />
> > > > > > > </client>
> > > > > > > <channels>
> > > > > > > <channel ref="http" port="0">
> > > > > > > <clientProviders>
> > > > > > > <formatter ref="binary" />
> > > > > > > </clientProviders>
> > > > > > > </channel>
> > > > > > > </channels>
> > > > > > > </application>
> > > > > > > </system.runtime.remoting>
> > > > > > >
> > > > > > > Thanks,
> > > > > > >
> > > > > > > Sam
> > > > > > >
> > > > > > > --
> > > > > > > _______________________________
> > > > > > > Sam Santiago
> > > > > > > ssantiago@n0spam-SoftiTechture.com
> > > > > > > http://www.SoftiTe...
> > > > > > > _______________________________
> > > > > > > "cduden" <cduden@netfusionservices.com> wrote in message
> > > > > > > news:u4aQht7jEHA.644@tk2msftngp13.phx.gbl...
> > > > > > > > I have tried:
> > > > > > > >
> > > > > > > > Server Web.config:
> > > > > > > > <system.runtime.remoting>
> > > > > > > > <application>
> > > > > > > > <channels>
> > > > > > > > <channel ref="http">
> > > > > > > > <serverProviders>
> > > > > > > > <formatter ref="binary" typeFilterLevel="Full" />
> > > > > > > > </serverProviders>
> > > > > > > > </channel>
> > > > > > > > </channels>
> > > > > > > > <service>
> > > > > > > > <wellknown mode="SingleCall"
> > > > type="NFC.UserManagement.UserManager,
> > > > > > > > NFC.UserManagement" objectUri="UserManager.rem" />
> > > > > > > > </service>
> > > > > > > >
> > > > > > > >
> > > > > > > > </application>
> > > > > > > > </system.runtime.remoting>
> > > > > > > >
> > > > > > > > Windows Client:
> > > > > > > >
> > > > > > > > <system.runtime.remoting>
> > > > > > > > <application>
> > > > > > > > <channels>
> > > > > > > > <channel
> > > > type="System.Runtime.Remoting.Channels.Http.HttpChannel,
> > > > > > > > System.Runtime.Remoting"/>
> > > > > > > > <clientProviders>
> > > > > > > > <formatter
> > > > > > > >
> > > > > >
> > > >
> >
type="System.Runtime.Remoting.Channels.BinaryClientFormatterSinkProvider,
> > > > > > > > System.Runtime.Remoting" />
> > > > > > > > </clientProviders>
> > > > > > > > </channel>
> > > > > > > > </channels>
> > > > > > > > </application>
> > > > > > > > </system.runtime.remoting>
> > > > > > > >
> > > > > > > >
> > > > > > > > AND:
> > > > > > > >
> > > > > > > > Server web config:
> > > > > > > > <channels>
> > > > > > > > <channel ref="http">
> > > > > > > > <serverProviders>
> > > > > > > > <formatter ref="binary" typeFilterLevel="Full" />
> > > > > > > > </serverProviders>
> > > > > > > > </channel>
> > > > > > > > </channels>
> > > > > > > >
> > > > > > > >
> > > > > > > > Client config:
> > > > > > > > <system.runtime.remoting>
> > > > > > > > <application>
> > > > > > > > <channels>
> > > > > > > > <channel ref="http" port="0">
> > > > > > > > <clientProviders>
> > > > > > > > <formatter ref="binary" />
> > > > > > > > </clientProviders>
> > > > > > > > </channel>
> > > > > > > > </channels>
> > > > > > > > </application>
> > > > > > > > </system.runtime.remoting>
> > > > > > > >
> > > > > > > > AND Countless other permutations. Using TCPTrace I can see
> what
> > > is
> > > > > > being
> > > > > > > > sent and recieved -- it is either SOAP or it doesn't work.
> > > > > > Consequently
> > > > > > > > the same calls work if I use the following:
> > > > > > > >
> > > > > > > >
> > > > > > > > SERVER:
> > > > > > > > <channels>
> > > > > > > > <channel ref="http">
> > > > > > > > <serverProviders>
> > > > > > > > <provider ref="wsdl" />
> > > > > > > > <formatter ref="soap" typeFilterLevel="Full" />
> > > > > > > > </serverProviders>
> > > > > > > > </channel>
> > > > > > > > </channels>
> > > > > > > >
> > > > > > > > CLIENT:
> > > > > > > >
> > > > > > > > <channels>
> > > > > > > > <channel ref="http" port="0">
> > > > > > > > <clientProviders>
> > > > > > > > <formatter ref="soap" />
> > > > > > > > </clientProviders>
> > > > > > > > </channel>
> > > > > > > > </channels>
> > > > > > > >
> > > > > > > > Using the soap formater. If I attempt to specify the client
> > > > formatter
> > > > > > and
> > > > > > > > leave the server empty then it works but inspecting the
> payload
> > > > > reveals
> > > > > > > that
> > > > > > > > it is using SOAP. When I try to force binary it fails with
> the
> > > > > > following
> > > > > > > > error:
> > > > > > > >
> > > > > > > > Additional information: System.ArgumentNullException: No
> message
> > > was
> > > > > > > > deserialized prior to calling the DispatchChannelSink.
> > > > > > > >
> > > > > > > > Parameter name: requestMsg
> > > > > > > >
> > > > > > > > at
> > > > > > > >
> > > > > > >
> > > > > >
> > > > >
> > > >
> > >
> >
>
System.Runtime.Remoting.Channels.DispatchChannelSink.ProcessMessage(IServerC
> > > > > > > > hannelSinkStack sinkStack, IMessage requestMsg,
> > ITransportHeaders
> > > > > > > > requestHeaders, Stream requestStream, IMessage& responseMsg,
> > > > > > > > ITransportHeaders& responseHeaders, Stream& responseStream)
> > > > > > > >
> > > > > > > > at
> > > > > > > >
> > > > > > >
> > > > > >
> > > > >
> > > >
> > >
> >
>
System.Runtime.Remoting.Channels.BinaryServerFormatterSink.ProcessMessage(IS
> > > > > > > > erverChannelSinkStack sinkStack, IMessage requestMsg,
> > > > > ITransportHeaders
> > > > > > > > requestHeaders, Stream requestStream, IMessage& responseMsg,
> > > > > > > > ITransportHeaders& responseHeaders, Stream& responseStream)
> > > > > > > >
> > > > > > > > at
> > > > > > > >
> > > > > > >
> > > > > >
> > > > >
> > > >
> > >
> >
>
System.Runtime.Remoting.Channels.Http.HttpHandlerTransportSink.HandleRequest
> > > > > > > > (HttpContext context)
> > > > > > > >
> > > > > > > > at
> > > > > > > >
> > > > > > >
> > > > > >
> > > > >
> > > >
> > >
> >
>
System.Runtime.Remoting.Channels.Http.HttpRemotingHandler.InternalProcessReq
> > > > > > > > uest(HttpContext context)
> > > > > > > >
> > > > > > > >
> > > > > > > >
> > > > > > > > What am I missing here? How do I set this up to work
forcing
> > the
> > > > > binary
> > > > > > > > formatter over HTTP (hosted in IIS).
> > > > > > > >
> > > > > > > >
> > > > > > > >
> > > > > > > > Thanks,
> > > > > > > >
> > > > > > > > CMD
> > > > > > > >
> > > > > > > >
> > > > > > >
> > > > > > >
> > > > > >
> > > > > >
> > > > >
> > > > >
> > > >
> > > >
> > >
> > >
> >
> >
>
>


Sam Santiago

9/1/2004 4:58:00 PM

0

I have not been able to monitor local traffic either. It's worth the effort
using another machine just to see network traffic details.

Thanks,

Sam

--
_______________________________
Sam Santiago
ssantiago@n0spam-SoftiTechture.com
http://www.SoftiTe...
_______________________________
"cduden" <cduden@netfusionservices.com> wrote in message
news:eeh3dW%23jEHA.1356@TK2MSFTNGP09.phx.gbl...
> Sam, I have spent the last hour looking at Ethereal, how do you make it
> analyze traffic on the local machine, I only seem to be able to connect to
> one of my network adapters and it doesn't seem to pick up traffic on the
> local machine (client --> web server)
>
>
> "Sam Santiago" <ssantiago@n0spam-SoftiTechture.com> wrote in message
> news:OTMq9E8jEHA.3696@TK2MSFTNGP15.phx.gbl...
> > I see binary for sure. I'm using the ethereal network protocol
analyzer:
> > http://www.eth.... The HTTP content type is Content-Type:
> > application/octet-stream. It's an open source analyzer so try it out.
> >
> > Thanks,
> >
> > Sam
> >
> > --
> > _______________________________
> > Sam Santiago
> > ssantiago@n0spam-SoftiTechture.com
> > http://www.SoftiTe...
> > _______________________________
> > "cduden" <cduden@netfusionservices.com> wrote in message
> > news:unfrz$7jEHA.2340@TK2MSFTNGP11.phx.gbl...
> > > I just cut and pasted your config settings into my server web config
and
> > > client appconfig. It works great for me too Sam except when I inspect
> the
> > > payload of the traffic between client and server it is a soap envelope
> so
> > I
> > > don't think that the binary serialization is actually happening.
> > >
> > >
> > > "Sam Santiago" <ssantiago@n0spam-SoftiTechture.com> wrote in message
> > > news:%23rQMM57jEHA.3944@tk2msftngp13.phx.gbl...
> > > > This works for me:
> > > >
> > > > Server config file hosted in IIS. Nothing special since channel
must
> be
> > > > HTTP and client will control formatting:
> > > >
> > > > <system.runtime.remoting>
> > > > <application>
> > > > <service>
> > > > <activated type="My.Class, MyAssembly" />
> > > > </service>
> > > > </application>
> > > > </system.runtime.remoting>
> > > >
> > > > Client Config:
> > > >
> > > > <system.runtime.remoting>
> > > > <application name="OrderServicesClient">
> > > > <client url="http://localhost:8085/">
> > > > <activated type="My.Class, MyAssembly" />
> > > > </client>
> > > > <channels>
> > > > <channel ref="http" port="0">
> > > > <clientProviders>
> > > > <formatter ref="binary" />
> > > > </clientProviders>
> > > > </channel>
> > > > </channels>
> > > > </application>
> > > > </system.runtime.remoting>
> > > >
> > > > Thanks,
> > > >
> > > > Sam
> > > >
> > > > --
> > > > _______________________________
> > > > Sam Santiago
> > > > ssantiago@n0spam-SoftiTechture.com
> > > > http://www.SoftiTe...
> > > > _______________________________
> > > > "cduden" <cduden@netfusionservices.com> wrote in message
> > > > news:u4aQht7jEHA.644@tk2msftngp13.phx.gbl...
> > > > > I have tried:
> > > > >
> > > > > Server Web.config:
> > > > > <system.runtime.remoting>
> > > > > <application>
> > > > > <channels>
> > > > > <channel ref="http">
> > > > > <serverProviders>
> > > > > <formatter ref="binary" typeFilterLevel="Full" />
> > > > > </serverProviders>
> > > > > </channel>
> > > > > </channels>
> > > > > <service>
> > > > > <wellknown mode="SingleCall"
> type="NFC.UserManagement.UserManager,
> > > > > NFC.UserManagement" objectUri="UserManager.rem" />
> > > > > </service>
> > > > >
> > > > >
> > > > > </application>
> > > > > </system.runtime.remoting>
> > > > >
> > > > > Windows Client:
> > > > >
> > > > > <system.runtime.remoting>
> > > > > <application>
> > > > > <channels>
> > > > > <channel
> type="System.Runtime.Remoting.Channels.Http.HttpChannel,
> > > > > System.Runtime.Remoting"/>
> > > > > <clientProviders>
> > > > > <formatter
> > > > >
> > >
> type="System.Runtime.Remoting.Channels.BinaryClientFormatterSinkProvider,
> > > > > System.Runtime.Remoting" />
> > > > > </clientProviders>
> > > > > </channel>
> > > > > </channels>
> > > > > </application>
> > > > > </system.runtime.remoting>
> > > > >
> > > > >
> > > > > AND:
> > > > >
> > > > > Server web config:
> > > > > <channels>
> > > > > <channel ref="http">
> > > > > <serverProviders>
> > > > > <formatter ref="binary" typeFilterLevel="Full" />
> > > > > </serverProviders>
> > > > > </channel>
> > > > > </channels>
> > > > >
> > > > >
> > > > > Client config:
> > > > > <system.runtime.remoting>
> > > > > <application>
> > > > > <channels>
> > > > > <channel ref="http" port="0">
> > > > > <clientProviders>
> > > > > <formatter ref="binary" />
> > > > > </clientProviders>
> > > > > </channel>
> > > > > </channels>
> > > > > </application>
> > > > > </system.runtime.remoting>
> > > > >
> > > > > AND Countless other permutations. Using TCPTrace I can see what
is
> > > being
> > > > > sent and recieved -- it is either SOAP or it doesn't work.
> > > Consequently
> > > > > the same calls work if I use the following:
> > > > >
> > > > >
> > > > > SERVER:
> > > > > <channels>
> > > > > <channel ref="http">
> > > > > <serverProviders>
> > > > > <provider ref="wsdl" />
> > > > > <formatter ref="soap" typeFilterLevel="Full" />
> > > > > </serverProviders>
> > > > > </channel>
> > > > > </channels>
> > > > >
> > > > > CLIENT:
> > > > >
> > > > > <channels>
> > > > > <channel ref="http" port="0">
> > > > > <clientProviders>
> > > > > <formatter ref="soap" />
> > > > > </clientProviders>
> > > > > </channel>
> > > > > </channels>
> > > > >
> > > > > Using the soap formater. If I attempt to specify the client
> formatter
> > > and
> > > > > leave the server empty then it works but inspecting the payload
> > reveals
> > > > that
> > > > > it is using SOAP. When I try to force binary it fails with the
> > > following
> > > > > error:
> > > > >
> > > > > Additional information: System.ArgumentNullException: No message
was
> > > > > deserialized prior to calling the DispatchChannelSink.
> > > > >
> > > > > Parameter name: requestMsg
> > > > >
> > > > > at
> > > > >
> > > >
> > >
> >
>
System.Runtime.Remoting.Channels.DispatchChannelSink.ProcessMessage(IServerC
> > > > > hannelSinkStack sinkStack, IMessage requestMsg, ITransportHeaders
> > > > > requestHeaders, Stream requestStream, IMessage& responseMsg,
> > > > > ITransportHeaders& responseHeaders, Stream& responseStream)
> > > > >
> > > > > at
> > > > >
> > > >
> > >
> >
>
System.Runtime.Remoting.Channels.BinaryServerFormatterSink.ProcessMessage(IS
> > > > > erverChannelSinkStack sinkStack, IMessage requestMsg,
> > ITransportHeaders
> > > > > requestHeaders, Stream requestStream, IMessage& responseMsg,
> > > > > ITransportHeaders& responseHeaders, Stream& responseStream)
> > > > >
> > > > > at
> > > > >
> > > >
> > >
> >
>
System.Runtime.Remoting.Channels.Http.HttpHandlerTransportSink.HandleRequest
> > > > > (HttpContext context)
> > > > >
> > > > > at
> > > > >
> > > >
> > >
> >
>
System.Runtime.Remoting.Channels.Http.HttpRemotingHandler.InternalProcessReq
> > > > > uest(HttpContext context)
> > > > >
> > > > >
> > > > >
> > > > > What am I missing here? How do I set this up to work forcing the
> > binary
> > > > > formatter over HTTP (hosted in IIS).
> > > > >
> > > > >
> > > > >
> > > > > Thanks,
> > > > >
> > > > > CMD
> > > > >
> > > > >
> > > >
> > > >
> > >
> > >
> >
> >
>
>