Versions Compared

    Key

    • This line was added.
    • This line was removed.
    • Formatting was changed.
    Comment: Published by Scroll Versions from this space and version 6.6-3

    ...

    Code Block
    #
    # callbacks.conf
    #
    # syntax of this file is :
    # filename = triggers
    #
    logFailuresToDB.py = failed-job-self-*
    mail-status.qcb = done-job-self
    checkWork.pl = done-work-self-*
    submitted.py = submit-job-self

    In this example, there are presumably 3 4 implementation files in the callback directory, logFailuresToDB.py, mail-status.qcb, submitted.py, and checkWork.pl, that have the implementation code in them.

    Code Block
    titlesubmitted.py
    languagepy
    #!/usr/bin/env python
    
    import sys
    import qb
    import traceback
    
    fh = open('/tmp/univeral_callback_test', 'a')
    try:
        # ==================================================
        #  === NOTE: ===
        #  the qb.jobinfo() in callbacks is not the
        #  same as the one in the external python API 
        # ==================================================
        job = qb.jobinfo("-id", qb.jobid())[0]
        fh.write('submitted %(id)s: %(name)s\n' % job)
    except:
        fh.write(traceback.format_exc())
    fh.close()
    
    sys.exit(0) 

     

    Include+
    scrollPageId405BE23F014B092BED873659461D31E3
    scrollEditorDisplayTitle_universal_cb_vs_flightchecks
    scrollEditorUrlhttp://docs.pipelinefx.com/display/QUBE/._universal_cb_vs_flightchecks+v6.6-3

    qb.conf Parameters

    supervisor_universal_callback_path

    ...