Donal McBreen
97bcdf1853
Enforce column limits via concern
...
SQLite columns lengths are purely informational, so we'll enforce the
limits via a concern that checks the lengths from the schema.
2025-11-25 15:32:34 +00:00
Donal McBreen
67f648f356
Enforce MySQL string/text limits in SQLite
...
To ensure consistent column lengths, we'll add limits to string and text
columns which match MySQL defaults.
2025-11-25 14:50:40 +00:00
Donal McBreen
e07419e953
Update config/database.yml
...
Co-authored-by: Mike Dalessio <mike.dalessio@gmail.com >
2025-11-25 11:38:21 +00:00
Donal McBreen
b96ea6e9d0
Update config/database.yml
...
Co-authored-by: Mike Dalessio <mike.dalessio@gmail.com >
2025-11-25 11:38:13 +00:00
Donal McBreen
4c4f6957ec
Drop sqlite compability, using a separate schema.rb
2025-11-21 17:25:40 +00:00
Donal McBreen
b1862733dd
Merge branch 'main' into sqlite
2025-11-21 15:23:34 +00:00
Jason Zimdars
2382326a13
Merge pull request #1638 from basecamp/expand-activity-columns
...
Expand activity columns
2025-11-21 09:11:22 -06:00
Donal McBreen
f384a0d9b8
Fix database.yml merge error
2025-11-21 14:30:17 +00:00
Donal McBreen
32c3bcec9f
Merge branch 'main' into sqlite
2025-11-21 14:26:21 +00:00
Jorge Manrubia
c1f5699443
Switch READ-COMMITED so that queries see the last committed data
...
This should help solving the problem with overlapping bundles
It is what we use in HEY and Basecamp
2025-11-21 14:35:29 +01:00
Jorge Manrubia
6e20c8c68f
Add brakeman rule
2025-11-21 10:42:08 +01:00
Jorge Manrubia
e4558f00ab
Merge branch 'main' into expand-activity-columns
2025-11-21 10:25:39 +01:00
Donal McBreen
f24f959d19
Add brakeman ignores
2025-11-21 09:15:19 +00:00
Donal McBreen
dd18b6641d
Simplify patching
2025-11-21 09:15:19 +00:00
Donal McBreen
33ef482189
Patch dumper on load
2025-11-21 09:15:19 +00:00
Donal McBreen
9c8d5e40ad
Always apply patches on load
2025-11-21 09:15:19 +00:00
Donal McBreen
f665b5a1fa
No need for default schema
2025-11-21 09:15:19 +00:00
Donal McBreen
cc7e091508
Disable multi-db for SQLite
2025-11-21 09:15:19 +00:00
Donal McBreen
bb36b4846f
Support SQLite searching
2025-11-21 09:15:19 +00:00
Donal McBreen
a2333d9a37
Add SQLite support
...
- UUID support
- Schema compatibility layer, ignore MySQL specific options
- Search not working yet
2025-11-21 09:15:19 +00:00
David Heinemeier Hansson
ae640198ae
Stick with the same general retention policy we use for everything
2025-11-21 09:40:50 +01:00
David Heinemeier Hansson
0a88565bd7
Slim down
2025-11-21 09:39:59 +01:00
David Heinemeier Hansson
f66da318aa
No longer needed now that we are back to a single DB
2025-11-21 09:39:33 +01:00
David Heinemeier Hansson
62d4998f27
We stopped using load_async in the code base
2025-11-21 09:35:25 +01:00
Mike Dalessio
2c2a1c4b4a
Make sure jobs are enqueued only after all transactions are committed
...
This should fix the recurring ActiveStorage::FileNotFoundError errors
from ActiveStorage::AnalyzeJob.
The issue is that, when images are not direct uploaded (e.g. a card
background image or avatar image), the AnalyzeJob has been getting
enqueued before the file itself was uploaded to blob storage.
Setting ActiveJob::Base.enqueue_after_transaction_commit = true makes
sure that jobs are always enqueued only once *all* transactions have
been committed.
This will be the Rails default at some point, but for now we still
need to explicitly set it.
Big thanks to @jeremy for the assist. 👏
2025-11-20 18:47:42 -05:00
Mike Dalessio
362be963c0
Add a very rudimentary admin dashboard.
2025-11-19 14:23:47 -05:00
Jason Zimdars
eba749a193
Expand activity columns
2025-11-19 12:48:36 -06:00
Fernando Álvarez
672816dec5
Move production jobs to specific hosts
2025-11-19 19:12:02 +01:00
Fernando Álvarez
a6a4bb236b
Split jobs hosts for Staging
...
Related to https://3.basecamp.com/2914079/buckets/37331921/todos/9266308208
2025-11-19 18:31:29 +01:00
Mike Dalessio
711cc8568e
Fix account slugs in Active Storage URLs
2025-11-19 08:51:12 -05:00
Mike Dalessio
3b717bbe0d
Move AccountSlug::Extractor later in the stack
...
so that in development, it runs after reloading; but still before the
database selector middleware in case we ever want to do something
account-specific.
2025-11-18 09:20:47 -05:00
Kevin McConnell
9b3b2f5d29
Prevent pinning writes in non-primary DCs
2025-11-18 11:03:58 +00:00
Kevin McConnell
d584950457
Consolidate staging MySQL replica hostname
2025-11-18 08:29:42 +00:00
Mike Dalessio
695037c7ee
Make sure rack-mini-profiler doesn't load in test
2025-11-17 15:03:26 -05:00
Mike Dalessio
e3ce26c53d
rubocop: more style fixes
2025-11-17 14:54:42 -05:00
Kevin McConnell
a7ff18c437
Add regional cache DBs for production
2025-11-17 17:49:26 +00:00
Stanko K.R.
0b8c51c2e9
Preload cards for columns
2025-11-17 16:16:19 +01:00
Mike Dalessio
2a1817d902
Bringing back the TurboStreamsExtension
...
so that, for example, notification content contains the URLs properly
scoped to the account.
2025-11-17 09:12:41 -05:00
Mike Dalessio
142a342e53
Make sure ActiveJob preserves the current account context
...
This is a pretty common pattern, something like this is in both
ActiveRecord::Tenanted and ActsAsTenanted.
2025-11-17 09:12:41 -05:00
Mike Dalessio
62f469f609
brakeman: remove two obsolete ignore entries
2025-11-17 09:12:41 -05:00
Mike Dalessio
5ca2df22ce
Load recurring jobs in development
2025-11-17 09:12:41 -05:00
Kevin McConnell
ac9824122b
Use direct hostnames for MySQL replicas (for now)
...
We will move this back to a single endpoint once the F5 setup is ready.
2025-11-17 09:12:41 -05:00
Kevin McConnell
dcd8536e0c
Set regional Solid Cache instances
2025-11-17 09:12:41 -05:00
Kevin McConnell
436caa8f74
Revert "Logging tweaks"
...
Debug logging interferes with the structured logging, so let's take that
back out.
2025-11-17 09:12:41 -05:00
Kevin McConnell
47f481525b
Logging tweaks
...
- Enable debug logging
- Disable health check logs
- Set Solid Queue logger
2025-11-17 09:12:41 -05:00
Stanko K.R.
a1d44b02ea
Change the symbol to a string
2025-11-17 09:12:41 -05:00
Stanko K.R.
a9e052d8cb
Explicitly use a shard for caching
...
See: https://github.com/rails/solid_cache/pull/219
2025-11-17 09:12:41 -05:00
Mike Dalessio
e3d86bb21e
Clean up some spots where "current account" is ambiguous
...
Primarily this is in tests (which were caught by temporarily
introducing acts_as_tenant and enabling safety checks), but notably
action cable connections were not working properly, and that's now
fixed.
2025-11-17 09:12:41 -05:00
Stanko K.R.
488c74d99e
Always use the cache db for caching
2025-11-17 09:12:41 -05:00
Kevin McConnell
fd3ad90f47
Remove outdated job reference
2025-11-17 09:12:41 -05:00