Fossil SCM
Continuing work on the VCCP design.
Commit
c3f118c529e94c8f64ddea131a1d8ad016ff1af6ac4c679ee1aff9d8c6b36292
Parent
60794e993c9e3da…
1 file changed
+59
-1
+59
-1
| --- www/vccp/intro.md | ||
| +++ www/vccp/intro.md | ||
| @@ -358,10 +358,23 @@ | ||
| 358 | 358 | To simplify the implementation of VCCP on diverse systems, |
| 359 | 359 | names should be sent as text. If the names for a particular system |
| 360 | 360 | are binary hashes, then the NAME table should store them as |
| 361 | 361 | the hexadecimal representation. |
| 362 | 362 | |
| 363 | +The NAME table can also be used for error messages in a VCCP | |
| 364 | +reply message. If the request contains an error associated with | |
| 365 | +a particular row in the DATA table, or with a particular NAMEID, | |
| 366 | +then an error message is added to the NAME table with NAMEID | |
| 367 | +set to the offending DATA.ID or NAMEID and NAMETYPE set to 2 | |
| 368 | +and with English the error message text in NAME.NAME. Hence, | |
| 369 | +the allowed values for NAME.NAMETYPE are: | |
| 370 | + | |
| 371 | +> | |
| 372 | +| 0: | Name of the object as known to the client | | |
| 373 | +| 1: | Name of the object as known to the server | | |
| 374 | +| 2: | Error message text for the object | | |
| 375 | + | |
| 363 | 376 | #### 3.4.1 NAME Table Example 1 |
| 364 | 377 | |
| 365 | 378 | Suppose a client is pushing a new check-in to the server and the |
| 366 | 379 | check-in text is stored in the DATA.ID=1 row. Then the request |
| 367 | 380 | should contain a NAME table row with NAME.NAMEID=1 (to match the |
| @@ -484,11 +497,12 @@ | ||
| 484 | 497 | is being renamed, the $.file[].oldname field may be included |
| 485 | 498 | to show the previous name of the file, if that information is |
| 486 | 499 | available. |
| 487 | 500 | |
| 488 | 501 | Some version control systems allow tags and properties to be |
| 489 | -associated with a check-in. The $.tag element supports this | |
| 502 | +part of the check-in itself rather than a separate entity. | |
| 503 | +The $.tag element supports this | |
| 490 | 504 | feature. Each element of the $.tag array is a separate tag |
| 491 | 505 | or property. If the $.tag[].propagate field exists and has |
| 492 | 506 | a value of "1", then the tag/property propagates to all |
| 493 | 507 | non-merge children. If the $.tag[].delete field exists and |
| 494 | 508 | has a value of "1", then a propagating tag or property with |
| @@ -495,5 +509,49 @@ | ||
| 495 | 509 | the given name that was set by some ancestor check-in is |
| 496 | 510 | stopped and omitted from this check-in. Version control |
| 497 | 511 | systems that do not support tags and/or properties on check-ins |
| 498 | 512 | or that do not support tag propagation can ignore all of these |
| 499 | 513 | attributes. |
| 514 | + | |
| 515 | +### 3.6 Tag JSON Format | |
| 516 | + | |
| 517 | +A new tag is created using the following JSON syntax: | |
| 518 | + | |
| 519 | +> | |
| 520 | + { | |
| 521 | + "time": DATETIME, -- Time when the tag was created | |
| 522 | + "name": TEXT, -- Name of the tag | |
| 523 | + "from": INT, -- Check-in being tagged | |
| 524 | + "comment": TEXT, -- Message associated with the tag | |
| 525 | + "mimetype": TEXT, -- Mimetype of the message | |
| 526 | + "value": TEXT, -- Value of the tag if it is really a property | |
| 527 | + "delete": 1, -- Stop propagaging this tag | |
| 528 | + "propagate": 1, -- Propagate this tag to direct children | |
| 529 | + "tagger": { -- Person who created this tag | |
| 530 | + "name": TEXT, -- Name or handle | |
| 531 | + "email": TEXT, -- Email address | |
| 532 | + "time": DATETIME -- Override for $.time | |
| 533 | + } | |
| 534 | + } | |
| 535 | + | |
| 536 | +### 3.7 Message Description JSON Format | |
| 537 | + | |
| 538 | +> | |
| 539 | + { | |
| 540 | + "version": INT, -- protocol version number | |
| 541 | + "features": [TEXT], -- supported optional features | |
| 542 | + "client_vcs": TEXT, | |
| 543 | + "server_vcs": TEXT, | |
| 544 | + "credentials": { | |
| 545 | + "username": TEXT, | |
| 546 | + "password": TEXT, | |
| 547 | + } | |
| 548 | + "pull": [{ | |
| 549 | + "branch": TEXT, | |
| 550 | + "decendents_of": TEXT, | |
| 551 | + "after": DATETIME | |
| 552 | + }], | |
| 553 | + "max_size_hint": INT, | |
| 554 | + "done": 1, | |
| 555 | + "more_available": 1, | |
| 556 | + "continue_with": JSON, | |
| 557 | + } | |
| 500 | 558 |
| --- www/vccp/intro.md | |
| +++ www/vccp/intro.md | |
| @@ -358,10 +358,23 @@ | |
| 358 | To simplify the implementation of VCCP on diverse systems, |
| 359 | names should be sent as text. If the names for a particular system |
| 360 | are binary hashes, then the NAME table should store them as |
| 361 | the hexadecimal representation. |
| 362 | |
| 363 | #### 3.4.1 NAME Table Example 1 |
| 364 | |
| 365 | Suppose a client is pushing a new check-in to the server and the |
| 366 | check-in text is stored in the DATA.ID=1 row. Then the request |
| 367 | should contain a NAME table row with NAME.NAMEID=1 (to match the |
| @@ -484,11 +497,12 @@ | |
| 484 | is being renamed, the $.file[].oldname field may be included |
| 485 | to show the previous name of the file, if that information is |
| 486 | available. |
| 487 | |
| 488 | Some version control systems allow tags and properties to be |
| 489 | associated with a check-in. The $.tag element supports this |
| 490 | feature. Each element of the $.tag array is a separate tag |
| 491 | or property. If the $.tag[].propagate field exists and has |
| 492 | a value of "1", then the tag/property propagates to all |
| 493 | non-merge children. If the $.tag[].delete field exists and |
| 494 | has a value of "1", then a propagating tag or property with |
| @@ -495,5 +509,49 @@ | |
| 495 | the given name that was set by some ancestor check-in is |
| 496 | stopped and omitted from this check-in. Version control |
| 497 | systems that do not support tags and/or properties on check-ins |
| 498 | or that do not support tag propagation can ignore all of these |
| 499 | attributes. |
| 500 |
| --- www/vccp/intro.md | |
| +++ www/vccp/intro.md | |
| @@ -358,10 +358,23 @@ | |
| 358 | To simplify the implementation of VCCP on diverse systems, |
| 359 | names should be sent as text. If the names for a particular system |
| 360 | are binary hashes, then the NAME table should store them as |
| 361 | the hexadecimal representation. |
| 362 | |
| 363 | The NAME table can also be used for error messages in a VCCP |
| 364 | reply message. If the request contains an error associated with |
| 365 | a particular row in the DATA table, or with a particular NAMEID, |
| 366 | then an error message is added to the NAME table with NAMEID |
| 367 | set to the offending DATA.ID or NAMEID and NAMETYPE set to 2 |
| 368 | and with English the error message text in NAME.NAME. Hence, |
| 369 | the allowed values for NAME.NAMETYPE are: |
| 370 | |
| 371 | > |
| 372 | | 0: | Name of the object as known to the client | |
| 373 | | 1: | Name of the object as known to the server | |
| 374 | | 2: | Error message text for the object | |
| 375 | |
| 376 | #### 3.4.1 NAME Table Example 1 |
| 377 | |
| 378 | Suppose a client is pushing a new check-in to the server and the |
| 379 | check-in text is stored in the DATA.ID=1 row. Then the request |
| 380 | should contain a NAME table row with NAME.NAMEID=1 (to match the |
| @@ -484,11 +497,12 @@ | |
| 497 | is being renamed, the $.file[].oldname field may be included |
| 498 | to show the previous name of the file, if that information is |
| 499 | available. |
| 500 | |
| 501 | Some version control systems allow tags and properties to be |
| 502 | part of the check-in itself rather than a separate entity. |
| 503 | The $.tag element supports this |
| 504 | feature. Each element of the $.tag array is a separate tag |
| 505 | or property. If the $.tag[].propagate field exists and has |
| 506 | a value of "1", then the tag/property propagates to all |
| 507 | non-merge children. If the $.tag[].delete field exists and |
| 508 | has a value of "1", then a propagating tag or property with |
| @@ -495,5 +509,49 @@ | |
| 509 | the given name that was set by some ancestor check-in is |
| 510 | stopped and omitted from this check-in. Version control |
| 511 | systems that do not support tags and/or properties on check-ins |
| 512 | or that do not support tag propagation can ignore all of these |
| 513 | attributes. |
| 514 | |
| 515 | ### 3.6 Tag JSON Format |
| 516 | |
| 517 | A new tag is created using the following JSON syntax: |
| 518 | |
| 519 | > |
| 520 | { |
| 521 | "time": DATETIME, -- Time when the tag was created |
| 522 | "name": TEXT, -- Name of the tag |
| 523 | "from": INT, -- Check-in being tagged |
| 524 | "comment": TEXT, -- Message associated with the tag |
| 525 | "mimetype": TEXT, -- Mimetype of the message |
| 526 | "value": TEXT, -- Value of the tag if it is really a property |
| 527 | "delete": 1, -- Stop propagaging this tag |
| 528 | "propagate": 1, -- Propagate this tag to direct children |
| 529 | "tagger": { -- Person who created this tag |
| 530 | "name": TEXT, -- Name or handle |
| 531 | "email": TEXT, -- Email address |
| 532 | "time": DATETIME -- Override for $.time |
| 533 | } |
| 534 | } |
| 535 | |
| 536 | ### 3.7 Message Description JSON Format |
| 537 | |
| 538 | > |
| 539 | { |
| 540 | "version": INT, -- protocol version number |
| 541 | "features": [TEXT], -- supported optional features |
| 542 | "client_vcs": TEXT, |
| 543 | "server_vcs": TEXT, |
| 544 | "credentials": { |
| 545 | "username": TEXT, |
| 546 | "password": TEXT, |
| 547 | } |
| 548 | "pull": [{ |
| 549 | "branch": TEXT, |
| 550 | "decendents_of": TEXT, |
| 551 | "after": DATETIME |
| 552 | }], |
| 553 | "max_size_hint": INT, |
| 554 | "done": 1, |
| 555 | "more_available": 1, |
| 556 | "continue_with": JSON, |
| 557 | } |
| 558 |