Open Bug 1913791 Opened 1 year ago Updated 1 year ago

unify page view timers

Categories

(Tecken :: General, task, P3)

Tracking

(Not tracked)

People

(Reporter: willkg, Unassigned)

Details

Currently, we've got three different page view timers:

  • tecken.api for the api views that the frontend uses
  • tecken.download_symbol for the download API
  • tecken.upload_archive for the upload API

We should change this to use a unified page view key with path and method tags.

We need to make sure we time exceptions and errors, so we can't just use Markus' timer_decorator since that won't emit a timing metric if an exception is thrown.

For the download API, we want to use the Django url match--not the actual path requested. Otherwise, the cardinality will be insane.

Something like this would work except that it needs to handle errors which I think this doesn't do:

https://github.com/mozilla-services/socorro/blob/a51c686736d5112072fcfd65ebcd13ecc6d582f1/webapp/crashstats/crashstats/decorators.py#L133-L189

Also, we do want the request method as a tag and probably don't need the api and ajax tags.

You need to log in before you can comment on or make changes to this bug.