canvas-lms/gems
Cody Cutrer 35ee9fc656 update activerecord-pg-extensions
* moves with_statement_timeout into the gem
 * improves locking profile of change_column_null ..., false

Change-Id: I6973c6ea322ff29e3f7b2044d1650a9d0cb5afcb
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/273154
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>
2021-09-10 19:55:20 +00:00
..
activesupport-suspend_callbacks don't even bother checking for suspensions if there are no callbacks 2021-07-30 17:46:27 +00:00
acts_as_list add an `ordered` scope to acts_as_list, and use it 2021-03-31 21:48:10 +00:00
adheres_to_policy add backend permission changes for manage courses granulars 2021-04-30 21:29:00 +00:00
attachment_fu add frozen_string_literal comment to engines and gems 2021-03-30 18:14:15 +00:00
autoextend add frozen_string_literal comment to engines and gems 2021-03-30 18:14:15 +00:00
bookmarked_collection fix issues using timestamp as a pagination bookmark 2021-04-28 20:47:28 +00:00
broadcast_policy add frozen_string_literal comment to engines and gems 2021-03-30 18:14:15 +00:00
canvas_breach_mitigation add frozen_string_literal comment to engines and gems 2021-03-30 18:14:15 +00:00
canvas_cache add the ability to ignore redis command guards; refs DE-803 2021-08-31 16:35:09 +00:00
canvas_cassandra add frozen_string_literal comment to engines and gems 2021-03-30 18:14:15 +00:00
canvas_color add frozen_string_literal comment to engines and gems 2021-03-30 18:14:15 +00:00
canvas_crummy Modify index and show views for K5 mode 2021-04-21 18:21:41 +00:00
canvas_dynamodb add frozen_string_literal comment to engines and gems 2021-03-30 18:14:15 +00:00
canvas_errors add frozen_string_literal comment to engines and gems 2021-03-30 18:14:15 +00:00
canvas_ext add frozen_string_literal comment to engines and gems 2021-03-30 18:14:15 +00:00
canvas_http CanvasHttp: support for a max response body length 2021-04-19 17:40:03 +00:00
canvas_i18nliner Add typescript support 2021-08-18 18:21:17 +00:00
canvas_kaltura add frozen_string_literal comment to engines and gems 2021-03-30 18:14:15 +00:00
canvas_mimetype_fu add frozen_string_literal comment to engines and gems 2021-03-30 18:14:15 +00:00
canvas_panda_pub add frozen_string_literal comment to engines and gems 2021-03-30 18:14:15 +00:00
canvas_partman update activerecord-pg-extensions 2021-09-10 19:55:20 +00:00
canvas_quiz_statistics add frozen_string_literal comment to engines and gems 2021-03-30 18:14:15 +00:00
canvas_sanitize RCE able to save flexbox and grid related properties 2021-09-02 16:37:02 +00:00
canvas_security remove SafeYAML 2021-08-24 16:58:54 +00:00
canvas_slug add frozen_string_literal comment to engines and gems 2021-03-30 18:14:15 +00:00
canvas_sort add frozen_string_literal comment to engines and gems 2021-03-30 18:14:15 +00:00
canvas_stringex Properly support ruby 2.7 2021-06-11 21:06:37 +00:00
canvas_text_helper add frozen_string_literal comment to engines and gems 2021-03-30 18:14:15 +00:00
canvas_time add frozen_string_literal comment to engines and gems 2021-03-30 18:14:15 +00:00
canvas_unzip add frozen_string_literal comment to engines and gems 2021-03-30 18:14:15 +00:00
config_file remove SafeYAML 2021-08-24 16:58:54 +00:00
csv_diff add frozen_string_literal comment to engines and gems 2021-03-30 18:14:15 +00:00
diigo add frozen_string_literal comment to engines and gems 2021-03-30 18:14:15 +00:00
dr_diff defer gergich require until necessary 2021-08-26 20:33:21 +00:00
dynamic_settings Fix usage of Diplomat::Kv.txn() 2021-09-01 18:18:46 +00:00
event_stream add frozen_string_literal comment to engines and gems 2021-03-30 18:14:15 +00:00
google_drive spec: enable net connect after webmock 2021-07-22 13:55:29 +00:00
html_text_helper add frozen_string_literal comment to engines and gems 2021-03-30 18:14:15 +00:00
i18n_extraction add frozen_string_literal comment to engines and gems 2021-03-30 18:14:15 +00:00
i18n_tasks Don't let nulls get into locale javascript 2021-08-04 23:26:46 +00:00
incoming_mail_processor switch to OpenSSL::SSL::VERIFY_PEER for pop3 incoming mail processing 2021-09-09 14:10:32 +00:00
inst_access allow apollo federation introspection query w/o authentication 2021-08-11 16:49:55 +00:00
json_token add frozen_string_literal comment to engines and gems 2021-03-30 18:14:15 +00:00
linked_in add frozen_string_literal comment to engines and gems 2021-03-30 18:14:15 +00:00
live_events Fix specs in LiveEvents client 2021-08-24 19:08:44 +00:00
lti-advantage add migration claim to LTI 1.3 launches 2021-04-14 19:34:24 +00:00
lti_outbound Remove New Quizzes Embedded Module Progression 2021-08-23 17:27:35 +00:00
multipart add frozen_string_literal comment to engines and gems 2021-03-30 18:14:15 +00:00
paginated_collection add frozen_string_literal comment to engines and gems 2021-03-30 18:14:15 +00:00
plugins fix true expiration of access tokens that have refresh tokens 2021-07-13 20:41:06 +00:00
request_context allow request context id to be set w/o signature on some paths 2021-08-31 18:27:00 +00:00
rubocop-canvas update outrigger to 3.0 2021-09-10 19:55:07 +00:00
stringify_ids add frozen_string_literal comment to engines and gems 2021-03-30 18:14:15 +00:00
tatl_tael add frozen_string_literal comment to engines and gems 2021-03-30 18:14:15 +00:00
turnitin_api spec: enable net connect after webmock 2021-07-22 13:55:29 +00:00
twitter add frozen_string_literal comment to engines and gems 2021-03-30 18:14:15 +00:00
utf8_cleaner add frozen_string_literal comment to engines and gems 2021-03-30 18:14:15 +00:00
workflow add frozen_string_literal comment to engines and gems 2021-03-30 18:14:15 +00:00
README.md extract ConfigFile to gem 2021-02-23 21:18:20 +00:00
test_all_gems.sh remove broken vendored gems html reports 2021-06-15 16:53:17 +00:00

README.md

Gems

This folder is a place to extract modular functionality from canvas. Canvas's Gemfile arrangement is enabled to read gems from this path locally without installing from a remote source. This is valuable for a few reasons:

  • it prevents circular dependencies (bundler won't allow it)
  • modularized code cannot bind to specific domain concepts on canvas models
  • gems can have their specs run independently, without needing to load all of canvas, saving iteration time
  • it allows for eventual build optimization via only running specs for the transitive closure of parents depending on a gem where a change is.
  • it gives ENGINES extracted from canvas (see the "engines" directory) a place to reference code shared with canvas without it being packaged into the canvas monolith directly.

There are some tradeoffs:

  • spreads canvas over more subdirectories, giving some mental overhad to traversing the entire codebase.
  • modular tests necessarily don't test integration with canvas concepts, so solid integration tests in the app are still a requirement.
  • total SERIALIZED build time goes up because each gem loads it's specs in a new process rather than all running within an already booted canvas process.

[TODO] eventually write more on whether we feel like those tradeoffs are good ones, and what the best practices are to leverage this pattern for max-gain/min-pain.

Testing

To test all the gems:

cd gems
./test_all_gems.sh

To test an individual gem

Run ./test.sh inside the gem's folder. This is basically the same as:

cd gems/google_drive
bundle
rspec