'Kill running Python version of ns-metadata-proxy.
This function will detect if the current metadata proxy process is
running the old Python version and kill it so that the new haproxy
version is spawned instead.'

@staticmethod
def _migrate_python_ns_metadata_proxy_if_needed(pm):

    cmdline = pm.cmdline
    if (cmdline and ('haproxy' not in cmdline)):
        LOG.debug('Migrating    old    instance    of    python    ns-metadata    proxy    to    new    one    based    on    haproxy    (%s)', cmdline)
        pm.disable()
