-
Notifications
You must be signed in to change notification settings - Fork 5
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
Pass credentials around with context #203
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
577f4d5
to
26a60d4
Compare
update:
|
26a60d4
to
8494168
Compare
update:
|
8494168
to
de7792c
Compare
2 tasks
Context is not part of serialized context. context.credentials is treated separately But passing them around together simplifies the process
de7792c
to
deffd73
Compare
update:
|
Checked commit kbrock@deffd73 with ruby 2.7.8, rubocop 1.56.3, haml-lint 0.51.0, and yamllint |
agrare
approved these changes
Jun 13, 2024
agrare
added a commit
that referenced
this pull request
Jun 20, 2024
Fixed - ResultPath=$ replaces complete output (#199) - Fix retrier backoff values (#200) - Fix Retry issues (#202) - Add Apache-2.0 license (#217) Changed - Update gemspec summary (#205) - Simpler State#long_name (#204) - State only modifies Context#state - prep for Map/Parallel (#206) - Set StateHistory in Workflow not State (#211) - Make Runner#wait optional (#190) - Pass credentials around with context (#203) - Pass context to State without workflow (#216) - Move the guts of the CLI into a class for easy testing (#220) Added - Set State PreviousStateGuid in StateHistory (#208) - Add a codeclimate config file (#224) - Add an Execution unique ID to Context (#226)
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Overview
My higher goal is to have
State
not store theworkspace
,context
, norcredentials
. See #210We store
Context
andCredentials
separately in the database. So it makes sense to keep them separate.But having a single container that holds all runtime state simplifies matters.
Before
Passed
Context
andCredentials
separately.The
State
accessed them usingState#workspace#context
andState#workspace#credentials
.If we go towards removing
State#workspace
,run_nonblock(context, credentials)
will provide that data.After
Context
contains the context andContext#to_h
returns the same value. ButContext#credentials
will contain the sensitive credentials.The
State
accesses them usingState#workspace#context
and `State#workspace#context#credentials.If we go towards removing
State#workspace
,run_nonblock(context)
will be able to provide that data.Compromise
Would have liked to remove
Workspace#context
andWorkspace#initialize(..., context
), but left it in there until we updatemanageiq-providers-workspace
.