You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It is not possible now to declare a method returning Stream, e.g.
public interface IComputingService
{
Stream GetBigFile();
}
In my use case machines need to transmit big index files between each other, and the file size can be up to 4 GB. There is no possibility to create a byte array more than 2GB. Even if it would be possible, it's undesirable to copy the whole file to memory of both sides of a communication channel.
When using WCF, streamed transmission mode can be used to achieve that. Here is an example of NetTcpBinding configuration:
private static Binding GetBinding()
{
var binding = WcfHelper.GetNetTcpBinding();
// Expand properties to allow the transfer of bigger files (> 100MB)
var netTcpBinding = binding as NetTcpBinding;
if (netTcpBinding != null)
{
netTcpBinding.TransferMode = TransferMode.Streamed;
netTcpBinding.MaxReceivedMessageSize = Configuration.Instance.MaxSizeOfIndexFileInBytes;
}
binding.ReceiveTimeout = TimeSpan.FromMinutes(60);
binding.SendTimeout = TimeSpan.FromMinutes(60);
return binding;
}
It would be nice to have the same feature in the IpcServiceFramework.
The text was updated successfully, but these errors were encountered:
It is not possible now to declare a method returning Stream, e.g.
In my use case machines need to transmit big index files between each other, and the file size can be up to 4 GB. There is no possibility to create a byte array more than 2GB. Even if it would be possible, it's undesirable to copy the whole file to memory of both sides of a communication channel.
When using WCF, streamed transmission mode can be used to achieve that. Here is an example of
NetTcpBinding
configuration:It would be nice to have the same feature in the IpcServiceFramework.
The text was updated successfully, but these errors were encountered: