.NET Remoting
From: kmacintyre (kmacintyre_at_discussions.microsoft.com)
Date: 12/22/04
- Previous message: JackD: "RE: Using IIS As an Activation Agent"
- Next in thread: Sam Santiago: "Re: .NET Remoting"
- Reply: Sam Santiago: "Re: .NET Remoting"
- Messages sorted by: [ date ] [ thread ]
Date: Wed, 22 Dec 2004 07:35:10 -0800
I am using .NET Remoting to transfer a file over a network in the form of a
byte array. I am registering the server using:
TcpChannel chan = new TcpChannel(8085);
ChannelServices.RegisterChannel(chan);
RemotingConfiguration.RegisterWellKnownServiceType(typeof(HICONServer),
"C4I.EDMSIM.HICON", WellKnownObjectMode.SingleCall);
and calling the function using:
byte[] buffer = _hiconServer.chooseStation(stationID);
the chooseStation function returns the byte array:
FileStream fs = new FileStream(_dsa.dbName, FileMode.Open);
BinaryReader br = new BinaryReader(fs);
buffer = br.ReadBytes((int)fs.Length);
br.Close();
return buffer;
This works fine when the client and server are both on the same machine, and
this method has worked in another application deployed in a large scale
environment. For some reason, the function never returns. I have added
trace information and the "return buffer" line is getting called, my network
activity jumps and anywhere from 1MB to 4MB gets sent and then nothing
happens.
I have two questions:
1. Should I being doing this another way (splitting up the byte array, and
returning pieces at a time, this probably makes more sense, but I didn't
have problems in the past).
2. Is there some way I can tell if the remoting call has hung up.
- Previous message: JackD: "RE: Using IIS As an Activation Agent"
- Next in thread: Sam Santiago: "Re: .NET Remoting"
- Reply: Sam Santiago: "Re: .NET Remoting"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|