Skip to content

authz: add debug endpoint for `PermsSyncer`

Administrator requested to merge jc/perms-syncer-debug-endpoint into master

Created by: unknwon

This PR adds PermsSyncer's snapshot to repo-updater's debug endpoint (i.e. /repo-updater-state).

Example output:

[
  {
    "Name": "repos",
    "UpdateQueue": null,
    "Schedule": [...],
    "SourceRepos": {}
  },
  {
    "Name": "permissions",
    "Size": 3,
    "Queue": [
      {
        "Meta": {
          "Priority": 0,
          "Type": 2,
          "ID": 2,
          "NextSyncAt": "0001-01-01T00:00:00Z"
        },
        "Acquired": false
      },
      {
        "Meta": {
          "Priority": 0,
          "Type": 2,
          "ID": 3,
          "NextSyncAt": "2020-03-12T15:51:23.101639Z"
        },
        "Acquired": false
      },
      {
        "Meta": {
          "Priority": 0,
          "Type": 1,
          "ID": 4,
          "NextSyncAt": "2020-03-12T15:51:23.101639Z"
        },
        "Acquired": false
      }
    ]
  }
]

Merge request reports

Loading