Skip to content

Update sample code to work with multiple databases

Thong Kuah requested to merge tkuah-master-patch-24154 into master

What does this MR do and why?

Update sample code to work with multiple databases

We recommend ApplicationRecord instead of ActiveRecord::Base to remove ambiguity around cross-database transactions

https://docs.gitlab.com/ee/development/database/multiple_databases.html#removing-cross-database-transactions

Screenshots or screen recordings

Screenshots are required for UI changes, and strongly recommended for all other merge requests.

Before After

How to set up and validate locally

Numbered steps to set up and validate the change are strongly suggested.

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Edited by Thong Kuah

Merge request reports