Warning
This document is for an in-development version of Galaxy. You can alternatively view this page in the latest release if it exists or view the top of the latest release's documentation.
Source code for galaxy.web.framework.middleware.request_id
import uuid
[docs]class RequestIDMiddleware:
"""
A WSGI middleware that creates a unique ID for the request and
puts it in the environment
"""
def __call__(self, environ, start_response):
environ['request_id'] = uuid.uuid1().hex
return self.app(environ, start_response)