Page MenuHomePhabricator

Support serving SVN repositories over SSH
ClosedPublic

Authored by epriestley on Nov 11 2013, 5:05 AM.
Tags
None
Referenced Files
Unknown Object (File)
Thu, Apr 11, 6:19 PM
Unknown Object (File)
Wed, Apr 10, 5:55 AM
Unknown Object (File)
Apr 5 2024, 9:04 PM
Unknown Object (File)
Apr 5 2024, 9:04 PM
Unknown Object (File)
Apr 5 2024, 9:04 PM
Unknown Object (File)
Apr 5 2024, 9:04 PM
Unknown Object (File)
Apr 5 2024, 8:40 PM
Unknown Object (File)
Apr 5 2024, 8:14 PM
Subscribers

Details

Reviewers
btrahan
Maniphest Tasks
Restricted Maniphest Task
Commits
Restricted Diffusion Commit
rP85f505465e53: Support serving SVN repositories over SSH
Summary

Ref T2230. The SVN protocol has a sensible protocol format with a good spec here:

http://svn.apache.org/repos/asf/subversion/trunk/subversion/libsvn_ra_svn/protocol

Particularly, compare this statement to the clown show that is the Mercurial wire protocol:

It is possible to parse an item without knowing its type in advance.

WHAT A REASONABLE STATEMENT TO BE ABLE TO MAKE ABOUT A WIRE PROTOCOL

Although it makes substantially more sense than Mercurial, it's much heavier-weight than the Git or Mercurial protocols, since it isn't distributed.

It's also not possible to figure out if a request is a write request (or even which repository it is against) without proxying some of the protocol frames. Finally, several protocol commands embed repository URLs, and we need to reach into the protocol and translate them.

Test Plan

Ran various SVN commands over SSH (svn log, svn up, svn commit, etc).

Diff Detail

Lint
Lint Skipped
Unit
Tests Skipped

Event Timeline

I'm going to covert the protocol parsing stuff with some tests, this is just a reasonable checkpoint for the night.

whoops

src/applications/diffusion/protocol/DiffusionSubversionWireProtocol.php
35โ€“36

derps

41โ€“42

more derps

71

xtra derps

88

also derps

epriestley updated this revision to Unknown Object (????).Nov 11 2013, 5:08 AM

Fewer derps.

epriestley updated this revision to Unknown Object (????).Nov 11 2013, 5:09 PM
  • Add unit tests.
  • Move some code to more sensible places.
  • Re-ran various SVN commands: checkout, update, log, diff, commit.