Unlocks a lock.
    :param lock_manager: the lock manager
    :param configuration: the configuration required to unlock the lock

def _release_lock(lock_manager: ConsulLockManager, configuration: CliUnlockConfiguration):
    """
    Unlocks a lock.
    :param lock_manager: the lock manager
    :param configuration: the configuration required to unlock the lock
    """
    if configuration.regex_key_enabled:
        release_information = sorted(list(lock_manager.release_regex(key_regex=configuration.key)))
    else:
        release_information = lock_manager.release(key=configuration.key)
    print(json.dumps(release_information))

    exit(SUCCESS_EXIT_CODE)