Skip to content

Commit

Permalink
Merge pull request #141 from djmitche/0139-addendum
Browse files Browse the repository at this point in the history
Amend RFC#139 to reduce 40 to 38, omit org/repo
  • Loading branch information
djmitche authored Feb 8, 2019
2 parents 2a2b1fb + d50569f commit 6e1e147
Showing 1 changed file with 26 additions and 9 deletions.
35 changes: 26 additions & 9 deletions rfcs/0139-longer-identifiers.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# RFC 139 - Increase identifier length from 20 to 44
# RFC 139 - Increase identifier length from 20 to 38
* Comments: [#139](https://api.github.com/repos/taskcluster/taskcluster-rfcs/pull/139), [Bug 1520579](https://bugzilla.mozilla.org/show_bug.cgi?id=1520579)
* Proposed by: @djmitche / @mitchhentges

Expand All @@ -19,25 +19,42 @@ We can, however, allow more than 22 characters.

We will define two types of identifiers:

* "identifiers" -- up to 40 characters, generally containing human-readable identifiers
* "identifiers" -- up to 38 characters, generally containing human-readable identifiers
* `provisionerId`, `workerType`, `workerGroup`, `workerId`
* `schedulerId`
* `organization`, `repository` (in tc-github)

* "slugids" -- exactly 22 characters, always a slugid
* `taskGroupId`
* `taskId`

The following remain separate:
* `organization`, `repository` (limited to 100 characters in taskcluster-github)

The rationale for the choice of 38 is the [task status routing key](https://docs.taskcluster.net/docs/reference/platform/taskcluster-queue/references/events#routing-key) which contains

| name | max characters |
|----------------|----------------|
| routingKeyKind | 7 |
| taskId | 22 |
| runId | 3 |
| workerGroup | N |
| workerId | N |
| provisionerId | N |
| workerType | N |
| schedulerId | N |
| taskGroupId | 22 |
| reserved | 1 |

With a total of 9 dots between each of those components.
So the total length is `5N + 55 + 9 <= 255`.
Solving for N, we get 38.

This change requires changes to schemas and API declarations in services in the monorepo, as well as to `aws-provisioner` and possibly `ec2-manager`, workers, and client libraries.
Much of this work has [already been done](https://github.com/taskcluster/taskcluster/pull/110) by @OjaswinM.

We already have checks on AMQP routing key lengths, and the increased length does not cause any failures in that code.

# Open Questions

TBD

# Implementation

* https://github.com/taskcluster/taskcluster/pull/110
* TBD
* [taskcluster/taskcluster#110](https://github.com/taskcluster/taskcluster/pull/110)
* [Bug 1520579](https://bugzilla.mozilla.org/show_bug.cgi?id=1520579)

0 comments on commit 6e1e147

Please sign in to comment.