[BlueOnyx:22273] Re: additional MX options

Michael Stauber mstauber at blueonyx.it
Fri Jul 20 23:27:53 -05 2018


Hi Michael,

> I am sure you are busy but if you get a chance it would be
> great if you could add more options for MX priorities.
> 
> Right now there is only 5. 0,20,30,40,50
>
> I am not sure why 10 was not added in the first place 

Yeah, it hasn never been added, because it was that way all the way back
to the RaQ550:

$mx_priority_select = $factory->getMultiChoice("mail_server_priority",
array_values(array("extremely_high", "very_high", "high", "low",
"very_low")));

It then pulls the actual priority from the locale files:

#-----------------

msgid "extremely_high"
msgstr "Extremely High (0)"

msgid "very_high"
msgstr "Very High (20)"

msgid "high"	
msgstr "High (30)"

msgid "low"	
msgstr "Low (40)"

msgid "very_low"
msgstr "Very Low (50)"

#-----------------

And eventually a Handler writes it off to the zone file based on the
locale ID:

if ($obj->{mail_server_priority} =~ m/^\s*(\d+)/) { $value = $1; }
if ($obj->{mail_server_priority} =~ m/^\s*Very_Low/i) { $value = 50; }
if ($obj->{mail_server_priority} =~ m/^\s*Low/i) { $value = 40; }
if ($obj->{mail_server_priority} =~ m/^\s*High/i) { $value = 30; }
if ($obj->{mail_server_priority} =~ m/^\s*Very_High/i) { $value = 20; }
if ($obj->{mail_server_priority} =~ m/^\s*Extremely_High/i) { $value = 0; }

So the "10" simply isn't there. This also makes it really shitty to fix,
because optically the "10" has to sit between "Extremely High (0)" and
"Very High (20)".

How do we name that? "Very, very High (10)" or "Very damn High (10)"?

;-)

-- 
With best regards

Michael Stauber



More information about the Blueonyx mailing list