|
|
|
date: Tue, 1 Jul 2008 07:47:00 -0700,
group: microsoft.public.dotnet.framework.aspnet.webservices
back
RE: WCF Service called from 2.0 app and setting maxReceivedMessageSize
Hi Bill,
From your description, you created a WCF service's client proxy via the
.NET 2.0 "Add WebReference" approach, and you're wondering how to configure
the "maxReceivedMessageSize" property for the webservice client proxy
class, correct?
Based on my research, by default the webservice client proxy class only
expose an "Timeout" property which can let you specify the max timeout
period that can let your client proxy waiting for longrun webmethod call.
Also, as for webservice, it normally only care about those http level
settings such as timeout, authentication, proxy or buffer size. And you can
override the following method in webservice proxy class to get the
underlying WebRequest object:
==============
protected override System.Net.WebRequest GetWebRequest(Uri uri) {
WebRequest request = base.GetWebRequest(uri);
HttpWebRequest httpRequest = request as HttpWebRequest;
if (httpRequest != null)
{
httpRequest.ServicePoint.MaxIdleTime = 3000;
httpRequest.KeepAlive = false;
}
return request;
}
=================
All the available network configuration are on the WebRequest object or its
"ServicePoint" property.
here are some other web article which describe this also:
#Connection left open after the web service request
http://vidmar.net/weblog/archive/2005/10/23/2310.aspx
#TCP Connections and Web Service Calls (Reposted from WebServices newsgroup)
http://forums.msdn.microsoft.com/en/netfxnetcom/thread/d093d602-4c6b-4b02-86
03-29c556b98cd1/
Sincerely,
Steven Cheng
Microsoft MSDN Online Support Lead
Delighting our customers is our #1 priority. We welcome your comments and
suggestions about how we can improve the support we provide to you. Please
feel free to let my manager know what you think of the level of service
provided. You can send feedback directly to my manager at:
msdnmg@microsoft.com.
==================================================
Get notification to my posts through email? Please refer to
http://msdn.microsoft.com/subscriptions/managednewsgroups/default.aspx#notif
ications.
Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
where an initial response from the community or a Microsoft Support
Engineer within 1 business day is acceptable. Please note that each follow
up response may take approximately 2 business days as the support
professional working with you may need further investigation to reach the
most efficient resolution. The offering is not appropriate for situations
that require urgent, real-time or phone-based interactions or complex
project analysis and dump analysis issues. Issues of this nature are best
handled working with a dedicated Microsoft Support Engineer by contacting
Microsoft Customer Support Services (CSS) at
http://msdn.microsoft.com/subscriptions/support/default.aspx.
==================================================
This posting is provided "AS IS" with no warranties, and confers no rights.
--------------------
>From: =?Utf-8?B?d2R1ZGVr?= <wdudek@newsgroup.nospam>
>Subject: WCF Service called from 2.0 app and setting maxReceivedMessageSize
>Date: Tue, 1 Jul 2008 07:47:00 -0700
>
>Hi,
>
> I need to up the default maxReceivedMessageSize setting in my clients
>calling a wcf service hosted as a web service. This was easily done in the
>3.5 applications we have using the editor. However I cannot find out where
to
>make the change to the 2.0 apps that are consuming the site as a web
>reference instead of a service reference, can anyone tell me where to
change
>this setting?
>
>Thanks,
>
>Bill
>
date: Wed, 02 Jul 2008 04:18:16 GMT
author: (Steven Cheng [MSFT])
RE: WCF Service called from 2.0 app and setting maxReceivedMessage
Steven,
Thanks for the reply, you are correct in that I used Add Web reference
to generate the proxy from the 2.0 framework application. Since the web
reference does not support the maxReceivedMessage property does this mean
that the problem with some of my messages exceeding the default size for a
service reference will not occur on the 2.0 apps with web references to the
service? In the mean time I will try to test this on our end.
Thanks
Bill
"Steven Cheng [MSFT]" wrote:
> Hi Bill,
>
> From your description, you created a WCF service's client proxy via the
> .NET 2.0 "Add WebReference" approach, and you're wondering how to configure
> the "maxReceivedMessageSize" property for the webservice client proxy
> class, correct?
>
> Based on my research, by default the webservice client proxy class only
> expose an "Timeout" property which can let you specify the max timeout
> period that can let your client proxy waiting for longrun webmethod call.
>
> Also, as for webservice, it normally only care about those http level
> settings such as timeout, authentication, proxy or buffer size. And you can
> override the following method in webservice proxy class to get the
> underlying WebRequest object:
>
> ==============
> protected override System.Net.WebRequest GetWebRequest(Uri uri) {
>
> WebRequest request = base.GetWebRequest(uri);
> HttpWebRequest httpRequest = request as HttpWebRequest;
> if (httpRequest != null)
> {
>
> httpRequest.ServicePoint.MaxIdleTime = 3000;
> httpRequest.KeepAlive = false;
>
> }
>
> return request;
> }
> =================
>
> All the available network configuration are on the WebRequest object or its
> "ServicePoint" property.
>
> here are some other web article which describe this also:
>
> #Connection left open after the web service request
> http://vidmar.net/weblog/archive/2005/10/23/2310.aspx
>
> #TCP Connections and Web Service Calls (Reposted from WebServices newsgroup)
> http://forums.msdn.microsoft.com/en/netfxnetcom/thread/d093d602-4c6b-4b02-86
> 03-29c556b98cd1/
>
> Sincerely,
>
> Steven Cheng
>
> Microsoft MSDN Online Support Lead
>
>
> Delighting our customers is our #1 priority. We welcome your comments and
> suggestions about how we can improve the support we provide to you. Please
> feel free to let my manager know what you think of the level of service
> provided. You can send feedback directly to my manager at:
> msdnmg@microsoft.com.
>
> ==================================================
> Get notification to my posts through email? Please refer to
> http://msdn.microsoft.com/subscriptions/managednewsgroups/default.aspx#notif
> ications.
>
> Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
> where an initial response from the community or a Microsoft Support
> Engineer within 1 business day is acceptable. Please note that each follow
> up response may take approximately 2 business days as the support
> professional working with you may need further investigation to reach the
> most efficient resolution. The offering is not appropriate for situations
> that require urgent, real-time or phone-based interactions or complex
> project analysis and dump analysis issues. Issues of this nature are best
> handled working with a dedicated Microsoft Support Engineer by contacting
> Microsoft Customer Support Services (CSS) at
> http://msdn.microsoft.com/subscriptions/support/default.aspx.
> ==================================================
> This posting is provided "AS IS" with no warranties, and confers no rights.
> --------------------
> >From: =?Utf-8?B?d2R1ZGVr?= <wdudek@newsgroup.nospam>
> >Subject: WCF Service called from 2.0 app and setting maxReceivedMessageSize
> >Date: Tue, 1 Jul 2008 07:47:00 -0700
>
> >
> >Hi,
> >
> > I need to up the default maxReceivedMessageSize setting in my clients
> >calling a wcf service hosted as a web service. This was easily done in the
> >3.5 applications we have using the editor. However I cannot find out where
> to
> >make the change to the 2.0 apps that are consuming the site as a web
> >reference instead of a service reference, can anyone tell me where to
> change
> >this setting?
> >
> >Thanks,
> >
> >Bill
> >
>
>
date: Wed, 2 Jul 2008 06:44:00 -0700
author: wdudek am
RE: WCF Service called from 2.0 app and setting maxReceivedMessage
Thanks for your reply Bill,
Yes, for webservice client proxy, it is just a normal http client
component. Generally there is not particular limitation/configuration on
the receive size. but the timeout setting may affect since for large
message it may take long time to return. I suggest you first time it by
setting timeout value to some large value to see whether it works well
witht large response message/data size.
Please feel free to let me know if you have got any new results.
Sincerely,
Steven Cheng
Microsoft MSDN Online Support Lead
Delighting our customers is our #1 priority. We welcome your comments and
suggestions about how we can improve the support we provide to you. Please
feel free to let my manager know what you think of the level of service
provided. You can send feedback directly to my manager at:
msdnmg@microsoft.com.
==================================================
Get notification to my posts through email? Please refer to
http://msdn.microsoft.com/subscriptions/managednewsgroups/default.aspx#notif
ications.
==================================================
This posting is provided "AS IS" with no warranties, and confers no rights.
--------------------
>From: =?Utf-8?B?d2R1ZGVr?= <wdudek@newsgroup.nospam>
>References:
<H968tq$2IHA.1620@TK2MSFTNGHUB02.phx.gbl>
>Subject: RE: WCF Service called from 2.0 app and setting maxReceivedMessage
>Date: Wed, 2 Jul 2008 06:44:00 -0700
ces
>
>Steven,
>
> Thanks for the reply, you are correct in that I used Add Web reference
>to generate the proxy from the 2.0 framework application. Since the web
>reference does not support the maxReceivedMessage property does this mean
>that the problem with some of my messages exceeding the default size for a
>service reference will not occur on the 2.0 apps with web references to
the
>service? In the mean time I will try to test this on our end.
>
>Thanks
>
>Bill
>
>"Steven Cheng [MSFT]" wrote:
>
>> Hi Bill,
>>
>> From your description, you created a WCF service's client proxy via the
>> .NET 2.0 "Add WebReference" approach, and you're wondering how to
configure
>> the "maxReceivedMessageSize" property for the webservice client proxy
>> class, correct?
>>
>> Based on my research, by default the webservice client proxy class only
>> expose an "Timeout" property which can let you specify the max timeout
>> period that can let your client proxy waiting for longrun webmethod call.
>>
>> Also, as for webservice, it normally only care about those http level
>> settings such as timeout, authentication, proxy or buffer size. And you
can
>> override the following method in webservice proxy class to get the
>> underlying WebRequest object:
>>
>> ==============
>> protected override System.Net.WebRequest GetWebRequest(Uri uri) {
>>
>> WebRequest request = base.GetWebRequest(uri);
>> HttpWebRequest httpRequest = request as HttpWebRequest;
>> if (httpRequest != null)
>> {
>>
>> httpRequest.ServicePoint.MaxIdleTime = 3000;
>> httpRequest.KeepAlive = false;
>>
>> }
>>
>> return request;
>> }
>> =================
>>
>> All the available network configuration are on the WebRequest object or
its
>> "ServicePoint" property.
>>
>> here are some other web article which describe this also:
>>
>> #Connection left open after the web service request
>> http://vidmar.net/weblog/archive/2005/10/23/2310.aspx
>>
>> #TCP Connections and Web Service Calls (Reposted from WebServices
newsgroup)
>>
http://forums.msdn.microsoft.com/en/netfxnetcom/thread/d093d602-4c6b-4b02-86
>> 03-29c556b98cd1/
>>
>> Sincerely,
>>
>> Steven Cheng
>>
>> Microsoft MSDN Online Support Lead
>>
date: Thu, 03 Jul 2008 04:57:42 GMT
author: (Steven Cheng [MSFT])
RE: WCF Service called from 2.0 app and setting maxReceivedMessage
Thanks for your followup.
I'm glad that everything is going on well.
Sincerely,
Steven Cheng
Microsoft MSDN Online Support Lead
Delighting our customers is our #1 priority. We welcome your comments and
suggestions about how we can improve the support we provide to you. Please
feel free to let my manager know what you think of the level of service
provided. You can send feedback directly to my manager at:
msdnmg@microsoft.com.
==================================================
Get notification to my posts through email? Please refer to
http://msdn.microsoft.com/subscriptions/managednewsgroups/default.aspx#notif
ications.
==================================================
This posting is provided "AS IS" with no warranties, and confers no rights.
--------------------
>Subject: RE: WCF Service called from 2.0 app and setting maxReceivedMessage
>Date: Sun, 13 Jul 2008 13:59:43 -0700
>Steven,
>
> Thanks that answered my question. I apologize for the delay getting
abck
>to you, I've been living in the SQL Server forumns and on the phone with
>support for the last week due to some database problems we have been
>experiencing.
>
>Thanks,
>Bill
>
>"Steven Cheng [MSFT]" wrote:
>
>> Hi Bill,
>>
>> Have you got any further ideas on this?
>>
>> I've also discussed with some other webservice engineer and they also
said
>> that for .net webservice proxy(the webRequest component), it doesn't
have a
>> receive message size limit like the WCF client.
>>
>> Sincerely,
>>
>> Steven Cheng
>>
>> Microsoft MSDN Online Support Lead
>>
>>
>> Delighting our customers is our #1 priority. We welcome your comments
and
>> suggestions about how we can improve the support we provide to you.
Please
>> feel free to let my manager know what you think of the level of service
>> provided. You can send feedback directly to my manager at:
>> msdnmg@microsoft.com.
>>
>
date: Mon, 14 Jul 2008 01:56:53 GMT
author: (Steven Cheng [MSFT])
|
|