I wouldn't count on there being any automatic file locking with operations 
like cffile.  For our use of cffile, we use it inside named locks that prev
ent multiple simultaneous accesses to error log files we generate.  This ha
s worked well, even with busy error logging with many users ...<sigh>.

So you might be able to get by without an explicit lock, but it's one of th
e first places I'd look if there's problems with cfserver stability.

best,
Chris Norloff

BTW, we learned the hard way that when cffile does an action=append, it a
ctually reads the ENTIRE file into memory, then appends the new info, then 
writes the entire file to the disk.  So watch your file size and your avail
able memory ...


---------- Original Message ----------------------------------
from: Jim McAtee <[EMAIL PROTECTED]>
Reply-To: [EMAIL PROTECTED]
date: Tue, 8 Jan 2002 09:53:12 -0700

>Even if you can't explicitly lock a file during a CFFILE operation... If C
F
>uses system-level function calls to read and write files (that must be why

>it's capable of being locked out of a file when another application has it

>locked), then you would think that during a CF file write operation, the O
S
>must place a lock on the file.  Or no?
>
>The reason I brought up the point in the first place is that I need to rea
d
>and write a large number of small text files that are in use by another,
>very busy service.  I'm hoping that by doing so, I wouldn't be causing
>problems for that application, or for CF itself.
>
>Jim
>
>
>----- Original Message -----
>From: "Jochem van Dieten" <[EMAIL PROTECTED]>
>To: "CF-Talk" <[EMAIL PROTECTED]>
>Sent: Monday, January 07, 2002 5:24 PM
>Subject: Re: CFLOCK on files
>
>
>> Kelly Matthews wrote:
>>
>> > as far as I know it's not something that can be done. CFLOCK is strict
ly
>for
>> > sessions, etc.
>>
>>
>> CFLOCK is for single threading CF. Whatever you do inside that single
>> threaded application is not of CFs concern.
>>
>>
>> > CFFILE doesn't allow you to add a system level lock on a file nor
>release a
>> > lock.
>>
>>
>> Unfortunately not.
>>
>> Jochem
>
______________________________________________________________________
Dedicated Windows 2000 Server
  PIII 800 / 256 MB RAM / 40 GB HD / 20 GB MO/XFER
  Instant Activation · $99/Month · Free Setup
  http://www.pennyhost.com/redirect.cfm?adcode=coldfusiona
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists

Reply via email to