force_flush

def force_flush():
    """force_flush"""
    if SPLUNK_DEBUG:
        print('{} -------------------------------'.format(
            rnow()))
        print('{} splunkpub: force_flush - start'.format(
            rnow()))
    worked = True
    for instance in instances:
        try:
            instance.force_flush()
        except Exception as e:
            worked = False
            if SPLUNK_DEBUG:
                print(
                    '{} - force_flush instance={} '
                    '- hit ex={}'.format(
                        rnow(),
                        instance,
                        e))
        # end of try/ex
    if not worked:
        if SPLUNK_DEBUG:
            print('{} Failed flushing queues'.format(
                rnow()))
    if SPLUNK_DEBUG:
        print('{} splunkpub: force_flush - done'.format(
            rnow()))
        print('{} -------------------------------'.format(
            rnow()))