def _send_command(cmd,
                  worker,
                  lbn,
                  target,
                  profile='default',
                  tgt_type='glob'):
    '''
    Send a command to the modjk loadbalancer
    The minion need to be able to publish the commands to the load balancer

    cmd:
        worker_stop - won't get any traffic from the lbn
        worker_activate - activate the worker
        worker_disable - will get traffic only for current sessions
    '''

    ret = {
        'code': False,
        'msg': 'OK',
        'minions': [],
    }

    # Send the command to target
    func = 'modjk.{0}'.format(cmd)
    args = [worker, lbn, profile]
    response = __salt__['publish.publish'](target, func, args, tgt_type)

    # Get errors and list of affeced minions
    errors = []
    minions = []
    for minion in response:
        minions.append(minion)
        if not response[minion]:
            errors.append(minion)

    # parse response
    if not response:
        ret['msg'] = 'no servers answered the published command {0}'.format(
            cmd
        )
        return ret
    elif errors:
        ret['msg'] = 'the following minions return False'
        ret['minions'] = errors
        return ret
    else:
        ret['code'] = True
        ret['msg'] = 'the commad was published successfully'
        ret['minions'] = minions
        return ret
Send a command to the modjk loadbalancer
    The minion need to be able to publish the commands to the load balancer

    cmd:
        worker_stop - won't get any traffic from the lbn
        worker_activate - activate the worker
        worker_disable - will get traffic only for current sessions