Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
1ef6bb6c
Commit
1ef6bb6c
authored
Aug 25, 2021
by
Bob Van Landuyt
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add job limit columns to application settings
This adds the schema changes for the sidekiq job limiter
parent
81992919
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
25 additions
and
0 deletions
+25
-0
db/migrate/20210908140437_add_sidekiq_limits_to_application_settings.rb
...10908140437_add_sidekiq_limits_to_application_settings.rb
+21
-0
db/schema_migrations/20210908140437
db/schema_migrations/20210908140437
+1
-0
db/structure.sql
db/structure.sql
+3
-0
No files found.
db/migrate/20210908140437_add_sidekiq_limits_to_application_settings.rb
0 → 100644
View file @
1ef6bb6c
# frozen_string_literal: true
class
AddSidekiqLimitsToApplicationSettings
<
Gitlab
::
Database
::
Migration
[
1.0
]
disable_ddl_transaction!
# needed for now to avoid subtransactions
def
up
with_lock_retries
do
add_column
:application_settings
,
:sidekiq_job_limiter_mode
,
:smallint
,
default:
1
,
null:
false
add_column
:application_settings
,
:sidekiq_job_limiter_compression_threshold_bytes
,
:integer
,
default:
100_000
,
null:
false
add_column
:application_settings
,
:sidekiq_job_limiter_limit_bytes
,
:integer
,
default:
0
,
null:
false
end
end
def
down
with_lock_retries
do
remove_column
:application_settings
,
:sidekiq_job_limiter_mode
remove_column
:application_settings
,
:sidekiq_job_limiter_compression_threshold_bytes
remove_column
:application_settings
,
:sidekiq_job_limiter_limit_bytes
end
end
end
db/schema_migrations/20210908140437
0 → 100644
View file @
1ef6bb6c
a8dc6d1fecf7b26182dd89f4dae088fb315774ff4720c282f608bd0c45c75a41
\ No newline at end of file
db/structure.sql
View file @
1ef6bb6c
...
...
@@ -10340,6 +10340,9 @@ CREATE TABLE application_settings (
throttle_unauthenticated_api_enabled boolean DEFAULT false NOT NULL,
throttle_unauthenticated_api_requests_per_period integer DEFAULT 3600 NOT NULL,
throttle_unauthenticated_api_period_in_seconds integer DEFAULT 3600 NOT NULL,
sidekiq_job_limiter_mode smallint DEFAULT 1 NOT NULL,
sidekiq_job_limiter_compression_threshold_bytes integer DEFAULT 100000 NOT NULL,
sidekiq_job_limiter_limit_bytes integer DEFAULT 0 NOT NULL,
CONSTRAINT app_settings_container_reg_cleanup_tags_max_list_size_positive CHECK ((container_registry_cleanup_tags_service_max_list_size >= 0)),
CONSTRAINT app_settings_ext_pipeline_validation_service_url_text_limit CHECK ((char_length(external_pipeline_validation_service_url) <= 255)),
CONSTRAINT app_settings_registry_exp_policies_worker_capacity_positive CHECK ((container_registry_expiration_policies_worker_capacity >= 0)),
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment