~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/transport/http/wsgi.py

  • Committer: John Arbash Meinel
  • Date: 2008-10-30 00:55:00 UTC
  • mto: (3815.2.5 prepare-1.9)
  • mto: This revision was merged to the branch mainline in revision 3811.
  • Revision ID: john@arbash-meinel.com-20081030005500-r5cej1cxflqhs3io
Switch so that we are using a simple timestamp as the first action.

Show diffs side-by-side

added added

removed removed

Lines of Context:
27
27
from bzrlib.urlutils import local_path_to_url
28
28
    
29
29
 
30
 
def make_app(root, prefix, path_var='REQUEST_URI', readonly=True):
 
30
def make_app(root, prefix, path_var='REQUEST_URI', readonly=True,
 
31
    load_plugins=True, enable_logging=True):
31
32
    """Convenience function to construct a WSGI bzr smart server.
32
33
    
33
34
    :param root: a local path that requests will be relative to.
39
40
        base_transport = get_transport('readonly+' + local_url)
40
41
    else:
41
42
        base_transport = get_transport(local_url)
 
43
    if load_plugins:
 
44
        from bzrlib.plugin import load_plugins
 
45
        load_plugins()
 
46
    if enable_logging:
 
47
        import bzrlib.trace
 
48
        bzrlib.trace.enable_default_logging()
42
49
    app = SmartWSGIApp(base_transport, prefix)
43
50
    app = RelpathSetter(app, '', path_var)
44
51
    return app