RE: Comet implementation in WCF



Hi Jonny,

As for the WCF Comet service scenario you mentioned, I think what you need
now is some means to check the client connection status when the
server-side finished the method(and ready to return).

So far based on my research, at server-side, WCF method can use
"OperationContext.Current" to inspect some WCF method invocation context
info. And the OperationContext class has a "InstanceContext" property that
can help inspect the current communication object's State:

#OperationContext Class
http://msdn.microsoft.com/en-us/library/system.servicemodel.operationcontext
aspx

For example:

========================
public string GetStringData()
{

OperationContext.Current.InstanceContext.State
}
========================

BTW, since your server-side WCF operation will take long time to process,
have you used async method call pattern at client-side? I think using async
approach will make the client-side UI responding perform better.

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@xxxxxxxxxxxxxx

==================================================
Get notification to my posts through email? Please refer to
http://msdn.microsoft.com/en-us/subscriptions/aa948868.aspx#notifications.

Note: MSDN Managed Newsgroup support offering is for non-urgent issues
where an initial response from the community or a Microsoft Support
Engineer within 2 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. 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/en-us/subscriptions/aa948874.aspx
==================================================
This posting is provided "AS IS" with no warranties, and confers no rights.

--------------------
From: "Jonny Bergdahl" <jonny.bergdahl@xxxxxxxxxxxxxxxx>
Subject: Comet implementation in WCF
Date: Wed, 19 Nov 2008 11:02:52 +0100


I am developing a WCF Comet web service, where client requests gets queued
until a response is available. The connection to the client is thus open a
long time, and in the Comet pattern timeouts is a factor that needs to be
addressed. It can for instance be a proxy server between the client and
server that has a short timeout that disconnects before the server or
client.

Now, the question is how to get a handle to the response so that I can
check
if the client is still connected?

Regards;
/jb



.



Relevant Pages

  • RE: WCF Security Issue
    ... ** Is your WCF service designed to use domain ... both wsHttpbinding and netTcpBinding support message ... Then, for your WCF client, you can use the current logon user's credential ... Microsoft MSDN Online Support Lead ...
    (microsoft.public.dotnet.framework.aspnet.security)
  • Re: System.Configuration does not support config files for libraries.
    ... Seems what you want to do is sharing some custom classes/types between the WCF service and client application. ... For WCF there is type sharing support. ...
    (microsoft.public.dotnet.languages.csharp)
  • Re: Notifying a user on demand
    ... I'm afraid this is quite difficult as the webservice by default is used as ... the client calls the server for information modal. ... portto let the server-side invoke. ... Microsoft MSDN Online Support Lead ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: System.Configuration does not support config files for libraries.
    ... a class library) between the WCF service and client application. ... there is type sharing support. ... Microsoft MSDN Online Support Lead ...
    (microsoft.public.dotnet.languages.csharp)
  • RE: =?Utf-8?Q?RE:_WCF_Service_Library:_=E2=80=9Ccannot?= =?Utf-8?Q?_change_thread_mode_after
    ... object in WCF method? ... Microsoft MSDN Online Support Lead ... where an initial response from the community or a Microsoft Support ... If a client application attempts to access a method that activates the COM ...
    (microsoft.public.dotnet.distributed_apps)

Loading