Article View: borland.public.cppbuilder.nativeapi
Article #10926Re: Directory Listing in Networks
From: Andrue Cope
Date: Mon, 22 Mar 2004 10:16
Date: Mon, 22 Mar 2004 10:16
54 lines
3611 bytes
3611 bytes
On 19 Mar 2004 17:22:19 -0800, Thomas Steup wrote: > Do FindFirstFile/FindNextFile search over a client-side image of the > directory or is there some kind of remote-call involved which scans the > original file system locally and delivers the result ? The client asks the server and the server performs the search and returns the results. It would be crazy to require the client to read the file system directly as it would have bandwidth and security implications not to mention requiring that the client have a driver for every file system servers use (not all servers are Windows servers so not all servers are running NTFS or FAT file systems). Think of the relationship as being like that between you and a restaurant. You can order what you like but you have little or no control over where the food comes from or how its prepared. It may not even come from the restaurant's kitchen. > If there is any client-side cashing of directory contents, when and how > does synchronisation occur ? It's spelt "caching" - "cashing" is what you do with money :) A directory cache risks getting out of date whenever another machine accesses that directory. The only solution would be to have the server send update messages to every machine and that would be impractical. Generally speaking it's better for servers to be reactive than proactive. Servers and networks have enough problems dealing with specific requests without going looking for trouble :) I wouldn't expect a client to cache directory searches unless they could establish a very close link with the server so as to be notified of updates. Even then I wouldn't expect it to be the default. Applications under Windows can ask to be notified of directory changes so it's possible that this will work for a Windows client connected to a Windows server. > How can i make sure that i find all new files in the remote directory ? Perform another search. As noted above it's possible that Windows servers can notify their clients of changes if asked to do so but non-Windows servers are unlikely to support this feature. Netware certainly doesn't seem to as you need to manually refresh Explorer's folder view. > Are there any differences in what's happening on win98 and win2000 > systems ? Very likely. Win98 is an obsolete operating system. Win2K is a lot more recent. In addition Win98 is a "light weight" operating system build on top a series of bodges and kludges. A lot of features have probably been dropped on the grounds that they were innappropriate or simply too much for Win98 to handle. -- Andrue Cope [Bicester UK]
Technical Details
Message-ID:
<o9i3v4nak0ya.mi5ephy7tfwc$.dlg@40tude.net>Path:
arc1-ca.pugleaf.net!archiver1.google.com!news2.google.com!news.maxwell.syr.edu!border1.nntp.ash.giganews.com!border2.nntp.ash.giganews.com!nntp.giganews.com!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mailReferences:
<405b9ccb@newsgroups.borland.com>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 10cc67,c326c16b6972ebc5 X-Google-Attributes: gid10cc67,public X-Google-ArrivalTime: 2004-03-22 02:39:25 PST From: Andrue Cope <no.spam@spammy.com> Subject: Re: Directory Listing in Networks Newsgroups: borland.public.cppbuilder.nativeapi User-Agent: 40tude_Dialog/2.0.10.1 MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit References: <405b9ccb@newsgroups.borland.com> Date: Mon, 22 Mar 2004 10:16:44 +0000 Message-ID: <o9i3v4nak0ya.mi5ephy7tfwc$.dlg@40tude.net> NNTP-Posting-Host: 217.207.223.34 X-Trace: newsgroups.borland.com 1079950643 217.207.223.34 (22 Mar 2004 02:17:23 -0800) Lines: 54 Path: arc1-ca.pugleaf.net!archiver1.google.com!news2.google.com!news.maxwell.syr.edu!border1.nntp.ash.giganews.com!border2.nntp.ash.giganews.com!nntp.giganews.com!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail