New profiles spec
Rui Lopes
rgl at ruilopes.com
Sun Jun 3 12:09:58 BST 2007
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
I'm just a newbie user of upstart, though, I'll try to give my opinion
anyways ;-)
Alex Smith wrote:
> Hmm, I thought of a few things in terms of the behaviour when parsing
> the profile:
>
> * What should the parser do if it encounters an enable/disable stanza
> for a job that's already been specifically mentioned? Should it override
> the previous definition for that job, or should it simply ignore the
> second value and dump a warning to syslog?
It should override (no warning; last stanza wins); assuming this is a
valid profile:
enable *
disable php-fcgi*
where I enabled all jobs (which includes php-fcgi, php-fcgi-1,
phpfcgi-2) and later I've disable all php-fcgi jobs. Without
overriding, this profile specification could not honored and it should
refuse to load the profile.
> * Would it be better to store the values in an NihHash or an NihList?
> Currently my implementation uses NihList, but I discovered NihHash when
> poking around job.c. I don't really see any reason to change apart from
> being able to look up profile entries by job name, and that can be done
> with an NIH_LIST_FOREACH.
Depends if you need to do a lot of profile lookups by name or not (and
if there are many profiles). Which I really don't known.
Bests regards,
Rui Lopes
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.7 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
iD8DBQFGYqGGg6ss8INEYd4RAodjAKCArbM2ZmkesbGufVlAmmpiQyy+0gCglyph
272fWN2AYZSANJkssPz9jY8=
=1rsg
-----END PGP SIGNATURE-----
More information about the upstart-devel
mailing list