Grid5000 and BonFIRE Events/Artifacts API Documentation
Any bug whose Keywords
list contains Event
will appear on the events page, in one of the following categories: Planned
, In Progress
, or Done
.
Any issue that is in a project accessible to the user querying BonFIRE's redmine (Event Robot (eventbot)) will be considered in the current version.
According to its status, a bug will appear in only one category:
Bug Status (bugzilla) | Issue Status (Redmine) | Event Category |
---|---|---|
NEW, UNCONFIRMED | New | Planned |
REOPENED, ASSIGNED | In Progress | In progress |
RESOLVED, CLOSED | Resolved, Closed | Done |
If there are no dates in the bug title, the Beginning
and Ending
dates of an event are respectively set to:
Done
events, the date of last update of the bug/issue, or ?
for other events. This implies that if a tracker is kept active after an bug/issue was solved for users, the date should be set in the title (see next paragraph). Otherwise, the end date of the event will change and this could affect statistics.Sometimes you want to hardcode the dates you want to display. Thus you can overwrite both dates by setting them explicitly in the bug title.
Dates must have the following format: YYYY[/-]mm[/-]dd(@HH:MM)?
(time is optional). Timezone is supposed to be the same as for the bugzilla server (CET).
Beginning
date of the event (the Ending
date is set to ?
in the case of In Progress
and Planned
events, and set to the last update date in the case of Done
events).Beginning
date, the second being the Ending
date.Tags are associated to events, so that users can easily filter them. By default, there is only one tag wich corresponds to the Component
attribute of the bug. But any word in the title, prefixed by the #
symbol, is added to the list of tags (only unique tags are displayed to the user).
Currently, the list of events is updated every minute.
Philippe suggested the follwing heuristic to keep bugs ASSIGNED without having them be considered as In Progress:
Any bug whose Keywords
list contains Artifact
will appear on the artifacts page, in one of the following categories: Current artifact
or Resolved artifact
.
According to its status, a bug will appear in only one category:
Bug Status | Artifact Category |
---|---|
NEW, UNCONFIRMED, REOPENED, ASSIGNED | Current artifact |
RESOLVED, CLOSED | Resolved artifact |
Tags are associated to artifacts, so that users can easily filter them. By default, there is only one tag wich corresponds to the Component
attribute of the bug. But any word in the title, prefixed by the #
symbol, is added to the list of tags (only unique tags are displayed to the user).
Currently, the list of artifactss is updated every 30 minutes.
This tag, set on bugs by administrators, is used to help users to filter unavailable sites with the events API.
Here an example :
#!/usr/bin/env ruby -KU require 'rubygems' require 'restclient' require 'json' data = RestClient.get 'https://api.grid5000.fr/3.0/status/upcoming.json', :content_type => :json, :accept => :json events = JSON.parse data broken_events = events.select { |event| event['tags'].include? 'broken' and event['status'] == 'ASSIGNED' } broken_events.each do |event| puts "--> Event #{event['id']}" p event end broken_components = broken_events.map { |event| event['component'][1..-1].downcase } puts "Broken sites : #{broken_components.join(', ')}"