tags:

views:

38

answers:

2

Hi,

I'he got wcf service for wcf straming. I works. But I must integrate it with our webserice.

is there any way, to have webmethod like this:

[webmethod]
public Stream GetStream(string path)
{
  return Iservice.GetStream(path);
}

I service is a class which I copy from WCF service to my asmx.

And is there any way to integrate App.config from wcf with web.config ?

+3  A: 

Sorry, no, ASMX web services don't support streaming.

John Saunders
A: 

What is the bigger picture here, what are you trying to archieve with this stream?

Like John Saunders already said: Webservices dont support it. This is behaviour by design: Data is serialized into a platform/language independent and human readable xml packet, sent and deserialized on the receiver side. Of course you could go and split up your stream into chunks and send it piece for piece. But it wouldnt really make sense to misuse webservices like that, plus you are adding huge overhead in bandwidth and processing time.

Philip Daubmeier
2gb is max size of file.
So why dont you use a plain old binary stream socket to socket? You dont really want to encode >2gb binary data into some string format for putting it into xml and sending it over a web service, do you?
Philip Daubmeier
@Philip: .NET web services most certainly support streaming - just use WCF. It's only the legacy ASMX web services that do not support streaming.
John Saunders