Page MenuHomePhabricator

[nix] Set db variables in our local environments
ClosedPublic

Authored by inka on Apr 4 2023, 4:00 AM.
Tags
None
Referenced Files
F1871174: D7296.id24593.diff
Mon, May 27, 12:26 AM
Unknown Object (File)
Sun, May 26, 1:11 AM
Unknown Object (File)
Fri, May 24, 11:02 AM
Unknown Object (File)
Sun, May 19, 5:45 PM
Unknown Object (File)
Sun, May 19, 5:45 PM
Unknown Object (File)
Sun, May 19, 4:57 AM
Unknown Object (File)
Sun, May 19, 3:28 AM
Unknown Object (File)
Sun, May 12, 4:56 AM
Subscribers

Details

Reviewers
jon
ashoat
Group Reviewers
Restricted Owners Package(Owns No Changed Paths)
Commits
rCOMMeaf79b7b72a8: [nix] Set db variables in our local environments
Summary

issue: https://linear.app/comm/issue/ENG-3349/test-setting-innodb-ft-min-token-size
In D7266 we set innodb-ft-min-token-size and innodb-ft-enable-stopword variables in the db run in Docker. We also need a way for these variable to be set in our local environments. This diff addresses the Nix
MariaDB instances. The legacy instances will have to be updated manually, and a proper instruction will be provided in the linear task, as well as on the Comm Dev Team channel.
I would be grateful if someone could check if the messages printed by db_usage and usage functions are reasonable.

Test Plan

Running a nix db instance, I ran comm-dev db restart and checked that the variables were set to 1 and 0, respectively.

Diff Detail

Repository
rCOMM Comm
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

Owners added a reviewer: Restricted Owners Package.Apr 4 2023, 4:00 AM
inka requested review of this revision.Apr 4 2023, 4:16 AM
ashoat removed a reviewer: Restricted Owners Package. ashoat added 1 blocking reviewer(s): jon.
ashoat added inline comments.
nix/mariadb-up-mac.nix
28 ↗(On Diff #24593)

Wondering if the rest of the parameters in keyserver/docker-compose.yml should be here too:

--max-allowed-packet=256M
--local-infile=0
--sql-mode=STRICT_ALL_TABLES
--innodb-buffer-pool-size=1600M

looks good to me from a bash perspective

This revision is now accepted and ready to land.Apr 4 2023, 7:26 AM
nix/mariadb-up-mac.nix
28 ↗(On Diff #24593)

I don't really know, probably yes, but I think @jon has better context.
I don't think this influences my task very much, so I created an issue to discuss this:
https://linear.app/comm/issue/ENG-3587/use-the-same-flags-when-running-mariadb-in-docker-and-in-nix

And I will land this diff, since it has been accepted

Owners added a reviewer: Restricted Owners Package.Apr 5 2023, 2:55 AM