---
- job:
    name: record-taxonomy-metrics
    display-name: Record metrics about the Topic Taxonomy
    project-type: freestyle
    description: |
      This job runs a rake task in Content Tagger to send metrics
      about the Topic Taxonomy to statsd.
    logrotate:
      daysToKeep: 30
    triggers:
      - timed: 'H/30 * * * *'
    builders:
      - shell: |
          #!/bin/bash
          set -eu
          
          cd "${WORKSPACE}"
          
          CONTENT_TAGGER=$(govuk_node_list --single-node -c backend)
          
          ssh deploy@$CONTENT_TAGGER "cd /var/apps/content-tagger && govuk_setenv content-tagger bundle exec rake metrics:taxonomy:count_content_per_level metrics:taxonomy:record_content_coverage_metrics"

---
- job:
    name: record-taxonomy-metrics
    display-name: Record metrics about the Topic Taxonomy
    project-type: freestyle
    description: |
      This job runs a rake task in Content Tagger to send metrics
      about the Topic Taxonomy to statsd.
    logrotate:
      daysToKeep: 30
    triggers:
      - timed: 'H/30 * * * *'
    builders:
      - shell: |
          #!/bin/bash
          set -eu
          
          cd "${WORKSPACE}"
          
          CONTENT_TAGGER=$(govuk_node_list --single-node -c backend)
          
          ssh deploy@$CONTENT_TAGGER "cd /var/apps/content-tagger && govuk_setenv content-tagger bundle exec rake metrics:taxonomy:record_all"

Update record taxonomy metrics Jenkins job
Update record taxonomy metrics Jenkins job

Running the tasks to record taxonomy metrics is consolidated in
a single 'record_all' Rake task. This change changes the Jenkins
job to run this single task instead of the individual recording
tasks.

See also: https://github.com/alphagov/content-tagger/pull/611
