File Change Detection - poll interval

General and specific configuration/INI settings

File Change Detection - poll interval

Postby Kashim » Mon Apr 02, 2007 2:42 am

Hi, I have a question about UltraEdit's forced interval file change detection. I have a local file which is modified frequently by several remote computers. Under the File Change Detection heading in the configuration menu, I have set automatic updating of changed files and a forced poll interval of one second. Then I turned on File Change Polling for the file in question. It works well, but my question is whether the one second interval is too low. I know the file is only reloaded in the editor if a change is detected, but how is that detection done? I'm assuming it is left up to the operating/file system to mark the file as changed, rather than UltraEdit constantly reloading the file to check. Does anyone know if the file is only read from disk if there was a change detected? I just want to make sure the file isn't read from disk over and over again every second.

Thanks in advance.
User avatar
Kashim
Newbie
 
Posts: 2
Joined: Sat Mar 31, 2007 11:00 pm

Re: File Change Detection - poll interval

Postby Mofi » Mon Apr 02, 2007 6:45 am

UE loads the file only when it is changed. The poll interval determines how often UE queries all the file informations (file name, file attributes, file size, file dates/times). Only when one bit in this information changes (normally the last modification date/time), the file is reloaded.
User avatar
Mofi
Grand Master
Grand Master
 
Posts: 4055
Joined: Thu Jul 29, 2004 11:00 pm
Location: Vienna

Re: File Change Detection

Postby danne » Mon Apr 02, 2007 6:50 am

I'd say you'd have to mail IDM and ask, because only they know how they've implemented that.

I guess you could check the access time on the file and compare it to modify time ie. something like this:

Code: Select all
$ stat scrolltext.txt
  File: `scrolltext.txt'
  Size: 123             Blocks: 8          IO Block: 4096   regular file
Access: 2007-03-19 17:08:54.000000000 +0100
Modify: 2006-04-17 21:44:14.000000000 +0200
Change: 2007-03-19 17:08:55.000000000 +0100
$ cat scrolltext.txt
$ stat scrolltext.txt
  File: `scrolltext.txt'
  Size: 123             Blocks: 8          IO Block: 4096   regular file
Access: 2007-04-02 10:42:53.000000000 +0200
Modify: 2006-04-17 21:44:14.000000000 +0200
Change: 2007-03-19 17:08:55.000000000 +0100


Notice the "Access:" info in both cases.

That of course requires you to have something to check that with, dunno what's available under windoze except for properties which probably is too slow to play around with for your test. I'm sure there's some program to try with tho^^
User avatar
danne
Basic User
Basic User
 
Posts: 36
Joined: Mon Feb 07, 2005 12:00 am

Re: File Change Detection - poll interval

Postby Kashim » Mon Apr 02, 2007 7:21 pm

All I wanted to know was whether it's safe to leave the poll interval at such a low value. Just wanted to make sure my hard disk isn't accessed thousands of times unnecessarily each day. Thanks for your replies, much appreciated. :D
User avatar
Kashim
Newbie
 
Posts: 2
Joined: Sat Mar 31, 2007 11:00 pm


Return to Configuration/INI Settings