def deploy(project_name):
    """Assemble the middleware pipeline"""
    request_log = requestlog.RequestLog
    header_addon = HeaderControl
    fault_wrapper = FaultWrapper
    application = handler.SdkHandler()

    # currently we have 3 middleware
    for middleware in (header_addon,
                       fault_wrapper,
                       request_log,
                       ):
        if middleware:
            application = middleware(application)

    return application
def deploy ( project_name ) : request_log = requestlog . RequestLog header_addon = HeaderControl fault_wrapper = FaultWrapper application = handler . SdkHandler ( ) for middleware in ( header_addon , fault_wrapper , request_log , ) : if middleware : application = middleware ( application ) return application
Assemble the middleware pipeline