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

fix!: set AWS_ENDPOINT_URL_DEADLINE after installing service model #96

Merged
merged 2 commits into from
Jun 3, 2024

Conversation

jericht
Copy link
Contributor

@jericht jericht commented Apr 17, 2024

What was the problem/requirement? (What/Why)

Main issue:

  • With the release of botocore that includes our service model, our method of configuring service model is no longer sufficient to contact endpoints other than the one included in botocore. We need to set AWS_ENDPOINT_URL_DEADLINE to tell boto that we want requests to Deadline Cloud to go to a different endpoint.

Small issues:

  • The test fixtures code that copies the service model from the test runner machine to the worker machine does not support gzip files, which is the format that service models included botocore are in.
  • The KEEP_WORKER_AFTER_FAILURE configuration was not working, workers are still shutting down after failing to start
  • The WORKER_REGION configuration is unnecessarily specific to the worker. The region can be applied to all components created by the test fixtures.

What was the solution? (How)

  • Set AWS_ENDPOINT_URL_DEADLINE whenever we install a service model
  • Support gzip (.json.gz) service model files
    • The ServiceModel class was responsible for too many things. Removed the file paths and the AWS CLI commands from the class to simplify the code.
  • Make KEEP_WORKER_AFTER_FAILURE actually keep the worker around after failing
  • Deprecate WORKER_REGION and use REGION instead

What is the impact of this change?

  • We can contact different Deadline Cloud endpoints for our tests
  • We support gzip service model files
  • KEEP_WORKER_AFTER_FAILURE works
  • WORKER_REGION configuration is deprecated

How was this change tested?

Was this change documented?

No

Is this a breaking change?

Yes


By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

@jericht jericht changed the title fix: set AWS_ENDPOINT_URL_DEADLINE after installing service model fix!: set AWS_ENDPOINT_URL_DEADLINE after installing service model Apr 17, 2024
@jericht jericht force-pushed the jericht/endpoint_url branch 2 times, most recently from 8c72551 to a0c8f2f Compare April 18, 2024 00:56
@jericht jericht marked this pull request as ready for review April 18, 2024 01:01
@jericht jericht requested a review from a team as a code owner April 18, 2024 01:01
@moorec-aws moorec-aws self-requested a review April 22, 2024 17:02
BREAKING CHANGE: The ServiceModel class no longer has the
"install_command" or "file_path" attributes. Also,
the WORKER_REGION configuration option has been deprecated.
Use REGION instead.

Signed-off-by: Jericho Tolentino <68654047+jericht@users.noreply.github.com>
Copy link

sonarcloud bot commented May 31, 2024

Quality Gate Passed Quality Gate passed

Issues
1 New issue
0 Accepted issues

Measures
0 Security Hotspots
No data about Coverage
0.0% Duplication on New Code

See analysis details on SonarCloud

Copy link
Contributor

@jusiskin jusiskin left a comment

Choose a reason for hiding this comment

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

Approved with understanding that configuring the AWS_ENDPOINT_URL_DEADLINE env var on the created workers will be completed before the next release

@jericht jericht merged commit 6bc4d8f into aws-deadline:mainline Jun 3, 2024
13 checks passed
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.

3 participants