goalert icon indicating copy to clipboard operation
goalert copied to clipboard

Introduce Detailed Breakdowns in Message Logs Graph

Open mastercactapus opened this issue 1 year ago • 2 comments

What problem would you like to solve? Please describe: Currently, the message logs graph only presents the number of messages with optional filter criteria. However, it lacks specificity, failing to provide adequate insights into traffic spikes and where they're coming from.

Describe the solution you'd like: I suggest introducing breakdowns in the message logs graph. Let's allow the data to be viewed per-type, per-user, and/or per-service. This way, users can have more detailed insight into any traffic spikes, identifying their sources more accurately.

Describe alternatives you've considered: An alternative solution could be to add additional filter criteria to the existing graph, but this might not provide as clear or versatile insights as the suggested breakdowns.

mastercactapus avatar Sep 11 '23 16:09 mastercactapus

There will need to be both API and UI work for this, the API only provides time series buckets for the total message count

I was toying with something like this:

enum MessageLogSegmentBy {
  service
  messageType
  user
  # Add other segments specific to message logs here
}

type MessageLogConnectionStats {
  timeSeries(input: TimeSeriesOptions!, segmentBy: MessageLogSegmentBy): [TimeSeriesBucket!]!
}

input TimeSeriesOptions {
  bucketDuration: ISODuration!
  bucketOrigin: ISOTimestamp
}

type TimeSeriesBucket {
  start: ISOTimestamp!
  end: ISOTimestamp!
  count: Int!
  segmentLabel: String  # Display-friendly label for the segment, e.g., "Service A"
}

mastercactapus avatar Sep 12 '23 17:09 mastercactapus

Summary from offline chat:

  • Replace current query with this updated query
  • Only 1 type can be selected at a time (service, messageType, or by user)
  • Graph will have n lines, with each line being a segment returned

e.g.

Lots of alerts happen at once. What services are affected?

  1. Select time range
  2. Select "Breakdown by service"
  3. See graph change from 1 line to n lines. Each line represents a service that has message logs for the given time range.
  4. If further dialing in is needed, the search can be used to filter (i.e. Logs going to Nathaniel.Cook broken down by services)

Forfold avatar Sep 12 '23 18:09 Forfold