Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
How to USE a DBF in ISAPI VFP MTDLL ?
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Applications Internet
Divers
Thread ID:
00989817
Message ID:
00990938
Vues:
21
You probably DO want to use the session class. If I were you I'd take a look at ActiveVFP and see the way it's set up there. it's really the same thing you're doing on the server side. Foxisapi.dll is in the same role as the ASP isapi but the server side stuff will be the same for mtdlls. I always use the session class but you might not notice it since the Session class is the very lowest(or highest?) subclass because of the way I implemented debugging. Also, I would always use COMRETURNERROR.

Thanks Claude

I read that using a "private" session would eliminate the requirement for a sys(2336) to manage pooling. A "USE" opens the file as shared. When the "thread" finishes, sys(2336,2) would release the thread, but leave the dbf open.

I envision (g) the pooled "requests", waiting to enter a critical section, at the ready and connected to the "shared" dbfs. Once a thread becomes available, they enter the critical section (with the open dbfs), do their business, punch out [sys(2336,2)], and take their data back to the browser. And the next guy jumps in!

I am looking for clock. How would you compare the performance of a private data session [no sys(2336)], to a shared datasession [requires sys(2336)], to "USE" (each client request would use (shared) all DBFs) [requires sys(2336)].

I mean, would a private session relase to the next thread more quickly that sys(2336)?


ON COMRETURN ERROR
I am having some difficulty understanding how COMRETURNERROR (CRE) would function in a browser and javascript (only no A/JSP's). It seems that CRE is designed to bind with a VFP ONERROR method. The only VFP in this configuration is the COM (foxISAPI server).

foxISAPI is a client of the VFP MTDLL. Is there an ON ERROR method in foxISAPI that CRE could bind with?

I suppose an 'ON ERROR' procedure, outside the class, but in the same PRG, could be called by CRE. Could a page be returned to the browser that experienced the exception?

Or -

If it is not possible to inform the browser that raised the exception, then it could be logged [perhaps], and at least reset. Would CRE be required for a reset?

Would a ON ERROR (reset) in the COM's error method be enough to reset.

>ActiveVFP is a collection of best practices learned over several years so there really is a wealth of good information in there for vfp mtdll usage. The result is stability, ease of use, and very fast processing!
>>If you derive from Session anything you do in the class will be isolated to that class because it is - surprise - a Session object. If you use Custom you shouldn't have this problem (although you have to do more setup potentially). Note also that you see open tables only through the same object. Another object may (or may not) be loaded on another thread.
>>>
>>>+++ Rick ---
Imagination is more important than knowledge
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform