[exim-dev] [Bug 3083] Allow multiple uses of options definin…

Startseite
Nachricht löschen
Nachricht beantworten
Autor: Exim Bugzilla
Datum:  
To: exim-dev
Betreff: [exim-dev] [Bug 3083] Allow multiple uses of options defining servers for database lookups
https://bugs.exim.org/show_bug.cgi?id=3083

--- Comment #4 from Marten Lehmann <lehmann@???> ---
You already gave good examples by yourself :)

This line in your example defines the first datasource:

mysql_servers = localhost::PORT_N/test/root/ : \

It ends with a colon (indicating there will be more sources following) and a
backslash (indicating further details will follow on a new line). An agnostic
configuration block for a single feature doesn't know though, whether there
will be more datasources in general, more datasources of the same type and
whether they will follow immediately on the next line or in a later segment of
the configuration file.

This block in your example adds an additional datasource:

.ifdef FUBAR
    localhost::PORT_D/test/fred/ : \
.endif


It doesn't define a type of datasource though, so it requires a prepending
block of the same type. That way it's not an independent block any longer.
Also, the line is ending with ": \", expecting another datasource the follow.
An agnostic configuration for a single feature is not aware of it's position in
the list of datasources nor does it know whether more datasources will follow.

Using your suggested += syntax, the same example would look like this:

mysql_servers += localhost::PORT_N/test/root/
.ifdef FUBAR
mysql_servers += localhost::PORT_D/test/fred/
.endif
mysql_servers += HOSTIPV4::PORT_D2/test/bill/

It looks way more nice and clean to me. It would blend in perfectly without
breaking existing configurations.

--
You are receiving this mail because:
You are on the CC list for the bug.

--
## subscription configuration (requires account):
## https://lists.exim.org/mailman3/postorius/lists/exim-dev.lists.exim.org/
## unsubscribe (doesn't require an account):
## exim-dev-unsubscribe@???
## Exim details at http://www.exim.org/
## Please use the Wiki with this list - http://wiki.exim.org/