Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Docker2 #2756

Draft
wants to merge 7 commits into
base: main
Choose a base branch
from
Draft

Docker2 #2756

wants to merge 7 commits into from

Conversation

justinlittman
Copy link
Contributor

Why was this change made? 🤔

Docker cures all ills.

How was this change tested? 🤨

⚡ ⚠ If this change involves consuming from or writing to another service (or shared file system), run integration test create_object_h2_spec.rb and/or test manually in [stage|qa] environment, in addition to specs. ⚡

Copy link
Contributor Author

@justinlittman justinlittman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@@ -6,7 +6,7 @@ class AssignPidJob
# This worker will connect to "h2.druid_assigned" queue
# env is set to nil since by default the actual queue name would be
# "h2.druid_assigned_development"
from_queue 'h2.druid_assigned', env: nil
from_queue Settings.rabbitmq.queues.druid_assigned, env: nil
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

All of these queue changes are so that we can run multiple instances of H2 in a single environment and each has its own queue. This will allow us to run a dockerized H2 and a plain-old H2 together.

@@ -6,8 +6,8 @@
# the maximum value specified for Puma. Default is set to 5 threads for minimum
# and maximum; this matches the default thread size of Active Record.
#
max_threads_count = ENV.fetch('RAILS_MAX_THREADS', 5)
min_threads_count = ENV.fetch('RAILS_MIN_THREADS') { max_threads_count }
max_threads_count = ENV.fetch('PUMA_MAX_THREADS', 5)
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changing these variables so that their naming is clearer elsewhere (e.g., in puppet files).

@@ -9,4 +9,4 @@
# Character.create(name: 'Luke', movie: movies.first)

# The SDR user is used in Events performed by SDR.
User.create!(name: 'SDR', email: 'sdr@stanford.edu')
User.find_or_create_by!(name: 'SDR', email: 'sdr@stanford.edu')
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This allows seeding as part of deploy. Currently, it was performed as a manual operation.

- HOST
- HONEYBADGER_API_KEY
- SETTINGS__RABBITMQ__PASSWORD
- SETTINGS__RABBITMQ__QUEUES__DEPOSIT_COMPLETE
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we need these *_QUEUES_* variables in here? Aren't they basically constants in settings.yml?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No, they vary by server so that we can run multiple instances of H2 (e.g., dockerized and non-dockerized) and each has its own queue. This is set in puppet.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants