Hi,
I have 2 independent programs on 1 machine that both use the new
synchronization. Each program can have multiple instances which need to be
synchronized with the other copies of itself. In short, a ps output might
read:
dviner 93168 0.0 1.9 10012 9672 ?? Is 7:20PM 0:00.58
/usr/local/bin/perl -w prog1.pl (perl5.6.1)
dviner 93169 0.0 1.9 10012 9672 ?? Is 7:20PM 0:00.58
/usr/local/bin/perl -w prog1.pl (perl5.6.1)
dviner 93170 0.0 1.9 10012 9672 ?? Is 7:20PM 0:00.58
/usr/local/bin/perl -w prog2.pl (perl5.6.1)
dviner 93171 0.0 1.9 10012 9672 ?? Is 7:20PM 0:00.58
/usr/local/bin/perl -w prog2.pl (perl5.6.1)
So, prog1.pl would have its own synchronized log file as would prog2.pl (say
prog1.log and prog2.log respectively).
Now, if I don't provide any 'key' argument in the log configuration file for
either program, all 4 of these processes will use the default "_l4p" as the
semaphore key. I think that this means that all 4 programs will synchronize
their logging, when in fact pid 93168 and 93169 really don't need to sync
with 93170 or 93171. Is that correct?
Is the right approach to use some program specific key for each synchronized
program?
thanks
dave
|