Rev 3743: (Marius Kruger) Update the wsgi bindings to load plugins and enable in file:///home/pqm/archives/thelove/bzr/%2Btrunk/
Canonical.com Patch Queue Manager
pqm at pqm.ubuntu.com
Fri Sep 26 21:36:31 BST 2008
At file:///home/pqm/archives/thelove/bzr/%2Btrunk/
------------------------------------------------------------
revno: 3743
revision-id: pqm at pqm.ubuntu.com-20080926203628-5yzejrl21kt639nk
parent: pqm at pqm.ubuntu.com-20080926163732-67umt69x8t9kpc2b
parent: amanic at gmail.com-20080926155740-qbkzu018vt20edph
committer: Canonical.com Patch Queue Manager <pqm at pqm.ubuntu.com>
branch nick: +trunk
timestamp: Fri 2008-09-26 21:36:28 +0100
message:
(Marius Kruger) Update the wsgi bindings to load plugins and enable
logging (optional)
modified:
NEWS NEWS-20050323055033-4e00b5db738777ff
bzrlib/transport/http/wsgi.py wsgi.py-20061005091552-rz8pva0olkxv0sd8-2
doc/en/user-guide/http_smart_server.txt fastcgi.txt-20061005091552-rz8pva0olkxv0sd8-3
------------------------------------------------------------
revno: 3708.1.5
revision-id: amanic at gmail.com-20080926155740-qbkzu018vt20edph
parent: amanic at gmail.com-20080926152653-gyrl20hfrw74fjtt
committer: Marius Kruger <amanic at gmail.com>
branch nick: bzr.bzr_http_with_plugins_and_logs
timestamp: Fri 2008-09-26 17:57:40 +0200
message:
add news
modified:
NEWS NEWS-20050323055033-4e00b5db738777ff
------------------------------------------------------------
revno: 3708.1.4
revision-id: amanic at gmail.com-20080926152653-gyrl20hfrw74fjtt
parent: amanic at gmail.com-20080914215109-iujglr8zczotkafm
parent: pqm at pqm.ubuntu.com-20080926054703-nxn5f1h7z7gvur96
committer: Marius Kruger <amanic at gmail.com>
branch nick: bzr.bzr_http_with_plugins_and_logs
timestamp: Fri 2008-09-26 17:26:53 +0200
message:
merge with bzr.dev
removed:
bzrlib/_walkdirs_win32.h _walkdirs_win32.h-20080716220454-kweh3tgxez5dvw2l-1
added:
bzrlib/python-compat.h pythoncompat.h-20080924041409-9kvi0fgtuuqp743j-1
bzrlib/tests/workingtree_implementations/test_get_file_with_stat.py test_get_file_with_s-20080922035909-lhdovrr36jpxmu0v-1
modified:
.bzrignore bzrignore-20050311232317-81f7b71efa2db11a
NEWS NEWS-20050323055033-4e00b5db738777ff
bzrlib/__init__.py __init__.py-20050309040759-33e65acf91bbcd5d
bzrlib/_btree_serializer_c.pyx _parse_btree_c.pyx-20080703034413-3q25bklkenti3p8p-2
bzrlib/_dirstate_helpers_c.pyx dirstate_helpers.pyx-20070503201057-u425eni465q4idwn-3
bzrlib/_dirstate_helpers_py.py _dirstate_helpers_py-20070710145033-90nz6cqglsk150jy-1
bzrlib/_patiencediff_c.c _patiencediff_c.c-20070721205602-q3imkipwlgagp3cy-1
bzrlib/_readdir_py.py readdir.py-20060609152855-rm6v321vuaqyh9tu-3
bzrlib/_readdir_pyx.pyx readdir.pyx-20060609152855-rm6v321vuaqyh9tu-1
bzrlib/_walkdirs_win32.pyx _walkdirs_win32.pyx-20080716220454-kweh3tgxez5dvw2l-2
bzrlib/annotate.py annotate.py-20050922133147-7c60541d2614f022
bzrlib/branch.py branch.py-20050309040759-e4baf4e0d046576e
bzrlib/builtins.py builtins.py-20050830033751-fc01482b9ca23183
bzrlib/bzrdir.py bzrdir.py-20060131065624-156dfea39c4387cb
bzrlib/commit.py commit.py-20050511101309-79ec1a0168e0e825
bzrlib/delta.py delta.py-20050729221636-54cf14ef94783d0a
bzrlib/diff.py diff.py-20050309040759-26944fbbf2ebbf36
bzrlib/directory_service.py directory_service.py-20080305221044-vr2mkvlsk8jypa2y-1
bzrlib/dirstate.py dirstate.py-20060728012006-d6mvoihjb3je9peu-1
bzrlib/help_topics/__init__.py help_topics.py-20060920210027-rnim90q9e0bwxvy4-1
bzrlib/help_topics/en/hooks.txt hooks.txt-20070830033044-xxu2rced13f72dka-1
bzrlib/hooks.py hooks.py-20070325015548-ix4np2q0kd8452au-1
bzrlib/index.py index.py-20070712131115-lolkarso50vjr64s-1
bzrlib/lock.py lock.py-20050527050856-ec090bb51bc03349
bzrlib/lockdir.py lockdir.py-20060220222025-98258adf27fbdda3
bzrlib/log.py log.py-20050505065812-c40ce11702fe5fb1
bzrlib/lsprof.py lsprof.py-20051208071030-833790916798ceed
bzrlib/mutabletree.py mutabletree.py-20060906023413-4wlkalbdpsxi2r4y-2
bzrlib/osutils.py osutils.py-20050309040759-eeaff12fbf77ac86
bzrlib/remote.py remote.py-20060720103555-yeeg2x51vn0rbtdp-1
bzrlib/repository.py rev_storage.py-20051111201905-119e9401e46257e3
bzrlib/revisionspec.py revisionspec.py-20050907152633-17567659fd5c0ddb
bzrlib/smart/branch.py branch.py-20061124031907-mzh3pla28r83r97f-1
bzrlib/smart/client.py client.py-20061116014825-2k6ada6xgulslami-1
bzrlib/smart/medium.py medium.py-20061103051856-rgu2huy59fkz902q-1
bzrlib/smart/request.py request.py-20061108095550-gunadhxmzkdjfeek-1
bzrlib/smart/server.py server.py-20061110062051-chzu10y32vx8gvur-1
bzrlib/status.py status.py-20050505062338-431bfa63ec9b19e6
bzrlib/tests/__init__.py selftest.py-20050531073622-8d0e3c8845c97a64
bzrlib/tests/blackbox/test_annotate.py testannotate.py-20051013044000-457f44801bfa9d39
bzrlib/tests/blackbox/test_branch.py test_branch.py-20060524161337-noms9gmcwqqrfi8y-1
bzrlib/tests/blackbox/test_init.py test_init.py-20060309032856-a292116204d86eb7
bzrlib/tests/blackbox/test_log.py test_log.py-20060112090212-78f6ea560c868e24
bzrlib/tests/blackbox/test_remove_tree.py test_remove_tree.py-20061110192919-5j3xjciiaqbs2dvo-1
bzrlib/tests/blackbox/test_status.py teststatus.py-20050712014354-508855eb9f29f7dc
bzrlib/tests/blackbox/test_switch.py test_switch.py-20071122111948-0c5en6uz92bwl76h-1
bzrlib/tests/branch_implementations/test_break_lock.py test_break_lock.py-20060504111902-9aae411dbe9aadd2
bzrlib/tests/branch_implementations/test_hooks.py test_hooks.py-20070129154855-blhpwxmvjs07waei-1
bzrlib/tests/branch_implementations/test_push.py test_push.py-20070130153159-fhfap8uoifevg30j-1
bzrlib/tests/intertree_implementations/__init__.py __init__.py-20060724101752-09ysswo1a92uqyoz-3
bzrlib/tests/intertree_implementations/test_compare.py test_compare.py-20060724101752-09ysswo1a92uqyoz-2
bzrlib/tests/per_repository/__init__.py __init__.py-20060131092037-9564957a7d4a841b
bzrlib/tests/per_repository/test_commit_builder.py test_commit_builder.py-20060606110838-76e3ra5slucqus81-1
bzrlib/tests/per_repository/test_repository.py test_repository.py-20060131092128-ad07f494f5c9d26c
bzrlib/tests/test__dirstate_helpers.py test_dirstate_helper-20070504035751-jsbn00xodv0y1eve-2
bzrlib/tests/test__walkdirs_win32.py test__walkdirs_win32-20080716220454-kweh3tgxez5dvw2l-3
bzrlib/tests/test_directory_service.py test_directory_servi-20080305221044-vr2mkvlsk8jypa2y-2
bzrlib/tests/test_dirstate.py test_dirstate.py-20060728012006-d6mvoihjb3je9peu-2
bzrlib/tests/test_lockdir.py test_lockdir.py-20060220222025-33d4221569a3d600
bzrlib/tests/test_log.py testlog.py-20050728115707-1a514809d7d49309
bzrlib/tests/test_osutils.py test_osutils.py-20051201224856-e48ee24c12182989
bzrlib/tests/test_remote.py test_remote.py-20060720103555-yeeg2x51vn0rbtdp-2
bzrlib/tests/test_revisionspec.py testrevisionnamespaces.py-20050711050225-8b4af89e6b1efe84
bzrlib/tests/test_selftest.py test_selftest.py-20051202044319-c110a115d8c0456a
bzrlib/tests/test_smart.py test_smart.py-20061122024551-ol0l0o0oofsu9b3t-2
bzrlib/tests/test_transform.py test_transaction.py-20060105172520-b3ffb3946550e6c4
bzrlib/tests/test_transport_implementations.py test_transport_implementations.py-20051227111451-f97c5c7d5c49fce7
bzrlib/tests/test_win32utils.py test_win32utils.py-20070713181630-8xsrjymd3e8mgw23-108
bzrlib/tests/test_workingtree_4.py test_workingtree_4.p-20070223025758-531n3tznl3zacv2o-1
bzrlib/tests/tree_implementations/test_inv.py test_inv.py-20070312023226-0cdvk5uwhutis9vg-1
bzrlib/tests/tree_implementations/test_tree.py test_tree.py-20061215160206-usu7lwcj8aq2n3br-1
bzrlib/tests/workingtree_implementations/__init__.py __init__.py-20060203003124-b2aa5aca21a8bfad
bzrlib/tests/workingtree_implementations/test_remove.py test_remove.py-20070413183901-rvnp85rtc0q0sclp-1
bzrlib/transform.py transform.py-20060105172343-dd99e54394d91687
bzrlib/transport/local.py local_transport.py-20050711165921-9b1f142bfe480c24
bzrlib/tree.py tree.py-20050309040759-9d5f2496be663e77
bzrlib/win32utils.py win32console.py-20051021033308-123c6c929d04973d
bzrlib/workingtree.py workingtree.py-20050511021032-29b6ec0a681e02e3
bzrlib/workingtree_4.py workingtree_4.py-20070208044105-5fgpc5j3ljlh5q6c-1
doc/developers/inventory.txt inventory.txt-20080103013957-opkrhxy6lmywmx4i-1
setup.py setup.py-20050314065409-02f8a0a6e3f9bc70
tools/doc_generate/autodoc_man.py bzrman.py-20050601153041-0ff7f74de456d15e
------------------------------------------------------------
revno: 3708.1.3
revision-id: amanic at gmail.com-20080914215109-iujglr8zczotkafm
parent: amanic at gmail.com-20080914214840-92raq370k4af3py1
committer: Marius Kruger <amanic at gmail.com>
branch nick: bzr.bzr_http_with_plugins_and_logs
timestamp: Sun 2008-09-14 23:51:09 +0200
message:
note extra options to wsgi.make_app in docs
modified:
doc/en/user-guide/http_smart_server.txt fastcgi.txt-20061005091552-rz8pva0olkxv0sd8-3
------------------------------------------------------------
revno: 3708.1.2
revision-id: amanic at gmail.com-20080914214840-92raq370k4af3py1
parent: amanic at gmail.com-20080914184734-jpgi1t7ibipuq2i4
committer: Marius Kruger <amanic at gmail.com>
branch nick: bzr.bzr_http_with_plugins_and_logs
timestamp: Sun 2008-09-14 23:48:40 +0200
message:
wsgi.make_app can now optionally do normal logging (used by bzr+http://)
modified:
bzrlib/transport/http/wsgi.py wsgi.py-20061005091552-rz8pva0olkxv0sd8-2
------------------------------------------------------------
revno: 3708.1.1
revision-id: amanic at gmail.com-20080914184734-jpgi1t7ibipuq2i4
parent: pqm at pqm.ubuntu.com-20080912142101-kj49buaas8zsqf5x
committer: Marius Kruger <amanic at gmail.com>
branch nick: bzr.bzr_http_with_plugins_and_logs
timestamp: Sun 2008-09-14 20:47:34 +0200
message:
wsgi.make_app can now optionally load plugins (used by bzr+http://)
modified:
bzrlib/transport/http/wsgi.py wsgi.py-20061005091552-rz8pva0olkxv0sd8-2
=== modified file 'NEWS'
--- a/NEWS 2008-09-26 05:47:03 +0000
+++ b/NEWS 2008-09-26 15:57:40 +0000
@@ -15,6 +15,9 @@
towards your mainline. This simplifies the output, makes it faster,
and reduces memory consumption. (John Arbash Meinel)
+ * ``bzr+http//`` will now optionally load plugins and write logs on the
+ server. (Marius Kruger)
+
FEATURES
IMPROVEMENTS:
=== modified file 'bzrlib/transport/http/wsgi.py'
--- a/bzrlib/transport/http/wsgi.py 2008-05-16 05:55:23 +0000
+++ b/bzrlib/transport/http/wsgi.py 2008-09-14 21:48:40 +0000
@@ -27,7 +27,8 @@
from bzrlib.urlutils import local_path_to_url
-def make_app(root, prefix, path_var='REQUEST_URI', readonly=True):
+def make_app(root, prefix, path_var='REQUEST_URI', readonly=True,
+ load_plugins=True, enable_logging=True):
"""Convenience function to construct a WSGI bzr smart server.
:param root: a local path that requests will be relative to.
@@ -39,6 +40,12 @@
base_transport = get_transport('readonly+' + local_url)
else:
base_transport = get_transport(local_url)
+ if load_plugins:
+ from bzrlib.plugin import load_plugins
+ load_plugins()
+ if enable_logging:
+ import bzrlib.trace
+ bzrlib.trace.enable_default_logging()
app = SmartWSGIApp(base_transport, prefix)
app = RelpathSetter(app, '', path_var)
return app
=== modified file 'doc/en/user-guide/http_smart_server.txt'
--- a/doc/en/user-guide/http_smart_server.txt 2008-09-11 06:09:44 +0000
+++ b/doc/en/user-guide/http_smart_server.txt 2008-09-14 21:51:09 +0000
@@ -135,7 +135,9 @@
root='/srv/example.com/www/code',
prefix='/code/',
path_var='REQUEST_URI',
- readonly=True)
+ readonly=True,
+ load_plugins=True,
+ enable_logging=True)
fcgi.WSGIServer(smart_server_app).run()
@@ -159,7 +161,9 @@
root='/srv/example.com/www/code',
prefix='/code/',
path_var='REQUEST_URI',
- readonly=True)
+ readonly=True,
+ load_plugins=True,
+ enable_logging=True)
def handler(request):
"""Handle a single request."""
More information about the bazaar-commits
mailing list