Rename Sentry::Client to ErrorTracking::SentryClient
We're going to upgrade the Sentry gem in a future MR. The new version exports a Sentry class, rather than the current Raven class. This would clash with our existing Sentry namespace, used for the Sentry::Client class, which is part of our feature where user projects can integrate with Sentry.
To start to untangle this, we move Sentry::Client to ErrorTracking::SentryClient. This has a number of benefits:
- We're following our namespacing guidelines by putting this code under the ErrorTracking namespace, which is the relevant application domain.
- We don't end up with any Sentry namespace at all, so there is no ambiguity when we add the top-level Sentry definition with the gem upgrade.
- The indentation for most classes and modules in this commit doesn't change, leading to a cleaner diff :-)
There are also some classes related to the error tracking feature that are in the Gitlab::ErrorTracking namespace, rather than just ErrorTracking. Those are tracked in the below issue:
Part of gitlab-com/gl-infra/scalability#849.
Screenshots
Sentry error | Error issue |
---|---|
Edited by Peter Leitzen