At file:///home/pqm/archives/thelove/bzr/%2Btrunk/

------------------------------------------------------------
revno: 3795
revision-id: [EMAIL PROTECTED]
parent: [EMAIL PROTECTED]
parent: [EMAIL PROTECTED]
committer: Canonical.com Patch Queue Manager <[EMAIL PROTECTED]>
branch nick: +trunk
timestamp: Mon 2008-10-27 07:35:19 +0000
message:
  Reduce round-trips when pushing to an existing repo by using the
        get_parent_map RPC more,
        and batching calls to it in _walk_to_common_revisions. (Andrew
        Bennetts)
modified:
  NEWS                           NEWS-20050323055033-4e00b5db738777ff
  bzrlib/remote.py               remote.py-20060720103555-yeeg2x51vn0rbtdp-1
  bzrlib/repository.py           rev_storage.py-20051111201905-119e9401e46257e3
  bzrlib/tests/test_repository.py 
test_repository.py-20060131075918-65c555b881612f4d
    ------------------------------------------------------------
    revno: 3709.5.10
    revision-id: [EMAIL PROTECTED]
    parent: [EMAIL PROTECTED]
    committer: Andrew Bennetts <[EMAIL PROTECTED]>
    branch nick: smart-push-integration
    timestamp: Mon 2008-10-27 18:02:58 +1100
    message:
      Fix test failure caused by missing attributes on DummyRepository.
    modified:
      bzrlib/tests/test_repository.py 
test_repository.py-20060131075918-65c555b881612f4d
    ------------------------------------------------------------
    revno: 3709.5.9
    revision-id: [EMAIL PROTECTED]
    parent: [EMAIL PROTECTED]
    committer: Andrew Bennetts <[EMAIL PROTECTED]>
    branch nick: smart-push-integration
    timestamp: Mon 2008-10-27 17:23:43 +1100
    message:
      Improve NEWS entry.
    modified:
      NEWS                           NEWS-20050323055033-4e00b5db738777ff
    ------------------------------------------------------------
    revno: 3709.5.8
    revision-id: [EMAIL PROTECTED]
    parent: [EMAIL PROTECTED]
    committer: Andrew Bennetts <[EMAIL PROTECTED]>
    branch nick: smart-push-integration
    timestamp: Mon 2008-10-27 17:22:36 +1100
    message:
      Add combined NEWS entry for smart-push-experiment and 
batch-get_parent_map work.
    modified:
      NEWS                           NEWS-20050323055033-4e00b5db738777ff
    ------------------------------------------------------------
    revno: 3709.5.7
    revision-id: [EMAIL PROTECTED]
    parent: [EMAIL PROTECTED]
    parent: [EMAIL PROTECTED]
    committer: Andrew Bennetts <[EMAIL PROTECTED]>
    branch nick: smart-push-integration
    timestamp: Mon 2008-10-27 17:15:46 +1100
    message:
      Merge batch-get_parent_map.
    modified:
      bzrlib/repository.py           
rev_storage.py-20051111201905-119e9401e46257e3
        ------------------------------------------------------------
        revno: 3731.4.5
        revision-id: [EMAIL PROTECTED]
        parent: [EMAIL PROTECTED]
        committer: Andrew Bennetts <[EMAIL PROTECTED]>
        branch nick: batch-get_parent_map
        timestamp: Mon 2008-10-27 17:08:44 +1100
        message:
          Clarify the code slightly.
        modified:
          bzrlib/repository.py           
rev_storage.py-20051111201905-119e9401e46257e3
        ------------------------------------------------------------
        revno: 3731.4.4
        revision-id: [EMAIL PROTECTED]
        parent: [EMAIL PROTECTED]
        parent: [EMAIL PROTECTED]
        committer: Andrew Bennetts <[EMAIL PROTECTED]>
        branch nick: batch-get_parent_map
        timestamp: Mon 2008-10-27 16:10:29 +1100
        message:
          Merge from 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/blackbox/test_dump_btree.py 
test_dump_btree.py-20081008203335-zkpcq230b6vubszz-1
          bzrlib/tests/fake_command.py   
fake_command.py-20081021195002-r9v65tgxx63c25v9-1
          bzrlib/tests/workingtree_implementations/test_get_file_with_stat.py 
test_get_file_with_s-20080922035909-lhdovrr36jpxmu0v-1
          doc/developers/cycle.txt       
cycle.txt-20081017031739-rw24r0cywm2ok3xu-1
          doc/developers/lca_tree_merging.txt 
lca_merge_resolution-20080731173903-8ku77uz7o6smd3jj-1
          tools/packaging/lp-upload-release 
lpuploadrelease-20081020075647-56zdf9z6yav1bx81-1
        modified:
          Makefile                       
Makefile-20050805140406-d96e3498bb61c5bb
          NEWS                           NEWS-20050323055033-4e00b5db738777ff
          bzr                            bzr.py-20050313053754-5485f144c7006fa6
          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_pyx.pyx        
readdir.pyx-20060609152855-rm6v321vuaqyh9tu-1
          bzrlib/_walkdirs_win32.pyx     
_walkdirs_win32.pyx-20080716220454-kweh3tgxez5dvw2l-2
          bzrlib/api.py                  
api.py-20070626082640-35lspz7j0ys7a8ld-1
          bzrlib/branch.py               
branch.py-20050309040759-e4baf4e0d046576e
          bzrlib/branchbuilder.py        
branchbuilder.py-20070427022007-zlxpqz2lannhk6y8-1
          bzrlib/btree_index.py          
index.py-20080624222253-p0x5f92uyh5hw734-7
          bzrlib/builtins.py             
builtins.py-20050830033751-fc01482b9ca23183
          bzrlib/bundle/__init__.py      
changeset.py-20050513021216-b02ab57fb9738913
          bzrlib/bzrdir.py               
bzrdir.py-20060131065624-156dfea39c4387cb
          bzrlib/chunk_writer.py         
chunk_writer.py-20080630234519-6ggn4id17nipovny-1
          bzrlib/cmd_version_info.py     
__init__.py-20051228204928-697d01fdca29c99b
          bzrlib/commands.py             bzr.py-20050309040720-d10f4714595cf8c3
          bzrlib/commit.py               
commit.py-20050511101309-79ec1a0168e0e825
          bzrlib/config.py               
config.py-20051011043216-070c74f4e9e338e8
          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/errors.py               
errors.py-20050309040759-20512168c4e14fbd
          bzrlib/hashcache.py            
hashcache.py-20050706091756-fe3a8cc1143ff24f
          bzrlib/help_topics/__init__.py 
help_topics.py-20060920210027-rnim90q9e0bwxvy4-1
          bzrlib/help_topics/en/hooks.txt 
hooks.txt-20070830033044-xxu2rced13f72dka-1
          bzrlib/index.py                
index.py-20070712131115-lolkarso50vjr64s-1
          bzrlib/knit.py                 knit.py-20051212171256-f056ac8f0fbe1bd9
          bzrlib/lock.py                 lock.py-20050527050856-ec090bb51bc03349
          bzrlib/lockdir.py              
lockdir.py-20060220222025-98258adf27fbdda3
          bzrlib/log.py                  log.py-20050505065812-c40ce11702fe5fb1
          bzrlib/mail_client.py          
mail_client.py-20070809192806-vuxt3t19srtpjpdn-1
          bzrlib/memorytree.py           
memorytree.py-20060906023413-4wlkalbdpsxi2r4y-1
          bzrlib/merge.py                
merge.py-20050513021216-953b65a438527106
          bzrlib/msgeditor.py            
msgeditor.py-20050901111708-ef6d8de98f5d8f2f
          bzrlib/mutabletree.py          
mutabletree.py-20060906023413-4wlkalbdpsxi2r4y-2
          bzrlib/option.py               
option.py-20051014052914-661fb36e76e7362f
          bzrlib/osutils.py              
osutils.py-20050309040759-eeaff12fbf77ac86
          bzrlib/patches.py              
patches.py-20050727183609-378c1cc5972ce908
          bzrlib/plugin.py               
plugin.py-20050622060424-829b654519533d69
          bzrlib/plugins/launchpad/account.py 
account.py-20071011033320-50y6vfftywf4yllw-1
          bzrlib/plugins/launchpad/lp_directory.py 
lp_indirect.py-20070126012204-de5rugwlt22c7u7e-1
          bzrlib/plugins/launchpad/test_account.py 
test_account.py-20071011033320-50y6vfftywf4yllw-2
          bzrlib/plugins/launchpad/test_lp_directory.py 
test_lp_indirect.py-20070126002743-oyle362tzv9cd8mi-1
          bzrlib/repofmt/knitrepo.py     
knitrepo.py-20070206081537-pyy4a00xdas0j4pf-1
          bzrlib/repofmt/pack_repo.py    
pack_repo.py-20070813041115-gjv5ma7ktfqwsjgn-1
          bzrlib/repofmt/weaverepo.py    
presplitout.py-20070125045333-wfav3tsh73oxu3zk-1
          bzrlib/repository.py           
rev_storage.py-20051111201905-119e9401e46257e3
          bzrlib/revision.py             
revision.py-20050309040759-e77802c08f3999d5
          bzrlib/revisionspec.py         
revisionspec.py-20050907152633-17567659fd5c0ddb
          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/store/__init__.py       
store.py-20050309040759-164dc5173d6406c2
          bzrlib/store/versioned/__init__.py 
weavestore.py-20050907094258-88262e0434babab9
          bzrlib/tag.py                  
tag.py-20070212110532-91cw79inah2cfozx-1
          bzrlib/testament.py            
testament.py-20051011100429-6d319a18183b13c8
          bzrlib/tests/__init__.py       
selftest.py-20050531073622-8d0e3c8845c97a64
          bzrlib/tests/blackbox/__init__.py 
__init__.py-20051128053524-eba30d8255e08dc3
          bzrlib/tests/blackbox/test_annotate.py 
testannotate.py-20051013044000-457f44801bfa9d39
          bzrlib/tests/blackbox/test_command_encoding.py 
test_command_encoding.py-20060106032110-45431fd2ce9ff21f
          bzrlib/tests/blackbox/test_commit.py 
test_commit.py-20060212094538-ae88fc861d969db0
          bzrlib/tests/blackbox/test_info.py 
test_info.py-20060215045507-bbdd2d34efab9e0a
          bzrlib/tests/blackbox/test_log.py 
test_log.py-20060112090212-78f6ea560c868e24
          bzrlib/tests/blackbox/test_merge.py 
test_merge.py-20060323225809-9bc0459c19917f41
          bzrlib/tests/blackbox/test_non_ascii.py 
test_non_ascii.py-20060105214030-68010be784a5d854
          bzrlib/tests/blackbox/test_push.py 
test_push.py-20060329002750-929af230d5d22663
          bzrlib/tests/blackbox/test_status.py 
teststatus.py-20050712014354-508855eb9f29f7dc
          bzrlib/tests/blackbox/test_version.py 
test_version.py-20070312060045-ol7th9z035r3im3d-1
          bzrlib/tests/branch_implementations/test_stacking.py 
test_stacking.py-20080214020755-msjlkb7urobwly0f-1
          bzrlib/tests/http_server.py    
httpserver.py-20061012142527-m1yxdj1xazsf8d7s-1
          bzrlib/tests/http_utils.py     
HTTPTestUtil.py-20050914180604-247d3aafb7a43343
          bzrlib/tests/intertree_implementations/__init__.py 
__init__.py-20060724101752-09ysswo1a92uqyoz-3
          bzrlib/tests/per_repository/test_check_reconcile.py 
test_broken.py-20070928125406-62236394w0jpbpd6-2
          bzrlib/tests/per_repository/test_commit_builder.py 
test_commit_builder.py-20060606110838-76e3ra5slucqus81-1
          bzrlib/tests/test__dirstate_helpers.py 
test_dirstate_helper-20070504035751-jsbn00xodv0y1eve-2
          bzrlib/tests/test_api.py       
testapi.py-20051027033546-6f9be2d308d18a52
          bzrlib/tests/test_branch.py    
test_branch.py-20060116013032-97819aa07b8ab3b5
          bzrlib/tests/test_branchbuilder.py 
test_branchbuilder.p-20070427022007-zlxpqz2lannhk6y8-2
          bzrlib/tests/test_btree_index.py 
test_index.py-20080624222253-p0x5f92uyh5hw734-13
          bzrlib/tests/test_bundle.py    test.py-20050630184834-092aa401ab9f039c
          bzrlib/tests/test_bzrdir.py    
test_bzrdir.py-20060131065654-deba40eef51cf220
          bzrlib/tests/test_chunk_writer.py 
test_chunk_writer.py-20080630234519-6ggn4id17nipovny-2
          bzrlib/tests/test_commands.py  
test_command.py-20051019190109-3b17be0f52eaa7a8
          bzrlib/tests/test_config.py    
testconfig.py-20051011041908-742d0c15d8d8c8eb
          bzrlib/tests/test_dirstate.py  
test_dirstate.py-20060728012006-d6mvoihjb3je9peu-2
          bzrlib/tests/test_hashcache.py 
testhashcache.py-20050706091800-0288ab2659338981
          bzrlib/tests/test_http.py      
testhttp.py-20051018020158-b2eef6e867c514d9
          bzrlib/tests/test_index.py     
test_index.py-20070712131115-lolkarso50vjr64s-2
          bzrlib/tests/test_knit.py      
test_knit.py-20051212171302-95d4c00dd5f11f2b
          bzrlib/tests/test_log.py       
testlog.py-20050728115707-1a514809d7d49309
          bzrlib/tests/test_memorytree.py 
test_memorytree.py-20060906023413-4wlkalbdpsxi2r4y-3
          bzrlib/tests/test_merge.py     
testmerge.py-20050905070950-c1b5aa49ff911024
          bzrlib/tests/test_msgeditor.py 
test_msgeditor.py-20051202041359-920315ec6011ee51
          bzrlib/tests/test_options.py   
testoptions.py-20051014093702-96457cfc86319a8f
          bzrlib/tests/test_osutils.py   
test_osutils.py-20051201224856-e48ee24c12182989
          bzrlib/tests/test_osutils_encodings.py 
test_osutils_encodin-20061226013130-kkp732tpt3lm91vv-1
          bzrlib/tests/test_pack_repository.py 
test_pack_repository-20080801043947-eaw0e6h2gu75kwmy-1
          bzrlib/tests/test_patches.py   
test_patches.py-20051231203844-f4974d20f6aea09c
          bzrlib/tests/test_plugins.py   
plugins.py-20050622075746-32002b55e5e943e9
          bzrlib/tests/test_remote.py    
test_remote.py-20060720103555-yeeg2x51vn0rbtdp-2
          bzrlib/tests/test_repository.py 
test_repository.py-20060131075918-65c555b881612f4d
          bzrlib/tests/test_revisionspec.py 
testrevisionnamespaces.py-20050711050225-8b4af89e6b1efe84
          bzrlib/tests/test_selftest.py  
test_selftest.py-20051202044319-c110a115d8c0456a
          bzrlib/tests/test_sftp_transport.py 
testsftp.py-20051027032739-247570325fec7e7e
          bzrlib/tests/test_store.py     
teststore.py-20050826022702-f6caadb647395769
          bzrlib/tests/test_testament.py 
testtestament.py-20051011100429-5df1657310caa929
          bzrlib/tests/test_transform.py 
test_transaction.py-20060105172520-b3ffb3946550e6c4
          bzrlib/tests/test_urlutils.py  
test_urlutils.py-20060502192900-46b1f9579987cf9c
          bzrlib/tests/test_workingtree.py 
testworkingtree.py-20051004024258-b88d0fe8f101d468
          bzrlib/tests/test_workingtree_4.py 
test_workingtree_4.p-20070223025758-531n3tznl3zacv2o-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/trace.py                
trace.py-20050309040759-c8ed824bdcd4748a
          bzrlib/transform.py            
transform.py-20060105172343-dd99e54394d91687
          bzrlib/transport/__init__.py   
transport.py-20050711165921-4978aa7ce1285ad5
          bzrlib/transport/ftp/__init__.py 
ftp.py-20051116161804-58dc9506548c2a53
          bzrlib/transport/ftp/_gssapi.py 
_gssapi.py-20080611190840-7ejrtp884bk5eu72-2
          bzrlib/transport/http/__init__.py 
http_transport.py-20050711212304-506c5fd1059ace96
          bzrlib/transport/http/_urllib2_wrappers.py 
_urllib2_wrappers.py-20060913231729-ha9ugi48ktx481ao-1
          bzrlib/transport/http/wsgi.py  
wsgi.py-20061005091552-rz8pva0olkxv0sd8-2
          bzrlib/transport/remote.py     
ssh.py-20060608202016-c25gvf1ob7ypbus6-1
          bzrlib/transport/sftp.py       sftp.py-20051019050329-ab48ce71b7e32dfe
          bzrlib/transport/ssh.py        
ssh.py-20060824042150-0s9787kng6zv1nwq-1
          bzrlib/tree.py                 tree.py-20050309040759-9d5f2496be663e77
          bzrlib/tuned_gzip.py           
tuned_gzip.py-20060407014720-5aadc518e928e8d2
          bzrlib/util/configobj/configobj.py 
configobj.py-20051018184548-06992a2246425e3e
          bzrlib/version.py              
version.py-20060816024207-ves6ult9a11taj9t-1
          bzrlib/versionedfile.py        
versionedfile.py-20060222045106-5039c71ee3b65490
          bzrlib/weave.py                knit.py-20050627021749-759c29984154256b
          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/HACKING.txt     HACKING-20050805200004-2a5dc975d870f78c
          doc/developers/development-repo.txt 
developmentrepo.txt-20080102200205-raj42k61dch8pjmj-1
          doc/developers/index.txt       
index.txt-20070508041241-qznziunkg0nffhiw-1
          doc/developers/inventory.txt   
inventory.txt-20080103013957-opkrhxy6lmywmx4i-1
          doc/developers/ppa.txt         
ppa.txt-20080722055539-606u7t2z32t3ae4w-1
          doc/developers/releasing.txt   
releasing.txt-20080502015919-fnrcav8fwy8ccibu-1
          doc/en/user-guide/http_smart_server.txt 
fastcgi.txt-20061005091552-rz8pva0olkxv0sd8-3
          setup.py                       
setup.py-20050314065409-02f8a0a6e3f9bc70
        ------------------------------------------------------------
        revno: 3731.4.3
        revision-id: [EMAIL PROTECTED]
        parent: [EMAIL PROTECTED]
        committer: Andrew Bennetts <[EMAIL PROTECTED]>
        branch nick: batch-get_parent_map
        timestamp: Mon 2008-10-27 16:03:29 +1100
        message:
          Rework ghost checking in _walk_to_common_revisions.
        modified:
          bzrlib/repository.py           
rev_storage.py-20051111201905-119e9401e46257e3
        ------------------------------------------------------------
        revno: 3731.4.2
        revision-id: [EMAIL PROTECTED]
        parent: [EMAIL PROTECTED]
        committer: Andrew Bennetts <[EMAIL PROTECTED]>
        branch nick: batch-get_parent_map
        timestamp: Fri 2008-10-03 09:32:46 +1000
        message:
          Move ghost check out of the inner loop.
        modified:
          bzrlib/repository.py           
rev_storage.py-20051111201905-119e9401e46257e3
        ------------------------------------------------------------
        revno: 3731.4.1
        revision-id: [EMAIL PROTECTED]
        parent: [EMAIL PROTECTED]
        committer: Andrew Bennetts <[EMAIL PROTECTED]>
        branch nick: batch-get_parent_map
        timestamp: Fri 2008-09-26 17:45:07 +1000
        message:
          Extract InterOtherToRemoteRepo get_parent_map batching from 
push-improvement-loom.
        modified:
          bzrlib/repository.py           
rev_storage.py-20051111201905-119e9401e46257e3
    ------------------------------------------------------------
    revno: 3709.5.6
    revision-id: [EMAIL PROTECTED]
    parent: [EMAIL PROTECTED]
    parent: [EMAIL PROTECTED]
    committer: Andrew Bennetts <[EMAIL PROTECTED]>
    branch nick: smart-push-experiment
    timestamp: Mon 2008-10-27 17:14:45 +1100
    message:
      Merge from 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/blackbox/test_dump_btree.py 
test_dump_btree.py-20081008203335-zkpcq230b6vubszz-1
      bzrlib/tests/fake_command.py   
fake_command.py-20081021195002-r9v65tgxx63c25v9-1
      bzrlib/tests/workingtree_implementations/test_get_file_with_stat.py 
test_get_file_with_s-20080922035909-lhdovrr36jpxmu0v-1
      doc/developers/cycle.txt       cycle.txt-20081017031739-rw24r0cywm2ok3xu-1
      doc/developers/lca_tree_merging.txt 
lca_merge_resolution-20080731173903-8ku77uz7o6smd3jj-1
      tools/packaging/lp-upload-release 
lpuploadrelease-20081020075647-56zdf9z6yav1bx81-1
    modified:
      .bzrignore                     bzrignore-20050311232317-81f7b71efa2db11a
      Makefile                       Makefile-20050805140406-d96e3498bb61c5bb
      NEWS                           NEWS-20050323055033-4e00b5db738777ff
      bzr                            bzr.py-20050313053754-5485f144c7006fa6
      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/api.py                  api.py-20070626082640-35lspz7j0ys7a8ld-1
      bzrlib/branch.py               branch.py-20050309040759-e4baf4e0d046576e
      bzrlib/branchbuilder.py        
branchbuilder.py-20070427022007-zlxpqz2lannhk6y8-1
      bzrlib/btree_index.py          index.py-20080624222253-p0x5f92uyh5hw734-7
      bzrlib/builtins.py             builtins.py-20050830033751-fc01482b9ca23183
      bzrlib/bundle/__init__.py      
changeset.py-20050513021216-b02ab57fb9738913
      bzrlib/bzrdir.py               bzrdir.py-20060131065624-156dfea39c4387cb
      bzrlib/chunk_writer.py         
chunk_writer.py-20080630234519-6ggn4id17nipovny-1
      bzrlib/cmd_version_info.py     __init__.py-20051228204928-697d01fdca29c99b
      bzrlib/commands.py             bzr.py-20050309040720-d10f4714595cf8c3
      bzrlib/commit.py               commit.py-20050511101309-79ec1a0168e0e825
      bzrlib/config.py               config.py-20051011043216-070c74f4e9e338e8
      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/errors.py               errors.py-20050309040759-20512168c4e14fbd
      bzrlib/hashcache.py            
hashcache.py-20050706091756-fe3a8cc1143ff24f
      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/knit.py                 knit.py-20051212171256-f056ac8f0fbe1bd9
      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/mail_client.py          
mail_client.py-20070809192806-vuxt3t19srtpjpdn-1
      bzrlib/memorytree.py           
memorytree.py-20060906023413-4wlkalbdpsxi2r4y-1
      bzrlib/merge.py                merge.py-20050513021216-953b65a438527106
      bzrlib/msgeditor.py            
msgeditor.py-20050901111708-ef6d8de98f5d8f2f
      bzrlib/mutabletree.py          
mutabletree.py-20060906023413-4wlkalbdpsxi2r4y-2
      bzrlib/option.py               option.py-20051014052914-661fb36e76e7362f
      bzrlib/osutils.py              osutils.py-20050309040759-eeaff12fbf77ac86
      bzrlib/patches.py              patches.py-20050727183609-378c1cc5972ce908
      bzrlib/plugin.py               plugin.py-20050622060424-829b654519533d69
      bzrlib/plugins/launchpad/account.py 
account.py-20071011033320-50y6vfftywf4yllw-1
      bzrlib/plugins/launchpad/lp_directory.py 
lp_indirect.py-20070126012204-de5rugwlt22c7u7e-1
      bzrlib/plugins/launchpad/test_account.py 
test_account.py-20071011033320-50y6vfftywf4yllw-2
      bzrlib/plugins/launchpad/test_lp_directory.py 
test_lp_indirect.py-20070126002743-oyle362tzv9cd8mi-1
      bzrlib/remote.py               remote.py-20060720103555-yeeg2x51vn0rbtdp-1
      bzrlib/repofmt/knitrepo.py     
knitrepo.py-20070206081537-pyy4a00xdas0j4pf-1
      bzrlib/repofmt/pack_repo.py    
pack_repo.py-20070813041115-gjv5ma7ktfqwsjgn-1
      bzrlib/repofmt/weaverepo.py    
presplitout.py-20070125045333-wfav3tsh73oxu3zk-1
      bzrlib/repository.py           
rev_storage.py-20051111201905-119e9401e46257e3
      bzrlib/revision.py             revision.py-20050309040759-e77802c08f3999d5
      bzrlib/revisionspec.py         
revisionspec.py-20050907152633-17567659fd5c0ddb
      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/store/__init__.py       store.py-20050309040759-164dc5173d6406c2
      bzrlib/store/versioned/__init__.py 
weavestore.py-20050907094258-88262e0434babab9
      bzrlib/tag.py                  tag.py-20070212110532-91cw79inah2cfozx-1
      bzrlib/testament.py            
testament.py-20051011100429-6d319a18183b13c8
      bzrlib/tests/__init__.py       selftest.py-20050531073622-8d0e3c8845c97a64
      bzrlib/tests/blackbox/__init__.py 
__init__.py-20051128053524-eba30d8255e08dc3
      bzrlib/tests/blackbox/test_annotate.py 
testannotate.py-20051013044000-457f44801bfa9d39
      bzrlib/tests/blackbox/test_command_encoding.py 
test_command_encoding.py-20060106032110-45431fd2ce9ff21f
      bzrlib/tests/blackbox/test_commit.py 
test_commit.py-20060212094538-ae88fc861d969db0
      bzrlib/tests/blackbox/test_info.py 
test_info.py-20060215045507-bbdd2d34efab9e0a
      bzrlib/tests/blackbox/test_log.py 
test_log.py-20060112090212-78f6ea560c868e24
      bzrlib/tests/blackbox/test_merge.py 
test_merge.py-20060323225809-9bc0459c19917f41
      bzrlib/tests/blackbox/test_non_ascii.py 
test_non_ascii.py-20060105214030-68010be784a5d854
      bzrlib/tests/blackbox/test_push.py 
test_push.py-20060329002750-929af230d5d22663
      bzrlib/tests/blackbox/test_status.py 
teststatus.py-20050712014354-508855eb9f29f7dc
      bzrlib/tests/blackbox/test_version.py 
test_version.py-20070312060045-ol7th9z035r3im3d-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/branch_implementations/test_stacking.py 
test_stacking.py-20080214020755-msjlkb7urobwly0f-1
      bzrlib/tests/http_server.py    
httpserver.py-20061012142527-m1yxdj1xazsf8d7s-1
      bzrlib/tests/http_utils.py     
HTTPTestUtil.py-20050914180604-247d3aafb7a43343
      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/test_check_reconcile.py 
test_broken.py-20070928125406-62236394w0jpbpd6-2
      bzrlib/tests/per_repository/test_commit_builder.py 
test_commit_builder.py-20060606110838-76e3ra5slucqus81-1
      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_api.py       testapi.py-20051027033546-6f9be2d308d18a52
      bzrlib/tests/test_branch.py    
test_branch.py-20060116013032-97819aa07b8ab3b5
      bzrlib/tests/test_branchbuilder.py 
test_branchbuilder.p-20070427022007-zlxpqz2lannhk6y8-2
      bzrlib/tests/test_btree_index.py 
test_index.py-20080624222253-p0x5f92uyh5hw734-13
      bzrlib/tests/test_bundle.py    test.py-20050630184834-092aa401ab9f039c
      bzrlib/tests/test_bzrdir.py    
test_bzrdir.py-20060131065654-deba40eef51cf220
      bzrlib/tests/test_chunk_writer.py 
test_chunk_writer.py-20080630234519-6ggn4id17nipovny-2
      bzrlib/tests/test_commands.py  
test_command.py-20051019190109-3b17be0f52eaa7a8
      bzrlib/tests/test_config.py    
testconfig.py-20051011041908-742d0c15d8d8c8eb
      bzrlib/tests/test_dirstate.py  
test_dirstate.py-20060728012006-d6mvoihjb3je9peu-2
      bzrlib/tests/test_hashcache.py 
testhashcache.py-20050706091800-0288ab2659338981
      bzrlib/tests/test_http.py      testhttp.py-20051018020158-b2eef6e867c514d9
      bzrlib/tests/test_index.py     
test_index.py-20070712131115-lolkarso50vjr64s-2
      bzrlib/tests/test_knit.py      
test_knit.py-20051212171302-95d4c00dd5f11f2b
      bzrlib/tests/test_lockdir.py   
test_lockdir.py-20060220222025-33d4221569a3d600
      bzrlib/tests/test_log.py       testlog.py-20050728115707-1a514809d7d49309
      bzrlib/tests/test_memorytree.py 
test_memorytree.py-20060906023413-4wlkalbdpsxi2r4y-3
      bzrlib/tests/test_merge.py     
testmerge.py-20050905070950-c1b5aa49ff911024
      bzrlib/tests/test_msgeditor.py 
test_msgeditor.py-20051202041359-920315ec6011ee51
      bzrlib/tests/test_options.py   
testoptions.py-20051014093702-96457cfc86319a8f
      bzrlib/tests/test_osutils.py   
test_osutils.py-20051201224856-e48ee24c12182989
      bzrlib/tests/test_osutils_encodings.py 
test_osutils_encodin-20061226013130-kkp732tpt3lm91vv-1
      bzrlib/tests/test_pack_repository.py 
test_pack_repository-20080801043947-eaw0e6h2gu75kwmy-1
      bzrlib/tests/test_patches.py   
test_patches.py-20051231203844-f4974d20f6aea09c
      bzrlib/tests/test_plugins.py   plugins.py-20050622075746-32002b55e5e943e9
      bzrlib/tests/test_remote.py    
test_remote.py-20060720103555-yeeg2x51vn0rbtdp-2
      bzrlib/tests/test_repository.py 
test_repository.py-20060131075918-65c555b881612f4d
      bzrlib/tests/test_revisionspec.py 
testrevisionnamespaces.py-20050711050225-8b4af89e6b1efe84
      bzrlib/tests/test_selftest.py  
test_selftest.py-20051202044319-c110a115d8c0456a
      bzrlib/tests/test_sftp_transport.py 
testsftp.py-20051027032739-247570325fec7e7e
      bzrlib/tests/test_store.py     
teststore.py-20050826022702-f6caadb647395769
      bzrlib/tests/test_testament.py 
testtestament.py-20051011100429-5df1657310caa929
      bzrlib/tests/test_transform.py 
test_transaction.py-20060105172520-b3ffb3946550e6c4
      bzrlib/tests/test_urlutils.py  
test_urlutils.py-20060502192900-46b1f9579987cf9c
      bzrlib/tests/test_win32utils.py 
test_win32utils.py-20070713181630-8xsrjymd3e8mgw23-108
      bzrlib/tests/test_workingtree.py 
testworkingtree.py-20051004024258-b88d0fe8f101d468
      bzrlib/tests/test_workingtree_4.py 
test_workingtree_4.p-20070223025758-531n3tznl3zacv2o-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/trace.py                trace.py-20050309040759-c8ed824bdcd4748a
      bzrlib/transform.py            
transform.py-20060105172343-dd99e54394d91687
      bzrlib/transport/__init__.py   
transport.py-20050711165921-4978aa7ce1285ad5
      bzrlib/transport/ftp/__init__.py ftp.py-20051116161804-58dc9506548c2a53
      bzrlib/transport/ftp/_gssapi.py 
_gssapi.py-20080611190840-7ejrtp884bk5eu72-2
      bzrlib/transport/http/__init__.py 
http_transport.py-20050711212304-506c5fd1059ace96
      bzrlib/transport/http/_urllib2_wrappers.py 
_urllib2_wrappers.py-20060913231729-ha9ugi48ktx481ao-1
      bzrlib/transport/http/wsgi.py  wsgi.py-20061005091552-rz8pva0olkxv0sd8-2
      bzrlib/transport/remote.py     ssh.py-20060608202016-c25gvf1ob7ypbus6-1
      bzrlib/transport/sftp.py       sftp.py-20051019050329-ab48ce71b7e32dfe
      bzrlib/transport/ssh.py        ssh.py-20060824042150-0s9787kng6zv1nwq-1
      bzrlib/tree.py                 tree.py-20050309040759-9d5f2496be663e77
      bzrlib/tuned_gzip.py           
tuned_gzip.py-20060407014720-5aadc518e928e8d2
      bzrlib/util/configobj/configobj.py 
configobj.py-20051018184548-06992a2246425e3e
      bzrlib/version.py              
version.py-20060816024207-ves6ult9a11taj9t-1
      bzrlib/versionedfile.py        
versionedfile.py-20060222045106-5039c71ee3b65490
      bzrlib/weave.py                knit.py-20050627021749-759c29984154256b
      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/HACKING.txt     HACKING-20050805200004-2a5dc975d870f78c
      doc/developers/development-repo.txt 
developmentrepo.txt-20080102200205-raj42k61dch8pjmj-1
      doc/developers/index.txt       index.txt-20070508041241-qznziunkg0nffhiw-1
      doc/developers/inventory.txt   
inventory.txt-20080103013957-opkrhxy6lmywmx4i-1
      doc/developers/ppa.txt         ppa.txt-20080722055539-606u7t2z32t3ae4w-1
      doc/developers/releasing.txt   
releasing.txt-20080502015919-fnrcav8fwy8ccibu-1
      doc/en/user-guide/http_smart_server.txt 
fastcgi.txt-20061005091552-rz8pva0olkxv0sd8-3
      setup.py                       setup.py-20050314065409-02f8a0a6e3f9bc70
    ------------------------------------------------------------
    revno: 3709.5.5
    revision-id: [EMAIL PROTECTED]
    parent: [EMAIL PROTECTED]
    committer: Andrew Bennetts <[EMAIL PROTECTED]>
    branch nick: smart-push-experiment
    timestamp: Wed 2008-09-24 15:34:52 +1000
    message:
      Add comment.
    modified:
      bzrlib/repository.py           
rev_storage.py-20051111201905-119e9401e46257e3
    ------------------------------------------------------------
    revno: 3709.5.4
    revision-id: [EMAIL PROTECTED]
    parent: [EMAIL PROTECTED]
    committer: Andrew Bennetts <[EMAIL PROTECTED]>
    branch nick: smart-push-experiment
    timestamp: Wed 2008-09-24 15:29:31 +1000
    message:
      Remove _parents_map_absences experiment.
    modified:
      bzrlib/remote.py               remote.py-20060720103555-yeeg2x51vn0rbtdp-1
    ------------------------------------------------------------
    revno: 3709.5.3
    revision-id: [EMAIL PROTECTED]
    parent: [EMAIL PROTECTED]
    committer: Andrew Bennetts <[EMAIL PROTECTED]>
    branch nick: smart-push-experiment
    timestamp: Wed 2008-09-24 15:27:20 +1000
    message:
      Invalidate _parents_map_absences cache in RemoteRepository.fetch.
    modified:
      bzrlib/remote.py               remote.py-20060720103555-yeeg2x51vn0rbtdp-1
    ------------------------------------------------------------
    revno: 3709.5.2
    revision-id: [EMAIL PROTECTED]
    parent: [EMAIL PROTECTED]
    parent: [EMAIL PROTECTED]
    committer: Andrew Bennetts <[EMAIL PROTECTED]>
    branch nick: smart-push-experiment
    timestamp: Mon 2008-09-22 17:41:28 +1000
    message:
      Merge from bzr.dev.
    modified:
      NEWS                           NEWS-20050323055033-4e00b5db738777ff
      bzrlib/branch.py               branch.py-20050309040759-e4baf4e0d046576e
      bzrlib/builtins.py             builtins.py-20050830033751-fc01482b9ca23183
      bzrlib/directory_service.py    
directory_service.py-20080305221044-vr2mkvlsk8jypa2y-1
      bzrlib/help_topics/__init__.py 
help_topics.py-20060920210027-rnim90q9e0bwxvy4-1
      bzrlib/remote.py               remote.py-20060720103555-yeeg2x51vn0rbtdp-1
      bzrlib/revisionspec.py         
revisionspec.py-20050907152633-17567659fd5c0ddb
      bzrlib/smart/branch.py         branch.py-20061124031907-mzh3pla28r83r97f-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/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_remove_tree.py 
test_remove_tree.py-20061110192919-5j3xjciiaqbs2dvo-1
      bzrlib/tests/blackbox/test_switch.py 
test_switch.py-20071122111948-0c5en6uz92bwl76h-1
      bzrlib/tests/test_directory_service.py 
test_directory_servi-20080305221044-vr2mkvlsk8jypa2y-2
      bzrlib/tests/test_remote.py    
test_remote.py-20060720103555-yeeg2x51vn0rbtdp-2
      bzrlib/tests/test_smart.py     
test_smart.py-20061122024551-ol0l0o0oofsu9b3t-2
      bzrlib/tests/test_transport_implementations.py 
test_transport_implementations.py-20051227111451-f97c5c7d5c49fce7
      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/transform.py            
transform.py-20060105172343-dd99e54394d91687
      bzrlib/transport/local.py      
local_transport.py-20050711165921-9b1f142bfe480c24
      bzrlib/tree.py                 tree.py-20050309040759-9d5f2496be663e77
      tools/doc_generate/autodoc_man.py 
bzrman.py-20050601153041-0ff7f74de456d15e
    ------------------------------------------------------------
    revno: 3709.5.1
    revision-id: [EMAIL PROTECTED]
    parent: [EMAIL PROTECTED]
    committer: Andrew Bennetts <[EMAIL PROTECTED]>
    branch nick: smart-push-experiment
    timestamp: Wed 2008-09-17 17:52:56 +1000
    message:
      Allow pushing to a pack repo over HPSS use the get_parent_map RPC, and 
teach the get_parent_map client to cache missing revisions.
    modified:
      bzrlib/remote.py               remote.py-20060720103555-yeeg2x51vn0rbtdp-1
      bzrlib/repository.py           
rev_storage.py-20051111201905-119e9401e46257e3
=== modified file 'NEWS'
--- a/NEWS      2008-10-23 17:59:52 +0000
+++ b/NEWS      2008-10-27 06:23:43 +0000
@@ -23,6 +23,11 @@
       btree index repositories, this can save 25% of the index size
       (mostly in the text indexes). (John Arbash Meinel)
 
+    * ``bzr push`` to an existing branch or repository on a smart server
+      is faster, due to Bazaar making more use of the ``get_parent_map``
+      RPC when querying the remote branch's revision graph.
+      (Andrew Bennetts)
+
     * default username for bzr+ssh and sftp can be configured in
       authentication.conf. (Aaron Bentley)
 

=== modified file 'bzrlib/remote.py'
--- a/bzrlib/remote.py  2008-09-23 02:16:55 +0000
+++ b/bzrlib/remote.py  2008-10-27 06:14:45 +0000
@@ -799,7 +799,7 @@
         return repository.InterRepository.get(
             other, self).search_missing_revision_ids(revision_id, find_ghosts)
 
-    def fetch(self, source, revision_id=None, pb=None):
+    def fetch(self, source, revision_id=None, pb=None, find_ghosts=False):
         if self.has_same_location(source):
             # check that last_revision is in 'from' and then return a
             # no-operation.
@@ -807,9 +807,12 @@
                 not revision.is_null(revision_id)):
                 self.get_revision(revision_id)
             return 0, []
-        self._ensure_real()
-        return self._real_repository.fetch(
-            source, revision_id=revision_id, pb=pb)
+        inter = repository.InterRepository.get(source, self)
+        try:
+            return inter.fetch(revision_id=revision_id, pb=pb, 
find_ghosts=find_ghosts)
+
+        except NotImplementedError:
+            raise errors.IncompatibleRepositories(source, self)
 
     def create_bundle(self, target, base, fileobj, format=None):
         self._ensure_real()

=== modified file 'bzrlib/repository.py'
--- a/bzrlib/repository.py      2008-10-01 05:40:45 +0000
+++ b/bzrlib/repository.py      2008-10-27 06:15:46 +0000
@@ -2353,9 +2353,17 @@
     InterRepository.get(other).method_name(parameters).
     """
 
+    _walk_to_common_revisions_batch_size = 1
     _optimisers = []
     """The available optimised InterRepository types."""
 
+    def __init__(self, source, target):
+        InterObject.__init__(self, source, target)
+        # These two attributes may be overridden by e.g. InterOtherToRemote to
+        # provide a faster implementation.
+        self.target_get_graph = self.target.get_graph
+        self.target_get_parent_map = self.target.get_parent_map
+
     def copy_content(self, revision_id=None):
         raise NotImplementedError(self.copy_content)
 
@@ -2386,8 +2394,13 @@
         :param revision_ids: The start point for the search.
         :return: A set of revision ids.
         """
-        target_graph = self.target.get_graph()
+        target_graph = self.target_get_graph()
         revision_ids = frozenset(revision_ids)
+        # Fast path for the case where all the revisions are already in the
+        # target repo.
+        # (Although this does incur an extra round trip for the
+        # fairly common case where the target doesn't already have the revision
+        # we're pushing.)
         if set(target_graph.get_parent_map(revision_ids)) == revision_ids:
             return graph.SearchResult(revision_ids, set(), 0, set())
         missing_revs = set()
@@ -2395,25 +2408,40 @@
         # ensure we don't pay silly lookup costs.
         searcher = source_graph._make_breadth_first_searcher(revision_ids)
         null_set = frozenset([_mod_revision.NULL_REVISION])
+        searcher_exhausted = False
         while True:
-            try:
-                next_revs, ghosts = searcher.next_with_ghosts()
-            except StopIteration:
-                break
-            if revision_ids.intersection(ghosts):
-                absent_ids = set(revision_ids.intersection(ghosts))
-                # If all absent_ids are present in target, no error is needed.
-                absent_ids.difference_update(
-                    set(target_graph.get_parent_map(absent_ids)))
-                if absent_ids:
-                    raise errors.NoSuchRevision(self.source, absent_ids.pop())
-            # we don't care about other ghosts as we can't fetch them and
+            next_revs = set()
+            ghosts = set()
+            # Iterate the searcher until we have enough next_revs
+            while len(next_revs) < self._walk_to_common_revisions_batch_size:
+                try:
+                    next_revs_part, ghosts_part = searcher.next_with_ghosts()
+                    next_revs.update(next_revs_part)
+                    ghosts.update(ghosts_part)
+                except StopIteration:
+                    searcher_exhausted = True
+                    break
+            # If there are ghosts in the source graph, and the caller asked for
+            # them, make sure that they are present in the target.
+            # We don't care about other ghosts as we can't fetch them and
             # haven't been asked to.
-            next_revs = set(next_revs)
-            # we always have NULL_REVISION present.
-            have_revs = 
set(target_graph.get_parent_map(next_revs)).union(null_set)
-            missing_revs.update(next_revs - have_revs)
-            searcher.stop_searching_any(have_revs)
+            ghosts_to_check = set(revision_ids.intersection(ghosts))
+            revs_to_get = set(next_revs).union(ghosts_to_check)
+            if revs_to_get:
+                have_revs = set(target_graph.get_parent_map(revs_to_get))
+                # we always have NULL_REVISION present.
+                have_revs = have_revs.union(null_set)
+                # Check if the target is missing any ghosts we need.
+                ghosts_to_check.difference_update(have_revs)
+                if ghosts_to_check:
+                    # One of the caller's revision_ids is a ghost in both the
+                    # source and the target.
+                    raise errors.NoSuchRevision(
+                        self.source, ghosts_to_check.pop())
+                missing_revs.update(next_revs - have_revs)
+                searcher.stop_searching_any(have_revs)
+            if searcher_exhausted:
+                break
         return searcher.get_result()
    
     @deprecated_method(one_two)
@@ -2781,7 +2809,7 @@
             # till then:
             source_revision_ids = frozenset(self.source.all_revision_ids())
             revision_ids = source_revision_ids - \
-                frozenset(self.target.get_parent_map(source_revision_ids))
+                frozenset(self.target_get_parent_map(source_revision_ids))
             revision_keys = [(revid,) for revid in revision_ids]
             index = self.target._pack_collection.revision_index.combined_index
             present_revision_ids = set(item[1][0] for item in
@@ -2830,7 +2858,7 @@
         elif revision_id is not None:
             # Find ghosts: search for revisions pointing from one repository to
             # the other, and vice versa, anywhere in the history of 
revision_id.
-            graph = self.target.get_graph(other_repository=self.source)
+            graph = self.target_get_graph(other_repository=self.source)
             searcher = graph._make_breadth_first_searcher([revision_id])
             found_ids = set()
             while True:
@@ -2846,7 +2874,7 @@
             # Double query here: should be able to avoid this by changing the
             # graph api further.
             result_set = found_ids - frozenset(
-                self.target.get_parent_map(found_ids))
+                self.target_get_parent_map(found_ids))
         else:
             source_ids = self.source.all_revision_ids()
             # source_ids is the worst possible case we may need to pull.
@@ -3022,6 +3050,8 @@
 
 class InterOtherToRemote(InterRepository):
 
+    _walk_to_common_revisions_batch_size = 50
+
     def __init__(self, source, target):
         InterRepository.__init__(self, source, target)
         self._real_inter = None
@@ -3037,6 +3067,9 @@
             self.target._ensure_real()
             real_target = self.target._real_repository
             self._real_inter = InterRepository.get(self.source, real_target)
+            # Make _real_inter use the RemoteRepository for get_parent_map
+            self._real_inter.target_get_graph = self.target.get_graph
+            self._real_inter.target_get_parent_map = self.target.get_parent_map
     
     def copy_content(self, revision_id=None):
         self._ensure_real_inter()

=== modified file 'bzrlib/tests/test_repository.py'
--- a/bzrlib/tests/test_repository.py   2008-10-16 18:58:22 +0000
+++ b/bzrlib/tests/test_repository.py   2008-10-27 07:02:58 +0000
@@ -478,6 +478,12 @@
     def supports_rich_root(self):
         return False
 
+    def get_graph(self):
+        raise NotImplementedError
+
+    def get_parent_map(self, revision_ids):
+        raise NotImplementedError
+
 
 class InterDummy(repository.InterRepository):
     """An inter-repository optimised code path for DummyRepository.


-- 
bazaar-commits mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/bazaar-commits

Reply via email to