Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / ASP.NET / Web Services / December 2004

Tip: Looking for answers? Try searching our database.

prevent concurrent access to my web service

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Leo - 07 Dec 2004 11:51 GMT
How do I prevent concurrent access to my web service. How to avoid it.
Signature

Leo

Dan Rogers - 07 Dec 2004 20:16 GMT
Hi Leo,

If you want to have only one caller at a time, you could create a singleton
that keeps track of how many callers are in call, and have any web method
then increment the count (lock here) check that count, and if it is > 1
with the lock still active, decrement, unlock and then throw an exception.

It is most unusual to expose this kind of requirement via web service, at
least this is the first request of this nature I've seen.  The reason is
that if there are multiple callers, there is no way to gate who calls when,
so I'd expect the client satisfaction to be pretty low on this approach.  
Why do you want to impose this kind of limit?

I hope this helps

Dan Rogers
Microsoft Corporation
--------------------
Thread-Topic: prevent concurrent access to my web service
thread-index: AcTcUwc1ODEDrwE8QwK35DLOPgw5gg==
X-WBNR-Posting-Host: 203.197.160.37
From: =?Utf-8?B?TGVv?= <Leo@discussions.microsoft.com>
Subject: prevent concurrent access to my web service
Date: Tue, 7 Dec 2004 03:51:03 -0800
Lines: 3
Message-ID: <EB080F38-1A53-4983-9C2F-198875DDE720@microsoft.com>
MIME-Version: 1.0
Content-Type: text/plain;
    charset="Utf-8"
Content-Transfer-Encoding: 7bit
X-Newsreader: Microsoft CDO for Windows 2000
Content-Class: urn:content-classes:message
Importance: normal
Priority: normal
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.3790.0
Newsgroups: microsoft.public.dotnet.framework.webservices.enhancements
NNTP-Posting-Host: TK2MSFTNGXA03.phx.gbl 10.40.1.29
Path:
cpmsftngxa10.phx.gbl!TK2MSFTFEED02.phx.gbl!TK2MSFTNGXA01.phx.gbl!TK2MSFTNGXA
03.phx.gbl
Xref: cpmsftngxa10.phx.gbl
microsoft.public.dotnet.framework.webservices.enhancements:5063
X-Tomcat-NG: microsoft.public.dotnet.framework.webservices.enhancements

How do I prevent concurrent access to my web service. How to avoid it.
Signature

Leo


Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.