MBS-6644: Add --limit to ProcessReplicationChanges

This flag indicates how many rows ProcessReplicationChanges should
fetch from dbmirror_pendingdata when applying the changes in a transaction.
The limiting is implemented by fetching rows via a cursor, using
the existing query.

The default value is 10000 which causes ProcessReplicationChanges
to use 32MB max. resident memory when applying 90k updates to
area_type (which admittedly is fairly arbitrary tuning, but the
majority of packets do not have transactions anywhere near this size).
MBS-2959: Add a script to fix first_release_date_* columns in release_group_meta

The script fixes the first_release_date_* columns by updating all
release_group_meta rows that have columns that don't match up with
the first release date for all release events on a release.

It does this by finding all release events for all releases, and then
taking the first_value of each date component, with NULLs sorted last,
as the set_release_group_first_release_date function does. This is
joined against release_group_meta rows that have the same release_group
but different values in any of the date components. This set is
limited to 500, so at most 500 release_group_meta rows will be
updated per transaction, to avoid breaking replication for clients.
MBS-6529: Fix display of edit release label edits entered before schema 18

The old edit schema was to have 'release.country' which contained
a string - the name of the country. With schema 18, this property
went away in favour of release.events.country_id. The remapping code
attempted to rewrite 'release.country' to 'release.events.0.country_id' -
but 'release.country' is not an integer so this doesn't make sense.

This commit changes the mapping to instead consult
Area->search_by_names to determine the country_id, and if this
fails it uses the new country_name field (if that is set).
MBS-6558: Encode all Redis keys as UTF-8

The Redis library doesn't deal with encoding keys, so I am encoding all
keys as UTF-8. This allows the 'remember me' functionality to work
with editor names which contain unicode characters (as the username
is used as part of the key).
MBS-6610: Do not show tags, ratings or aliases for linked various artists

The alias-list, rating-list and tag-list elements are not shown for
the "Various Artists" entity unless the client is directly looking up
/ws/2/artist/<various artists mbid>.
MBS-6546: Respond with status 503 if the search server isn't responding

If the search server is unable to delivery the requested page because
it dies for unexpected reasons, then the client should be notified that
it is not their fault the query could not be processed.
MBS-6418: Replace HTML::FormHandler with custom validation for relationship editor

HTML::FormHandler appears to be excessively slow for validating
the relationship editor - taking at least 30 seconds to validate a few
hundred relationships before even getting to the database.

This commit replaces the /relationship-editor validation logic with a
custom validator rather than relying on HTML::FormHandler. To interact
with the rest of the code, the form "looks like" something HTML::FormHandler
would give you back, but has a very limited interface (and equally
limited validation capabilities).

By my rough testing, this allows the relationship editor to create ~700
relationships in 10 seconds.
MBS-6650: Escape example relationships in relationship admin pages

We are splicing in values from Template Toolkit into a <script> block,
so we need to take care to escape them to be valid JavaScript strings.
Remove unused admin/bin scripts
Remove dead code from MB::S::Replication
Merge branch 'mbs-6644' into beta
Merge branch 'mbs-6610' into beta
Merge branch 'mbs-6558' into beta
Merge branch 'mbs-6529' into beta
Merge branch 'mbs-6546' into beta
Merge branch 'mbs-2959' into beta
Merge branch 'mbs-6418' into beta
Merge branch 'mbs-6650' into beta
Merge branch 'unused' into beta
Merge branch 'replication-pm' into beta