What does priority mean in `update-alternatives`?

Solution 1:

From man update-alternatives:

Each alternative has a priority associated with it.  When a link  group  is  in  automatic
mode,  the  alternatives  pointed  to by members of the group will be those which have the
highest priority.

It can be any integer, even negative (see example in manpage).

If the alternative is set manually, priority has no relation to the default.