Discussion about Cancel-Lock support

Julien ÉLIE julien at trigofacile.com
Thu Oct 21 20:21:55 UTC 2021


Hi Russ,

> Personally, I'd be happy to never have to write cryptic configuration lke:
> 
> news.uu.net/uunet\
>         :*,!junk,!control,!control.*/!foo\
>         :Tm:innfeed!

I bet you also love the syntax of innwatch.ctl :-)

!load!+! uptime | tr -d ,. | awk '{ print $(NF - 2) }' ! gt ! 
${INNWATCHPAUSELOAD} ! pause ! loadav


> I think the question is whether having a
> cleaner config syntax with more human-readable options and schema checking
> is enough of an advantage over, say, the current cryptic newsfeeds syntax
> to be worth introducing a whole new config syntax after all this time.

That's a good question.
We have lots of examples in the newsfeeds sample file, so normally it is 
not too difficult to find out the right syntax for a basic feed.

Most of the questions come from readers.conf... which has a cleaner syntax!


> If we did something like this, it also opens the interesting possibility
> of rethinking how configuration is broken up between files.  It's pretty
> irritating right now to have to modify three different files with entirely
> different syntax to add a new peer, and we could fix that.

It is true that having only one file to set up a peer would be good, 
mixing newsfeeds/incoming.conf/innfeed.conf configuration for the peer.


>> The drawbacks I would see for YAML is that we add a library dependency to
>> libyaml, hoping it is available in all the platforms we support (libyaml
>> seems more wide-spread than libfyaml).
> 
> Yes, this is a potentially serious drawback for folks who are building INN
> themselves on platforms other than Linux.

Seems like the only real argument for not using YAML.
If we speak of the syntax, what you implemented in the "new" parser is 
pretty good, YAML-like, and perfectly fits the needs of INN.

So maybe we should just keep this parser and go ahead with it?
Does anyone here have another opinion?


>> And personally I like its way to write lists ([a b c]) more than YAML
>> does (multi-lines).
> 
> Little known fact: [a, b, c] is also valid YAML!

Oh, I did not know.  The summaries I read about YAML did not show that 
syntax.

-- 
Julien ÉLIE

« Attention aux bugs dans le code ci-dessus. Je ne l'ai pas testé, j'ai
   seulement prouvé qu'il était correct. » (Donald Knuth)


More information about the inn-workers mailing list