Skip to content

BenchX identity policy

urn:benchx:schema:identity-policy:0.1.0 · version 0.1.0 · schema.json · source

A project's identity policy (docs/design/benchmark-result-schema.md section 4.3): for every reported fact, whether it must match, as is or normalized, for two results to share a series, or is ignored. It is the project's default projection, whose axis is always the subject revision, so only the roles are stored; other projections, such as the comparison profiles of section 5.5, reuse these roles with a different axis. Which estimators a project derives series for is separate configuration (section 4.5): the estimator enters series_fingerprint on its own, so adding one never changes the policy.

Implementer note

Rules the server enforces: paths are JSON Pointers into the reported coordinates (project, source, benchmark, coordinates); the longest matching path wins, so a role on a subtree can be overridden for one member; a null fact never equals anything; an ignored fact whose value differs from the previous point of a series is recorded as a warning on that point; any change other than description needs a new identity_schema.

Properties

Property Required Type Description
identity_schema yes token Versioned name of the policy. Enters comparison_fingerprint, so series of different policies never mix.
description string
default yes one of "match", "ignore" Role of every reported fact not named in paths.
paths map of role (keys pointer) Roles by JSON Pointer.

No other properties are allowed.

Definitions

Reusable subschemas referenced from the tables above and from other schemas.

token

Type: string (pattern ^\S+$; min length 1)

pointer

Type: string (pattern ^/(project|source|benchmark|coordinates)(/[^/]+)*$)

role

Type: exactly one of: one of "match", "ignore"; object

Examples

{
  "identity_schema": "arrow/identity/v4",
  "description": "Arrow's identity policy: the default, with benchmark revisions mapped to a declared suite version.",
  "default": "match",
  "paths": {
    "/source/uri": {
      "normalize": {
        "rule": "canonical-uri"
      }
    },
    "/coordinates/environment/system/hostname": "ignore",
    "/coordinates/environment/system/os": "ignore",
    "/coordinates/environment/system/libc": "ignore",
    "/coordinates/environment/system/cpu": "ignore",
    "/coordinates/environment/system/gpu": "ignore",
    "/coordinates/environment/system/firmware": "ignore",
    "/coordinates/environment/system/container": "ignore",
    "/coordinates/environment/system/process/cgroup": "ignore",
    "/benchmark/revision/key": {
      "normalize": {
        "rule": "map",
        "map": {
          "92ef3aa0c1d5e8b7f4a2936d5c1e7b8a9f0d3c2e": "suite-v3"
        }
      }
    }
  }
}
{
  "identity_schema": "benchx/default/v1",
  "description": "The default identity policy: every coordinate matches except a named list of system fields the former design never matched; anything else, including a fact an adapter adds later, matches.",
  "default": "match",
  "paths": {
    "/source/uri": {
      "normalize": {
        "rule": "canonical-uri"
      }
    },
    "/coordinates/environment/system/hostname": "ignore",
    "/coordinates/environment/system/os": "ignore",
    "/coordinates/environment/system/libc": "ignore",
    "/coordinates/environment/system/cpu": "ignore",
    "/coordinates/environment/system/gpu": "ignore",
    "/coordinates/environment/system/firmware": "ignore",
    "/coordinates/environment/system/container": "ignore",
    "/coordinates/environment/system/process/cgroup": "ignore"
  }
}