Permalink
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
48 lines (38 sloc) 2.09 KB

Report 011 - September 16, 2016

Loading metrics dynamically

  • The set of metrics to present in the UI is now specified in a JSON file that currently sits in WMArchive/src/maps/metrics.json. The environment variable WMARCHIVE_PERF_METRICS must be set to point to this file, since no metrics are hard-coded anymore. The JSON file contains a nested list of metrics along with their properties:

    [
      {
        "key": "jobstate",
        "title": "Job State",
        "description": "Number of jobs and their success rate.",
        "unit": ""
      },
      {
        "key": "cpu",
        "title": "CPU",
        "metrics": [
          {
            "key": "TotalJobTime",
            "title": "Total Job Time",
            "description": "Job wall time.",
            "unit": "s"
          },
          // ...
        ]
      },
      // ...
    ]
  • This file is read by the server and passed to the UI, that in turn presents these metrics to the user.

  • The UI uses the unit specified for each metric to decide on a formatting style for its values. All formatting is done in WMArchive/src/js/utils/format.js.

Reading MongoDB database from environment

  • The MongoDB database and collection to use are now read from the environment variables WMARCHIVE_PERF_DB and WMARCHIVE_PERF_COLL and default to aggregated.performance.

Project-wide documentation

  • I wrote extensive documentation across the entire project to aid in the maintenance of the service.
  • The README.md file gives an overview of the project and serves as an entry point to the documentation as well as an index to the weekly reports. It also lists common tasks, pending improvements and known issues.
  • I wrote detailed documentation on various topics in the docs directory.
  • Finally I added a plethora of code-level comments and explanations as well as links to the documentation.

Preparations for the presentation

  • I prepared a number of slides for the final presentation of the project to present the service to the CMS community.