Ævar Arnfjörð Bjarmason | 5db9210 | 2022-08-04 18:28:36 +0200 | [diff] [blame] | 1 | gitprotocol-capabilities(5) |
| 2 | =========================== |
| 3 | |
| 4 | NAME |
| 5 | ---- |
| 6 | gitprotocol-capabilities - Protocol v0 and v1 capabilities |
| 7 | |
| 8 | SYNOPSIS |
| 9 | -------- |
| 10 | [verse] |
| 11 | <over-the-wire-protocol> |
| 12 | |
| 13 | DESCRIPTION |
| 14 | ----------- |
Scott Chacon | b31222c | 2009-11-03 21:58:23 -0800 | [diff] [blame] | 15 | |
Josh Steadmon | 90503a2 | 2019-02-19 16:32:26 -0800 | [diff] [blame] | 16 | NOTE: this document describes capabilities for versions 0 and 1 of the pack |
Ævar Arnfjörð Bjarmason | 5db9210 | 2022-08-04 18:28:36 +0200 | [diff] [blame] | 17 | protocol. For version 2, please refer to the linkgit:gitprotocol-v2[5] |
Josh Steadmon | 90503a2 | 2019-02-19 16:32:26 -0800 | [diff] [blame] | 18 | doc. |
| 19 | |
Scott Chacon | b31222c | 2009-11-03 21:58:23 -0800 | [diff] [blame] | 20 | Servers SHOULD support all capabilities defined in this document. |
| 21 | |
| 22 | On the very first line of the initial server response of either |
| 23 | receive-pack and upload-pack the first reference is followed by |
| 24 | a NUL byte and then a list of space delimited server capabilities. |
| 25 | These allow the server to declare what it can and cannot support |
| 26 | to the client. |
| 27 | |
| 28 | Client will then send a space separated list of capabilities it wants |
| 29 | to be in effect. The client MUST NOT ask for capabilities the server |
| 30 | did not say it supports. |
| 31 | |
| 32 | Server MUST diagnose and abort if capabilities it does not understand |
Elijah Newren | ce14cc0 | 2023-10-08 06:45:09 +0000 | [diff] [blame] | 33 | were sent. Server MUST NOT ignore capabilities that client requested |
Scott Chacon | b31222c | 2009-11-03 21:58:23 -0800 | [diff] [blame] | 34 | and server advertised. As a consequence of these rules, server MUST |
| 35 | NOT advertise capabilities it does not understand. |
| 36 | |
Jiang Xin | b913075 | 2020-08-27 11:45:47 -0400 | [diff] [blame] | 37 | The 'atomic', 'report-status', 'report-status-v2', 'delete-refs', 'quiet', |
| 38 | and 'push-cert' capabilities are sent and recognized by the receive-pack |
| 39 | (push to server) process. |
Scott Chacon | b31222c | 2009-11-03 21:58:23 -0800 | [diff] [blame] | 40 | |
Jeff King | 9354b9a | 2013-07-24 04:01:59 -0400 | [diff] [blame] | 41 | The 'ofs-delta' and 'side-band-64k' capabilities are sent and recognized |
Josh Steadmon | f5cdbe4 | 2020-11-11 15:29:24 -0800 | [diff] [blame] | 42 | by both upload-pack and receive-pack protocols. The 'agent' and 'session-id' |
| 43 | capabilities may optionally be sent in both protocols. |
Scott Chacon | b31222c | 2009-11-03 21:58:23 -0800 | [diff] [blame] | 44 | |
| 45 | All other capabilities are only recognized by the upload-pack (fetch |
| 46 | from server) process. |
| 47 | |
| 48 | multi_ack |
| 49 | --------- |
| 50 | |
| 51 | The 'multi_ack' capability allows the server to return "ACK obj-id |
| 52 | continue" as soon as it finds a commit that it can use as a common |
| 53 | base, between the client's wants and the client's have set. |
| 54 | |
| 55 | By sending this early, the server can potentially head off the client |
| 56 | from walking any further down that particular branch of the client's |
| 57 | repository history. The client may still need to walk down other |
| 58 | branches, sending have lines for those, until the server has a |
| 59 | complete cut across the DAG, or the client has said "done". |
| 60 | |
| 61 | Without multi_ack, a client sends have lines in --date-order until |
| 62 | the server has found a common base. That means the client will send |
| 63 | have lines that are already known by the server to be common, because |
Elijah Newren | cf6cac2 | 2023-10-08 06:45:03 +0000 | [diff] [blame] | 64 | they overlap in time with another branch on which the server hasn't found |
| 65 | a common base yet. |
Scott Chacon | b31222c | 2009-11-03 21:58:23 -0800 | [diff] [blame] | 66 | |
| 67 | For example suppose the client has commits in caps that the server |
| 68 | doesn't and the server has commits in lower case that the client |
| 69 | doesn't, as in the following diagram: |
| 70 | |
| 71 | +---- u ---------------------- x |
| 72 | / +----- y |
| 73 | / / |
| 74 | a -- b -- c -- d -- E -- F |
| 75 | \ |
| 76 | +--- Q -- R -- S |
| 77 | |
| 78 | If the client wants x,y and starts out by saying have F,S, the server |
| 79 | doesn't know what F,S is. Eventually the client says "have d" and |
| 80 | the server sends "ACK d continue" to let the client know to stop |
Ralf Wildenhues | 6a5d0b0 | 2010-01-31 14:24:39 +0100 | [diff] [blame] | 81 | walking down that line (so don't send c-b-a), but it's not done yet, |
Scott Chacon | b31222c | 2009-11-03 21:58:23 -0800 | [diff] [blame] | 82 | it needs a base for x. The client keeps going with S-R-Q, until a |
| 83 | gets reached, at which point the server has a clear base and it all |
| 84 | ends. |
| 85 | |
| 86 | Without multi_ack the client would have sent that c-b-a chain anyway, |
| 87 | interleaved with S-R-Q. |
| 88 | |
Nguyễn Thái Ngọc Duy | 087e347 | 2014-02-06 22:10:37 +0700 | [diff] [blame] | 89 | multi_ack_detailed |
| 90 | ------------------ |
Elijah Newren | 0a4f051 | 2023-10-08 06:45:17 +0000 | [diff] [blame] | 91 | This is an extension of multi_ack that permits the client to better |
Ævar Arnfjörð Bjarmason | 5db9210 | 2022-08-04 18:28:36 +0200 | [diff] [blame] | 92 | understand the server's in-memory state. See linkgit:gitprotocol-pack[5], |
Nguyễn Thái Ngọc Duy | 087e347 | 2014-02-06 22:10:37 +0700 | [diff] [blame] | 93 | section "Packfile Negotiation" for more information. |
| 94 | |
Nguyễn Thái Ngọc Duy | c9cd60f | 2014-02-06 22:10:38 +0700 | [diff] [blame] | 95 | no-done |
| 96 | ------- |
| 97 | This capability should only be used with the smart HTTP protocol. If |
| 98 | multi_ack_detailed and no-done are both present, then the sender is |
| 99 | free to immediately send a pack following its first "ACK obj-id ready" |
| 100 | message. |
| 101 | |
| 102 | Without no-done in the smart HTTP protocol, the server session would |
| 103 | end and the client has to make another trip to send "done" before |
| 104 | the server can send the pack. no-done removes the last round and |
| 105 | thus slightly reduces latency. |
| 106 | |
Scott Chacon | b31222c | 2009-11-03 21:58:23 -0800 | [diff] [blame] | 107 | thin-pack |
| 108 | --------- |
| 109 | |
Carlos Martín Nieto | 1ba98a7 | 2013-11-23 17:07:55 +0100 | [diff] [blame] | 110 | A thin pack is one with deltas which reference base objects not |
| 111 | contained within the pack (but are known to exist at the receiving |
| 112 | end). This can reduce the network traffic significantly, but it |
| 113 | requires the receiving end to know how to "thicken" these packs by |
| 114 | adding the missing bases to the pack. |
Scott Chacon | b31222c | 2009-11-03 21:58:23 -0800 | [diff] [blame] | 115 | |
Carlos Martín Nieto | 1ba98a7 | 2013-11-23 17:07:55 +0100 | [diff] [blame] | 116 | The upload-pack server advertises 'thin-pack' when it can generate |
| 117 | and send a thin pack. A client requests the 'thin-pack' capability |
| 118 | when it understands how to "thicken" it, notifying the server that |
| 119 | it can receive such a pack. A client MUST NOT request the |
| 120 | 'thin-pack' capability if it cannot turn a thin pack into a |
| 121 | self-contained pack. |
| 122 | |
| 123 | Receive-pack, on the other hand, is assumed by default to be able to |
| 124 | handle thin packs, but can ask the client not to use the feature by |
| 125 | advertising the 'no-thin' capability. A client MUST NOT send a thin |
| 126 | pack if the server advertises the 'no-thin' capability. |
| 127 | |
| 128 | The reasons for this asymmetry are historical. The receive-pack |
| 129 | program did not exist until after the invention of thin packs, so |
| 130 | historically the reference implementation of receive-pack always |
| 131 | understood thin packs. Adding 'no-thin' later allowed receive-pack |
| 132 | to disable the feature in a backwards-compatible manner. |
Scott Chacon | b31222c | 2009-11-03 21:58:23 -0800 | [diff] [blame] | 133 | |
| 134 | |
| 135 | side-band, side-band-64k |
| 136 | ------------------------ |
| 137 | |
Elijah Newren | cf6cac2 | 2023-10-08 06:45:03 +0000 | [diff] [blame] | 138 | This capability means that the server can send, and the client can understand, multiplexed |
Scott Chacon | b31222c | 2009-11-03 21:58:23 -0800 | [diff] [blame] | 139 | progress reports and error info interleaved with the packfile itself. |
| 140 | |
| 141 | These two options are mutually exclusive. A modern client always |
| 142 | favors 'side-band-64k'. |
| 143 | |
| 144 | Either mode indicates that the packfile data will be streamed broken |
| 145 | up into packets of up to either 1000 bytes in the case of 'side_band', |
| 146 | or 65520 bytes in the case of 'side_band_64k'. Each packet is made up |
| 147 | of a leading 4-byte pkt-line length of how much data is in the packet, |
| 148 | followed by a 1-byte stream code, followed by the actual data. |
| 149 | |
| 150 | The stream code can be one of: |
| 151 | |
| 152 | 1 - pack data |
| 153 | 2 - progress messages |
| 154 | 3 - fatal error message just before stream aborts |
| 155 | |
| 156 | The "side-band-64k" capability came about as a way for newer clients |
| 157 | that can handle much larger packets to request packets that are |
| 158 | actually crammed nearly full, while maintaining backward compatibility |
| 159 | for the older clients. |
| 160 | |
| 161 | Further, with side-band and its up to 1000-byte messages, it's actually |
| 162 | 999 bytes of payload and 1 byte for the stream code. With side-band-64k, |
| 163 | same deal, you have up to 65519 bytes of data and 1 byte for the stream |
| 164 | code. |
| 165 | |
Elijah Newren | cf6cac2 | 2023-10-08 06:45:03 +0000 | [diff] [blame] | 166 | The client MUST send only one of "side-band" and "side- |
| 167 | band-64k". The server MUST diagnose it as an error if client requests |
Scott Chacon | b31222c | 2009-11-03 21:58:23 -0800 | [diff] [blame] | 168 | both. |
| 169 | |
| 170 | ofs-delta |
| 171 | --------- |
| 172 | |
Elijah Newren | cf6cac2 | 2023-10-08 06:45:03 +0000 | [diff] [blame] | 173 | The server can send, and the client can understand, PACKv2 with delta referring to |
Scott Chacon | b31222c | 2009-11-03 21:58:23 -0800 | [diff] [blame] | 174 | its base by position in pack rather than by an obj-id. That is, they can |
| 175 | send/read OBJ_OFS_DELTA (aka type 6) in a packfile. |
| 176 | |
Jeff King | af60826 | 2013-07-24 04:03:13 -0400 | [diff] [blame] | 177 | agent |
| 178 | ----- |
| 179 | |
| 180 | The server may optionally send a capability of the form `agent=X` to |
| 181 | notify the client that the server is running version `X`. The client may |
| 182 | optionally return its own agent string by responding with an `agent=Y` |
| 183 | capability (but it MUST NOT do so if the server did not mention the |
| 184 | agent capability). The `X` and `Y` strings may contain any printable |
| 185 | ASCII characters except space (i.e., the byte range 32 < x < 127), and |
| 186 | are typically of the form "package/version" (e.g., "git/1.8.3.1"). The |
| 187 | agent strings are purely informative for statistics and debugging |
Thomas Ackermann | f745acb | 2014-11-03 21:37:07 +0100 | [diff] [blame] | 188 | purposes, and MUST NOT be used to programmatically assume the presence |
Jeff King | af60826 | 2013-07-24 04:03:13 -0400 | [diff] [blame] | 189 | or absence of particular features. |
| 190 | |
brian m. carlson | b8615c3 | 2020-05-13 00:53:42 +0000 | [diff] [blame] | 191 | object-format |
| 192 | ------------- |
| 193 | |
| 194 | This capability, which takes a hash algorithm as an argument, indicates |
| 195 | that the server supports the given hash algorithms. It may be sent |
| 196 | multiple times; if so, the first one given is the one used in the ref |
| 197 | advertisement. |
| 198 | |
| 199 | When provided by the client, this indicates that it intends to use the |
| 200 | given hash algorithm to communicate. The algorithm provided must be one |
| 201 | that the server supports. |
| 202 | |
| 203 | If this capability is not provided, it is assumed that the only |
| 204 | supported algorithm is SHA-1. |
| 205 | |
Josh Steadmon | 90503a2 | 2019-02-19 16:32:26 -0800 | [diff] [blame] | 206 | symref |
| 207 | ------ |
| 208 | |
| 209 | This parameterized capability is used to inform the receiver which symbolic ref |
| 210 | points to which ref; for example, "symref=HEAD:refs/heads/master" tells the |
| 211 | receiver that HEAD points to master. This capability can be repeated to |
| 212 | represent multiple symrefs. |
| 213 | |
| 214 | Servers SHOULD include this capability for the HEAD symref if it is one of the |
| 215 | refs being sent. |
| 216 | |
| 217 | Clients MAY use the parameters from this capability to select the proper initial |
| 218 | branch when cloning a repository. |
| 219 | |
Scott Chacon | b31222c | 2009-11-03 21:58:23 -0800 | [diff] [blame] | 220 | shallow |
| 221 | ------- |
| 222 | |
| 223 | This capability adds "deepen", "shallow" and "unshallow" commands to |
| 224 | the fetch-pack/upload-pack protocol so clients can request shallow |
| 225 | clones. |
| 226 | |
Nguyễn Thái Ngọc Duy | 569e554 | 2016-06-12 17:53:58 +0700 | [diff] [blame] | 227 | deepen-since |
| 228 | ------------ |
| 229 | |
| 230 | This capability adds "deepen-since" command to fetch-pack/upload-pack |
| 231 | protocol so the client can request shallow clones that are cut at a |
| 232 | specific time, instead of depth. Internally it's equivalent of doing |
| 233 | "rev-list --max-age=<timestamp>" on the server side. "deepen-since" |
| 234 | cannot be used with "deepen". |
| 235 | |
Nguyễn Thái Ngọc Duy | 269a7a8 | 2016-06-12 17:54:03 +0700 | [diff] [blame] | 236 | deepen-not |
| 237 | ---------- |
| 238 | |
| 239 | This capability adds "deepen-not" command to fetch-pack/upload-pack |
| 240 | protocol so the client can request shallow clones that are cut at a |
| 241 | specific revision, instead of depth. Internally it's equivalent of |
| 242 | doing "rev-list --not <rev>" on the server side. "deepen-not" |
| 243 | cannot be used with "deepen", but can be used with "deepen-since". |
| 244 | |
Nguyễn Thái Ngọc Duy | cccf74e | 2016-06-12 17:54:09 +0700 | [diff] [blame] | 245 | deepen-relative |
| 246 | --------------- |
| 247 | |
| 248 | If this capability is requested by the client, the semantics of |
| 249 | "deepen" command is changed. The "depth" argument is the depth from |
| 250 | the current shallow boundary, instead of the depth from remote refs. |
| 251 | |
Scott Chacon | b31222c | 2009-11-03 21:58:23 -0800 | [diff] [blame] | 252 | no-progress |
| 253 | ----------- |
| 254 | |
Elijah Newren | cf6cac2 | 2023-10-08 06:45:03 +0000 | [diff] [blame] | 255 | The client was started with "git clone -q" or something similar, and doesn't |
Scott Chacon | b31222c | 2009-11-03 21:58:23 -0800 | [diff] [blame] | 256 | want that side band 2. Basically the client just says "I do not |
| 257 | wish to receive stream 2 on sideband, so do not send it to me, and if |
| 258 | you did, I will drop it on the floor anyway". However, the sideband |
| 259 | channel 3 is still used for error responses. |
| 260 | |
| 261 | include-tag |
| 262 | ----------- |
| 263 | |
| 264 | The 'include-tag' capability is about sending annotated tags if we are |
| 265 | sending objects they point to. If we pack an object to the client, and |
| 266 | a tag object points exactly at that object, we pack the tag object too. |
| 267 | In general this allows a client to get all new annotated tags when it |
| 268 | fetches a branch, in a single network connection. |
| 269 | |
| 270 | Clients MAY always send include-tag, hardcoding it into a request when |
| 271 | the server advertises this capability. The decision for a client to |
| 272 | request include-tag only has to do with the client's desires for tag |
| 273 | data, whether or not a server had advertised objects in the |
| 274 | refs/tags/* namespace. |
| 275 | |
Elijah Newren | 384f7d1 | 2023-10-08 06:45:05 +0000 | [diff] [blame] | 276 | Servers MUST pack the tags if their referent is packed and the client |
Scott Chacon | b31222c | 2009-11-03 21:58:23 -0800 | [diff] [blame] | 277 | has requested include-tags. |
| 278 | |
| 279 | Clients MUST be prepared for the case where a server has ignored |
| 280 | include-tag and has not actually sent tags in the pack. In such |
| 281 | cases the client SHOULD issue a subsequent fetch to acquire the tags |
| 282 | that include-tag would have otherwise given the client. |
| 283 | |
| 284 | The server SHOULD send include-tag, if it supports it, regardless |
| 285 | of whether or not there are tags available. |
| 286 | |
| 287 | report-status |
| 288 | ------------- |
| 289 | |
Jeff King | 9a621ad | 2013-07-24 04:01:21 -0400 | [diff] [blame] | 290 | The receive-pack process can receive a 'report-status' capability, |
Scott Chacon | b31222c | 2009-11-03 21:58:23 -0800 | [diff] [blame] | 291 | which tells it that the client wants a report of what happened after |
| 292 | a packfile upload and reference update. If the pushing client requests |
| 293 | this capability, after unpacking and updating references the server |
| 294 | will respond with whether the packfile unpacked successfully and if |
| 295 | each reference was updated successfully. If any of those were not |
Ævar Arnfjörð Bjarmason | 5db9210 | 2022-08-04 18:28:36 +0200 | [diff] [blame] | 296 | successful, it will send back an error message. See linkgit:gitprotocol-pack[5] |
Scott Chacon | b31222c | 2009-11-03 21:58:23 -0800 | [diff] [blame] | 297 | for example messages. |
| 298 | |
Jiang Xin | b913075 | 2020-08-27 11:45:47 -0400 | [diff] [blame] | 299 | report-status-v2 |
| 300 | ---------------- |
| 301 | |
| 302 | Capability 'report-status-v2' extends capability 'report-status' by |
| 303 | adding new "option" directives in order to support reference rewritten by |
| 304 | the "proc-receive" hook. The "proc-receive" hook may handle a command |
| 305 | for a pseudo-reference which may create or update a reference with |
| 306 | different name, new-oid, and old-oid. While the capability |
Ævar Arnfjörð Bjarmason | 5db9210 | 2022-08-04 18:28:36 +0200 | [diff] [blame] | 307 | 'report-status' cannot report for such case. See linkgit:gitprotocol-pack[5] |
Jiang Xin | b913075 | 2020-08-27 11:45:47 -0400 | [diff] [blame] | 308 | for details. |
| 309 | |
Scott Chacon | b31222c | 2009-11-03 21:58:23 -0800 | [diff] [blame] | 310 | delete-refs |
| 311 | ----------- |
| 312 | |
| 313 | If the server sends back the 'delete-refs' capability, it means that |
Ralf Wildenhues | 6a5d0b0 | 2010-01-31 14:24:39 +0100 | [diff] [blame] | 314 | it is capable of accepting a zero-id value as the target |
Scott Chacon | b31222c | 2009-11-03 21:58:23 -0800 | [diff] [blame] | 315 | value of a reference update. It is not sent back by the client, it |
| 316 | simply informs the client that it can be sent zero-id values |
| 317 | to delete references. |
Jeff King | 69fb960 | 2013-07-24 04:03:43 -0400 | [diff] [blame] | 318 | |
| 319 | quiet |
| 320 | ----- |
| 321 | |
| 322 | If the receive-pack server advertises the 'quiet' capability, it is |
| 323 | capable of silencing human-readable progress output which otherwise may |
| 324 | be shown when processing the received pack. A send-pack client should |
| 325 | respond with the 'quiet' capability to suppress server-side progress |
| 326 | reporting if the local progress reporting is also being suppressed |
| 327 | (e.g., via `push -q`, or if stderr does not go to a tty). |
Nguyễn Thái Ngọc Duy | 4acbe91 | 2013-07-26 18:01:54 +0700 | [diff] [blame] | 328 | |
Ronnie Sahlberg | 1b70fe5 | 2015-01-07 19:23:20 -0800 | [diff] [blame] | 329 | atomic |
| 330 | ------ |
| 331 | |
| 332 | If the server sends the 'atomic' capability it is capable of accepting |
| 333 | atomic pushes. If the pushing client requests this capability, the server |
| 334 | will update the refs in one atomic transaction. Either all refs are |
| 335 | updated or none. |
| 336 | |
Stefan Beller | c714e45 | 2016-07-14 14:49:46 -0700 | [diff] [blame] | 337 | push-options |
| 338 | ------------ |
| 339 | |
| 340 | If the server sends the 'push-options' capability it is able to accept |
| 341 | push options after the update commands have been sent, but before the |
| 342 | packfile is streamed. If the pushing client requests this capability, |
| 343 | the server will pass the options to the pre- and post- receive hooks |
| 344 | that process this push request. |
| 345 | |
Nguyễn Thái Ngọc Duy | 4acbe91 | 2013-07-26 18:01:54 +0700 | [diff] [blame] | 346 | allow-tip-sha1-in-want |
| 347 | ---------------------- |
| 348 | |
| 349 | If the upload-pack server advertises this capability, fetch-pack may |
Martin Ågren | 0756e61 | 2020-08-15 18:06:01 +0200 | [diff] [blame] | 350 | send "want" lines with object names that exist at the server but are not |
| 351 | advertised by upload-pack. For historical reasons, the name of this |
| 352 | capability contains "sha1". Object names are always given using the |
| 353 | object format negotiated through the 'object-format' capability. |
Junio C Hamano | 4adf569 | 2014-08-18 14:38:45 -0700 | [diff] [blame] | 354 | |
Fredrik Medley | 68ee628 | 2015-05-21 22:23:39 +0200 | [diff] [blame] | 355 | allow-reachable-sha1-in-want |
| 356 | ---------------------------- |
| 357 | |
| 358 | If the upload-pack server advertises this capability, fetch-pack may |
Martin Ågren | 0756e61 | 2020-08-15 18:06:01 +0200 | [diff] [blame] | 359 | send "want" lines with object names that exist at the server but are not |
| 360 | advertised by upload-pack. For historical reasons, the name of this |
| 361 | capability contains "sha1". Object names are always given using the |
| 362 | object format negotiated through the 'object-format' capability. |
Fredrik Medley | 68ee628 | 2015-05-21 22:23:39 +0200 | [diff] [blame] | 363 | |
Junio C Hamano | b89363e | 2014-08-21 16:45:30 -0700 | [diff] [blame] | 364 | push-cert=<nonce> |
| 365 | ----------------- |
Junio C Hamano | 4adf569 | 2014-08-18 14:38:45 -0700 | [diff] [blame] | 366 | |
| 367 | The receive-pack server that advertises this capability is willing |
Junio C Hamano | b89363e | 2014-08-21 16:45:30 -0700 | [diff] [blame] | 368 | to accept a signed push certificate, and asks the <nonce> to be |
| 369 | included in the push certificate. A send-pack client MUST NOT |
Junio C Hamano | 4adf569 | 2014-08-18 14:38:45 -0700 | [diff] [blame] | 370 | send a push-cert packet unless the receive-pack server advertises |
| 371 | this capability. |
Jeff Hostetler | 10ac85c | 2017-12-08 15:58:39 +0000 | [diff] [blame] | 372 | |
| 373 | filter |
| 374 | ------ |
| 375 | |
| 376 | If the upload-pack server advertises the 'filter' capability, |
| 377 | fetch-pack may send "filter" commands to request a partial clone |
| 378 | or partial fetch and request that the server omit various objects |
| 379 | from the packfile. |
Josh Steadmon | f5cdbe4 | 2020-11-11 15:29:24 -0800 | [diff] [blame] | 380 | |
Jean-Noël Avila | 2162f9f | 2023-12-25 21:21:26 +0000 | [diff] [blame] | 381 | session-id=<session-id> |
Josh Steadmon | f5cdbe4 | 2020-11-11 15:29:24 -0800 | [diff] [blame] | 382 | ----------------------- |
| 383 | |
| 384 | The server may advertise a session ID that can be used to identify this process |
| 385 | across multiple requests. The client may advertise its own session ID back to |
| 386 | the server as well. |
| 387 | |
| 388 | Session IDs should be unique to a given process. They must fit within a |
| 389 | packet-line, and must not contain non-printable or whitespace characters. The |
| 390 | current implementation uses trace2 session IDs (see |
Todd Zullinger | 086eaab | 2022-09-16 02:23:02 -0400 | [diff] [blame] | 391 | link:technical/api-trace2.html[api-trace2] for details), but this may change |
| 392 | and users of the session ID should not rely on this fact. |
Ævar Arnfjörð Bjarmason | 5db9210 | 2022-08-04 18:28:36 +0200 | [diff] [blame] | 393 | |
| 394 | GIT |
| 395 | --- |
| 396 | Part of the linkgit:git[1] suite |