Comment 20 for bug 366780

Revision history for this message
mvdkwast (mvdkwast) wrote :

> There won't ever be user-defined priorities in NM.

Old comment, no rationale. Time for a change ?

Instead of full-blown network prioritization which would involve a gui to sort connections and careful thinking to ensure that the connection selection stays predictable, would it be enough to add a boolean "preferred" field ?

In the original example, "home" and "work" would be marked as preferred, while "beeline-wifi-free" would not.

A quick glance at the NetworkManager source code makes me think that it shouldn't be too hard to add a "preferred" attribute to network connections, and to use it in the connection_sort function (nm-settings.c). It would be shown as a checkbox in nm-applet.

If more granularity is required, a numeric "priority" attribute could be used instead. If it seems to confusing to expose a numeric connection priority value to the users, it could still be shown as a "preferred" checkbox in nm-applet, leaving it to power users to edit the numeric value manually in the configuration file if required.