|
|
Home /
Groups /
ColdFusion Talk (CF-Talk)
ColdFusion 8 directory watcher event gateway
hi all.Tony 05/20/08 03:49 P What events are you watching?Andrew Scott 05/20/08 07:57 P exsqueeze me :)Tony 05/20/08 10:01 P Well, thats weird. I am going to assume that there is a timer for theAndrew Scott 05/21/08 12:39 A i dont believe that its a timer.Tony 05/21/08 09:57 A ok, i figured it out :) i think.Tony 05/21/08 10:39 A hi all. i have an event gateway test app using the directory watcher and its working, i have it setup to send me an email everytime a file changes.. problem is, is that im testing with a simple text file, and when i make a change and save the file, i get two emails :( one email for the previous change, and one email for the current change. if i do it again, same thing. one email that matches the previous email, and one new one. ideas? thanks! tony -- 'Never have anything in your life that you can't walk out on in thirty seconds flat, if you spot the heat coming around the corner' robert deniro - heat (1995) What events are you watching? Editing a file, deletes then recreates from memory. So you will get two emails if you are watching both these events. On Wed, May 21, 2008 at 5:48 AM, Tony <tonyweeg@gmail.com> wrote: ----- Excess quoted text cut - see Original Post for more ----- exsqueeze me :) im watching the "onChange" event. and having it send me an email. so, what you are saying is that i need to turn the onDelete event off and that will stop the behaviour i am seeing? because the ACT of editing a file in "system speak" is a deletion then a re-creation from memory? wow, i figured it was something odd like that. and even more odd. if i put more time between the editing of the file, it sometimes WOULDNT do two events, and only would do one event. wonder why? thanks tony On Tue, May 20, 2008 at 7:55 PM, Andrew Scott <andrew.scott@aegeon.com.au> wrote: ----- Excess quoted text cut - see Original Post for more ----- Well, thats weird. I am going to assume that there is a timer for the watching of the directory then, not sure on that. But your problem is a weird one, I suggested the delete event because I got caught in .Net for that once before so was curious if this was the case here. On Wed, May 21, 2008 at 12:00 PM, Tony <tonyweeg@gmail.com> wrote: ----- Excess quoted text cut - see Original Post for more ----- i dont believe that its a timer. that would be weird... here is the 1st email i get... for a file that just changed a few minutes ago... ==================================================== A file has been changed. struct CFCMETHOD onChange CFCPATH S:\reports\version4.0\cfc\root_productionCodeMover.cfc DATA struct FILENAME s:\reports\version4.0\shorty.txt LASTMODIFIED {ts '2008-05-20 15:30:26'} TYPE CHANGE GATEWAYID ProductionCodeMover_root GATEWAYTYPE FileWatcher ORIGINATORID [empty string] ==================================================== and here is the 2nd email that i get... ==================================================== A file has been changed. struct CFCMETHOD onChange CFCPATH S:\reports\version4.0\cfc\root_productionCodeMover.cfc DATA struct FILENAME s:\reports\version4.0\shorty.txt LASTMODIFIED {ts '2008-05-21 09:53:39'} TYPE CHANGE GATEWAYID ProductionCodeMover_root GATEWAYTYPE FileWatcher ORIGINATORID [empty string] ==================================================== what the effffff????/ thanks for any insight! tony On Wed, May 21, 2008 at 12:38 AM, Andrew Scott <andrew.scott@aegeon.com.au> wrote: ----- Excess quoted text cut - see Original Post for more ----- ok, i figured it out :) i think. basically i had the timer set for 10 milliseconds ... way too much and too fast. so, ive set it to 5 seconds and all is working as expected! thanks! tony On Wed, May 21, 2008 at 9:56 AM, Tony <tonyweeg@gmail.com> wrote: ----- Excess quoted text cut - see Original Post for more -----
|
Mailing Lists
|
Latest Fusion Authority Articles
|
||||||