~lifeless/ubuntu/lucid/bzr/2.1.2-sru

« back to all changes in this revision

Viewing changes to doc/developers/container-format.txt

  • Committer: Bazaar Package Importer
  • Author(s): Jelmer Vernooij
  • Date: 2010-02-17 17:47:40 UTC
  • mfrom: (1.5.2 upstream)
  • mto: This revision was merged to the branch mainline in revision 13.
  • Revision ID: james.westby@ubuntu.com-20100217174740-p1x5dd5uwvxtg9y6
Tags: upstream-2.1.0
ImportĀ upstreamĀ versionĀ 2.1.0

Show diffs side-by-side

added added

removed removed

Lines of Context:
129
129
------------------
130
130
 
131
131
There is a requirement that each object can be given an arbitrary name.
132
 
Some revision control systems address all content by the SHA-1 digest of
 
132
Some version control systems address all content by the SHA-1 digest of
133
133
that content, but this scheme is unsatisfactory for Bazaar's revision
134
134
objects.  We can still allow addressing by SHA-1 digest for those content
135
135
types where it makes sense.
136
136
 
137
137
Some proposed object names:
138
138
 
139
 
  * to name a revision: "``revision:``\ *revision-id*".  e.g., 
 
139
  * to name a revision: "``revision:``\ *revision-id*".  e.g.,
140
140
    `revision:pqm@pqm.ubuntu.com-20070531210833-8ptk86ocu822hjd5`.
141
141
  * to name an inventory delta: "``inventory.delta:``\ *revision-id*".  e.g.,
142
142
    `inventory.delta:pqm@pqm.ubuntu.com-20070531210833-8ptk86ocu822hjd5`.
155
155
 
156
156
  * a record's content could be self-describing in the context of a
157
157
    particular container, or
158
 
  * a record could be accessed via an index based on SHA-1, or 
 
158
  * a record could be accessed via an index based on SHA-1, or
159
159
  * when streaming, the first record could be treated specially.
160
160
 
161
161
Reasonably cheap for small records
203
203
A **Bytes** record:
204
204
 
205
205
  * has a kind marker of "``B``",
206
 
  * followed by a mandatory **content length** [1]_: 
 
206
  * followed by a mandatory **content length** [1]_:
207
207
    "*number*\ ``\n``", where *number* is in decimal, e.g::
208
208
 
209
209
      1234
210
210
 
211
 
  * followed by zero or more optional **names**: 
 
211
  * followed by zero or more optional **names**:
212
212
    "*name*\ ``\n``", e.g.::
213
213
 
214
214
      revision:pqm@pqm.ubuntu.com-20070531210833-8ptk86ocu822hjd5