Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Critical Section in VFP
Message
 
To
06/07/2000 12:14:51
General information
Forum:
Visual FoxPro
Category:
Windows API functions
Miscellaneous
Thread ID:
00387913
Message ID:
00389336
Views:
15
>>That won't solve that problem. This is not a concurrency issue that a block can help. The issue is with VFP's data caching and using a CS won't solve that problem. Basically, you either have to close and re-open that table to refresh those buffers immediately or wait long enough to guarantee the buffers get refreshed by VFP.
>
>Why would you have concurrency issue if you have only one DataSessionServer that is multi-use? We still have multiple single-use WC servers, but they get their session data from the DataSessionServer.

I didn't read the whole thread. But basically, if you're using a multi-use server you also don't need CS because those by their very nature are queued. You can't make simultaneous calls into a multi-use EXE server.

If you're using multiple WWWC instances and they're all creating DLL multi-use server instances then a CS won't help either because it's cross process and a CS only works interprocess. If this is your game then you need to use mutexes, but again this is all overkill. In the time it takes to make the COM calls and handle the Csections/mutex or whatever you could have closed and re-opened that table.

Basically, a CS is not the right way to handle this any way you look at it.

If you really have this issue at a critical piece in your code consider sticking that piece of data into a SQL server of some sort - concurrency issues can easily be handled properly there.

+++ Rick ---
+++ Rick ---

West Wind Technologies
Maui, Hawaii

west-wind.com/
West Wind Message Board
Rick's Web Log
Markdown Monster
---
Making waves on the Web

Where do you want to surf today?
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform