GfSE / SpecIF

Specification Integration Facility - schema, constraint checker and examples
Apache License 2.0
15 stars 6 forks source link

Let a revision data consist of a branch name and an ID #28

Closed oalt closed 4 years ago

oalt commented 4 years ago

Represent a revision as a tuple of data

Each revision is unique following this schema. The following rules shall be always followed by all SpecIF providers:

  1. If the replacesis empty, the element is the first one in the branch stated in the revision
  2. If the element is not the first element in the given branch the replaces must always been set
oalt commented 4 years ago

A branch name is also not unique enough. When a second user sets the same branch name we have two different branches with the same name. So we need also a branch ID.

odungern commented 4 years ago

What do you mean by tuple: "branchId-revisionId" as a single string? Or a JSON-Object with multiple properties? I guess (and hope) the former.

odungern commented 4 years ago

Don't quite understand the discussion: A revision tag will be unique with all likelihood, so it doesn't matter in which branch it has been created. We chain the revisions by unique values ... where's the problem? Perhaps we would like to decode in which branch a revision has been created ... then a branchId helps. Or am I missing out on something?

By the way: the replaces property is a list with 0..2 values. There are two values after a 'merge'. (Just to complement the cases listed in the initial comment).

odungern commented 4 years ago

In Telco on 2020-01-29 it has been agreed that there is a mandatory condition that the revision is globally unique and no other. Therefore this is the only requirement imposed by the schema.

Any addition of a branch name or branchId may be helpful and can be adopted by best practice or convention.