We added this instrumentation to try and figure out what was happening
in LS-3147, but this has been in place for 1.5 years and we haven't
received any related reports since.
This reverts commit 7624569b39.
Change-Id: I4c99333204f14c3a77b0350c246d2928cae861be
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/330695
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Robin Kuss <rkuss@instructure.com>
QA-Review: Robin Kuss <rkuss@instructure.com>
Product-Review: Jackson Howe <jackson.howe@instructure.com>
region helpers have been hoisted into switchman proper, so
remove them locally
Change-Id: I1eda64fd64eda61b7647b15ec2ba62db986d19bd
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/329655
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Jacob Burroughs <jburroughs@instructure.com>
QA-Review: Cody Cutrer <cody@instructure.com>
Product-Review: Cody Cutrer <cody@instructure.com>
Build-Review: Cody Cutrer <cody@instructure.com>
closes AE-494
[skip-stages=Flakey]
[skip-crystalball]
several things going on here. in general, many of our monkeypatches
have been implemented in upstream, but in a vastly different way, so
we need to enable/configure those things
* `servers` is no longer accepted as a backwards compatible
configuration option; use `url`
* `database` is no longer accepted as a backwards compatible
configuration option; you _can_ use `db`, but preferable to
just use `url`
* no longer merge together redis.yml and cache_store.yml; if one
references the other, simply use the config from the other
* `nil_store` is no longer accepted as a backwards compatible
configuration option; use `null_store` (almost no one should
be explicitly using this anyway, so nbd)
* automatically not-even-trying when redis has previously failed
is now handled by redis-client's circuit breaker. be sure to
configure it in redis.yml/cache_store.yml/dynamic settings
* ignoring redis failures completely is already done by
RedisCacheStore; just rely on that, except for the few cases
where we use redis directly. some of these now take advantage
of a new `failsafe` kwarg (and often in combination with
pipelining), and some just handle it directly
* move logging to a RedisClient middleware
* move Twemproxy disallowed commands to a RedisClient middleware
* simplify Canvas.lookup_cache_store to have far less special casing
(in particular, patching is done automatically now)
* add ability to use Redis::Cluster (configure with `nodes` instead
of `url`)
* still override Redis::Distributed's HashRing, so that we don't
change our ring layout with the new MD5 hashing for servers. but
we got to vastly simplify the new class, due to upstream
refactorings allowing us to simply override a single method rather
than having to re-implement the entire class
* statsd reporting of redis errors is now simply passed as a callback
to RedisCacheStore, breaking CanvasCache's dependency on InstStatsd
Change-Id: I787672677a21994d40ae304dbac0fbf3a960a779
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/325641
Reviewed-by: Jacob Burroughs <jburroughs@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
QA-Review: Cody Cutrer <cody@instructure.com>
Product-Review: Cody Cutrer <cody@instructure.com>
Build-Review: Cody Cutrer <cody@instructure.com>
It's the new default debugger in ruby 3.1. Rails switched to it in 7.0,
avoids issues with Zeitwerk, has a more modern interface based on
current IRB, supports Unix Domain Sockets for remote debugging,
promises even better future maintenance due to being part of Ruby,
etc.
Change-Id: Ieaa7872f1c0308b16ae180fdb16df5dd6caa87a8
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/328241
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Isaac Moore <isaac.moore@instructure.com>
Build-Review: Isaac Moore <isaac.moore@instructure.com>
QA-Review: Cody Cutrer <cody@instructure.com>
Product-Review: Cody Cutrer <cody@instructure.com>
This does add an additional query every time we insert a versioned record, but it
is a very lightweight query that shouldn't hit the disk and record insertions are
orders of magnitude more expensive, so it should have an insignficant performance
impact.
fixes AE-445
Change-Id: I9ae43121a221442fc1db9f1c1486778b58803917
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326670
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Cody Cutrer <cody@instructure.com>
QA-Review: Jacob Burroughs <jburroughs@instructure.com>
Product-Review: Jacob Burroughs <jburroughs@instructure.com>
we only used it for one thing, and honestly with all of the dynamic
method dispatch it's not clear what it's even doing, so just do the
math ourselves
Change-Id: I17b601732d7b6e5e2236eb01e9ef368fc9d1fa89
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326665
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Jacob Burroughs <jburroughs@instructure.com>
QA-Review: Cody Cutrer <cody@instructure.com>
Product-Review: Cody Cutrer <cody@instructure.com>
Build-Review: Cody Cutrer <cody@instructure.com>
the version we use now properly calls super in inherited
Change-Id: I1da36c07877712c8362d7cb31090a271b0f37c51
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326475
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Jacob Burroughs <jburroughs@instructure.com>
QA-Review: Cody Cutrer <cody@instructure.com>
Product-Review: Cody Cutrer <cody@instructure.com>
fixes CANVAS-KWHP
the only job we have that uses it has a permanent_failure_callback anyway
Change-Id: Ie8034969943d958ed6ef59ee815bc5153283820a
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/324601
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Isaac Moore <isaac.moore@instructure.com>
QA-Review: Cody Cutrer <cody@instructure.com>
Product-Review: Cody Cutrer <cody@instructure.com>
why: we want to reduce Sentry "noise" and not sending 400s
errors from `lti_api_controller#check_outcome` will help
closes INTEROP-8159
test plan:
deploy to beta and make sure it's working as expected
Change-Id: I8c672dd5e40c7d13f085343c650b6007bec380c3
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/323986
Reviewed-by: Tucker Mcknight <tmcknight@instructure.com>
QA-Review: Tucker Mcknight <tmcknight@instructure.com>
Product-Review: Steve Mcgee <steve.mcgee@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
makes it much easier to do a failsafe local cache on it
refs AE-380
Change-Id: Ia4bda742e3ee3f80749f3f074e2411b68476b49c
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/322309
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Isaac Moore <isaac.moore@instructure.com>
Reviewed-by: Jacob Burroughs <jburroughs@instructure.com>
QA-Review: Cody Cutrer <cody@instructure.com>
Product-Review: Cody Cutrer <cody@instructure.com>
Build-Review: Cody Cutrer <cody@instructure.com>
either used at boot, or on every request (recaptcha)
refs AE-380
Change-Id: I3e75b6063591c4704a01fda807273ca36a93cb44
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/322308
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Isaac Moore <isaac.moore@instructure.com>
Reviewed-by: Jacob Burroughs <jburroughs@instructure.com>
QA-Review: Cody Cutrer <cody@instructure.com>
Product-Review: Cody Cutrer <cody@instructure.com>
refs AE-380
a lot of these are APM style settings that would be okay to just turn
off while Consul is down. others are things that should just silently
not have any data, instead of failing the request
Change-Id: I34c553b089197f85b2d46029e5079851227090b6
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/322239
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Isaac Moore <isaac.moore@instructure.com>
Reviewed-by: Jacob Burroughs <jburroughs@instructure.com>
QA-Review: Cody Cutrer <cody@instructure.com>
Product-Review: Cody Cutrer <cody@instructure.com>
This job will run once daily to make two test connections against each
LDAP authentication provider, and log a warning to Sentry if their TLS
certificate is not valid.
flag=none
closes AE-349
test plan:
- create an LDAP auth provider with a bad TLS cert
- run AuthenticationProvider::LDAP.ensure_tls_cert_validity
- ensure you get a warning in Sentry
- create an LDAP auth provider with a valid TLS cert
- run AuthenticationProvider::LDAP.ensure_tls_cert_validity
- ensure you get no warning in Sentry
Change-Id: Idd1157068f34a610f3f0e2fb1de89557cb585575
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/321403
Reviewed-by: Cody Cutrer <cody@instructure.com>
QA-Review: Isaac Moore <isaac.moore@instructure.com>
Product-Review: Isaac Moore <isaac.moore@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
add new columns 'points_based' (boolean) and 'scaling_factor'
(decimal) to grading_standards table. Add support for
GET, PUT, CREATE of these new attribures to the json
based grading_schemes rails controller.
flag = points_based_grading_schemes
Test Plan
- tests pass
closes EVAL-3256
closes EVAL-3257
closes EVAL-3258
Change-Id: I0851d5d3b11b4e29098d810bbd96397c61f872ce
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/320659
Migration-Review: Cody Cutrer <cody@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Kai Bjorkman <kbjorkman@instructure.com>
QA-Review: Kai Bjorkman <kbjorkman@instructure.com>
Product-Review: Cameron Ray <cameron.ray@instructure.com>
manually done. the big one was the explicit locale assignment
in set_locale_with_localizer needs undone in a controller callback
then using with_locale everywhere, specs no longer need to be concerned
about being in an uncertain locale
Change-Id: I5a1d2c907a6f52ee4d8c2307b8c789a1f1ea436e
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/320112
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Jacob Burroughs <jburroughs@instructure.com>
QA-Review: Cody Cutrer <cody@instructure.com>
Product-Review: Cody Cutrer <cody@instructure.com>
I'm not sure why rubocop didn't find these; I found them manually
Change-Id: Id2654b6d2a4a2827d56dfd0baef7a7d668591144
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/320149
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Isaac Moore <isaac.moore@instructure.com>
QA-Review: Cody Cutrer <cody@instructure.com>
Product-Review: Cody Cutrer <cody@instructure.com>
[skip-stages=Flakey]
Change-Id: I6abefdfa9fed6dd4525c8786e93efa548b3710f2
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/319603
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Isaac Moore <isaac.moore@instructure.com>
QA-Review: Jacob Burroughs <jburroughs@instructure.com>
Product-Review: Jacob Burroughs <jburroughs@instructure.com>
Build-Review: Jacob Burroughs <jburroughs@instructure.com>
Migration-Review: Jacob Burroughs <jburroughs@instructure.com>
Change-Id: Ib787e8cf4fdb6b3a79ddb82c5566db0467018854
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/318199
Reviewed-by: Aaron Ogata <aogata@instructure.com>
Reviewed-by: Isaac Moore <isaac.moore@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
QA-Review: Jacob Burroughs <jburroughs@instructure.com>
Product-Review: Jacob Burroughs <jburroughs@instructure.com>
Change-Id: I42e8dbe319551a7ccb19ad20dde60fd38046dc49
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/318170
Reviewed-by: Aaron Ogata <aogata@instructure.com>
Reviewed-by: Isaac Moore <isaac.moore@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
QA-Review: Jacob Burroughs <jburroughs@instructure.com>
Product-Review: Jacob Burroughs <jburroughs@instructure.com>
so that switchman can tranpose the sub-queries
refs AE-164
Change-Id: I0bb0be10cd7c47126767d94e0bdb83cd0b3d16bf
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/316973
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Jacob Burroughs <jburroughs@instructure.com>
QA-Review: Cody Cutrer <cody@instructure.com>
Product-Review: Cody Cutrer <cody@instructure.com>
Change-Id: I8a4b84177cfcb89ad148c18a7a06149a7117d285
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/316758
Reviewed-by: Aaron Ogata <aogata@instructure.com>
QA-Review: Isaac Moore <isaac.moore@instructure.com>
Product-Review: Isaac Moore <isaac.moore@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
closes AE-239
flag=none
test plan:
- migrations run successfully on Jenkins
- tests pass
Change-Id: Ic89e000b89bb35f2ae20ea98b950b45e4fbe3089
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/316549
Reviewed-by: Cody Cutrer <cody@instructure.com>
Migration-Review: Cody Cutrer <cody@instructure.com>
QA-Review: Isaac Moore <isaac.moore@instructure.com>
Product-Review: Isaac Moore <isaac.moore@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
closes AE-81
test plan:
* the people page for an account or course should load properly,
and still sort properly (enforced by specs)
Change-Id: Id8f252af44b2fa4a31786c5c4b7fef9d2aad0946
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/314759
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Jacob Burroughs <jburroughs@instructure.com>
Migration-Review: Jacob Burroughs <jburroughs@instructure.com>
QA-Review: Cody Cutrer <cody@instructure.com>
Product-Review: Cody Cutrer <cody@instructure.com>
fixes CANVAS-K0Y4
Change-Id: I8d715b404a5eecc375f909110c2abbfbf9ed572d
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/315642
Reviewed-by: Jacob Burroughs <jburroughs@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
QA-Review: Jeremy Stanley <jeremy@instructure.com>
Product-Review: Jeremy Stanley <jeremy@instructure.com>