Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(1)  |  Call(1)  |  Derive(0)  |  Import(0)
Generate header for delivery and reply of queue request.

Xqueue header is a JSON-serialized dict:
    { 'lms_callback_url': url to which xqueue will return the request (string),
      'lms_key': secret key used by LMS to protect its state (string),
      'queue_name': designate a specific queue within xqueue server, e.g. 'MITx-6.00x' (string)
    }

        def make_xheader(lms_callback_url, lms_key, queue_name):
    """
    Generate header for delivery and reply of queue request.

    Xqueue header is a JSON-serialized dict:
        { 'lms_callback_url': url to which xqueue will return the request (string),
          'lms_key': secret key used by LMS to protect its state (string),
          'queue_name': designate a specific queue within xqueue server, e.g. 'MITx-6.00x' (string)
        }
    """
    return json.dumps({'lms_callback_url': lms_callback_url,
                        'lms_key': lms_key,
                        'queue_name': queue_name})
        


src/m/h/MHST2013-14-HEAD/edx_all/edx-platform/common/lib/capa/capa/inputtypes.py   MHST2013-14(Download)
                                                 self.input_id)
        xheader = xqueue_interface.make_xheader(
            lms_callback_url=callback_url,
            lms_key=queuekey,
            queue_name=self.queuename)