fam
[Top] [All Lists]

[fam] Using fam correctly

To: fam@xxxxxxxxxxx
Subject: [fam] Using fam correctly
From: "Unité d'Ombre" <chris@xxxxxxxxx>
Date: Thu, 23 May 2002 20:53:34 +0200
Sender: owner-fam@xxxxxxxxxxx
Hello,

I'm on OSX. Someone on the Dawring Project has ported fam (quickly port)
on OSX.
I want to use it for my project but i have some strange behaviors with my test app :

1- Copying the test.c++ code (from the file inside the fam package)
i create a new OS X application. It appears i can't
send more than about 130 (sometimes 129...or 133) requests at once ; my app. suddenly freezes (no crash) and i have no messages from fam (even in debug mode). Each of my requests is for monitoring a directory. I could break this limit of 130
doing this (tr is an array) :

- Collect all directories
- Open fam
- Fill tr (array) with 100 elements
- sendRequest (with tr)
- start the event loop (looking for fam events : changed, created and so on).
->for all my directories :
--> fill tr with other 100 elements
--> sendRequest (the last 100 elements only).

Now i can monitor about 1000 directories (in fact all my files in my home
directories)...but i think it's not a good approach (see (2)). Can you confirm ?

2- When i send all of my directories my event loop received
 changed events for all my files in my home dir. These events
never stop. It's like if all my files were changed continuously.
If i create of delete a file i have the appropriate message.
Is it normal to have all these changed events ?
Is there a way to purge the event queue ?

Thx for your help.
Chris.


--
Source code, list archive, and docs: http://oss.sgi.com/projects/fam/
To unsubscribe: echo unsubscribe fam | mail majordomo@xxxxxxxxxxx

<Prev in Thread] Current Thread [Next in Thread>