Knowledge Base Administration Guide

Bug Refresh (Update) and Auto-Resolve flow

Simscope comes with a Python-based JIRA bug update and ADO bug plugins, which can pull updates from the bug back into Simscope.

  • For example, if the bug title, assignee, or state changes.

Note: if you have an internal (in-house) bug tracker, you can build your own bug update flow by following the Custom Bug Plugin.


Enabling Bug Refresh

To enable refreshing, your simscope.config plugin must be configured with a refreshplugin = "REFRESH-SCRIPT" enabled.

You should also enable automatic refresh, where Simscope will refresh all bugs on a configurable schedule (e.g. every 30 minutes).

[bugs]

# Automatically refresh all bugs on a fixed time interval schedule.
# NOTE: this works by calling the 'refreshplugin' script.
autorefresh = "30m"

# Auto-resolve rules.  This enables automatic resolving of rules when a bug
# has been set to a fixed/resolved/closed state.
## autoresolverules = true

# Search Changelist DB must be enabled for auto-resolve
[commitid]
searchchangelistdb = true

Rule Automatic Resolve

Simscope has an optional Rule auto-resolve flow, where bug resolution will trigger Rules to be automatically resolved.

  • To trigger, POST a JSON bug update, with the resolved JSON field set to a valid timestamp.
    • Or if autorefresh is enabled, Simscope will automatically refresh the external bug tracker, and if updates are found, will trigger the automatic resolve flow.
  • This uses the branch field from the bug.
  • This automatically uses the latest commit published to Simscope (ie HEAD) to resolve the rules against.

When this occurs, the users linked to each rule being resolved will get a notification email that their rule was resolved by a bug.

State Transition

This flow only triggers on the bug state transition from an active state to a resolved state (or closed).

  • If a bug is updated after resolve, Simscope ignores this update, as it is not a transition.
  • You can re-open and re-resolve a bug, and Simscope will auto-resolve rules at this point.

Example Auto-resolve email

This email shows an example, where bug TEST-AUTORESOLVE was resolved in JIRA. Simscope used:

  • The bug branch dev2
  • The latest commit in Simscope, with integrate=true (SHA abcd29)

This resolved the rule, along with 2 jobs, and sent this email:

Auto Resolve


Enabling Auto-resolve in Simscope

To enable auto-resolve in Simscope, add the following to your simscope.config file:

[bugs]

# Automatically refresh all bugs on a fixed time interval schedule.
# NOTE: this works by calling the 'refreshplugin' script.
autorefresh = "30m"

# Auto-resolve rules.  This enables automatic resolving of rules when a bug
# has been set to a fixed/resolved/closed state.
autoresolverules = true

# Search Changelist DB must be enabled for auto-resolve
[commitid]
searchchangelistdb = true