If you think a bug might affect users in the 57 release, please set the correct tracking and status flags for Release Management.

taskcluster-base: Implement the "/ping" end-point in API utilities (minor refactor)

RESOLVED FIXED

Status

Taskcluster
Platform and Services
RESOLVED FIXED
3 years ago
9 months ago

People

(Reporter: jonasfj, Unassigned)

Tracking

Details

(Reporter)

Description

3 years ago
All taskcluster components with APIs should implement a ping end-point.
Typically it looks like this:

/** Check that the server is a alive */
api.declare({
  method:   'get',
  route:    '/ping',
  name:     'ping',
  title:    "Ping Server",
  description: [
    "Documented later...",
    "",
    "**Warning** this api end-point is **not stable**."
  ].join('\n')
}, function(req, res) {
  res.json(200, {
    alive:    true,
    uptime:   process.uptime()
  });
});


We really should just move this code to taskcluster-base, and add it to all instances of API.
This would reduce code duplication and allow us to declare the end-point stable.
Component: TaskCluster → General
Product: Testing → Taskcluster
(Reporter)

Updated

2 years ago
Component: General → Platform Libraries
Component: Platform Libraries → Platform and Services
(Reporter)

Comment 1

9 months ago
Pretty sure owlish did this in https://github.com/taskcluster/taskcluster-lib-api
Status: NEW → RESOLVED
Last Resolved: 9 months ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.