Part of lp.codehosting
Module | branchfs | The Launchpad code hosting file system. |
Module | branchfsclient | Client code for the branch filesystem endpoint. |
Module | hooks | Implementations for the seen_new_branch_hook of BranchFileSystemClient . |
Package | tests | No package docstring; 6/6 modules documented |
Module | transport | Transport utilities for the codehosting system. |
From the __init__.py module:
Class | AsyncLaunchpadTransport | Virtual transport to implement the Launchpad VFS for branches. |
Class | BranchFileSystemClient | Wrapper for some methods of the codehosting endpoint. |
Class | LaunchpadServer | The Server used for the public SSH codehosting service. |
Function | branch_id_to_path | Convert the given branch ID into NN/NN/NN/NN form, where NN is a two |
Function | get_lp_server | Create a Launchpad server. |
Function | get_ro_server | Get a Launchpad internal server for scanning branches. |
Function | get_rw_server | Get a server that can write to the Launchpad branch vfs. |
Some filesystems are not capable of dealing with large numbers of inodes. The codehosting system has tens of thousands of branches and thus splits the branches into several directories. The Launchpad id is used in order to determine the splitting.
Parameters | user_id | A unique database ID of the user whose branches are being served. |
codehosting_endpoint_url | URL for the branch file system end-point. | |
hosted_directory | Where the branches are uploaded to. | |
mirror_directory | Where all Launchpad branches are mirrored. | |
seen_new_branch_hook | ||
Returns | A LaunchpadServer . |
You can only call this usefully on the codehost -- the transport this server provides are backed onto file:/// URLs.
Parameters | direct_database | if True, use a server implementation that talks directly to the database. If False, the default, use a server implementation that talks to the internal XML-RPC server. |