Skip to content

[App Search] Credentials: Add final Logic and server routes#81519

Merged
cee-chen merged 8 commits intoelastic:masterfrom
cee-chen:credentials-flyout-2
Oct 22, 2020
Merged

[App Search] Credentials: Add final Logic and server routes#81519
cee-chen merged 8 commits intoelastic:masterfrom
cee-chen:credentials-flyout-2

Conversation

@cee-chen
Copy link
Copy Markdown
Contributor

@cee-chen cee-chen commented Oct 22, 2020

PR sequence

This PR is part of a set of 3 PRs that implements the Credentials flyout form + functionality. It's broken up into PRs in the 400-800 line range so as not to open a 1700~ line PR.

List of all PRs (may be helpful for obtaining more context / QAing the entire final feature)

Summary

This PR achieves:

  • Adding CredentialsLogic.values.fullEngineAccessChecked
  • Adding CredentialsLogic.actions.onEngineSelect
  • Adding CredentialsLogic.actions.onApiTokenChange
  • Adding server API routes that CredentialsLogic.actions.onApiTokenChange calls:
    • POST /api/app_search/credentials
    • PUT /api/app_search/credentials/{name}

QA

This PR does not have easily testable changes in and of itself. It's easier to QA this against the credentials-flyout-3 branch.

Checklist

@cee-chen cee-chen added Feature:Plugins release_note:skip Skip the PR/issue when compiling release notes v7.11.0 labels Oct 22, 2020
@cee-chen cee-chen requested review from a team and JasonStoltz October 22, 2020 18:08
Comment on lines +200 to +201
describe('validates', () => {
describe('admin keys', () => {
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Note: this is copied/pasted from the new POST route tests. In theory we could DRY it out (since both routes inherit the same exact schema), but I didn't want to over-complicate it for now.

Copy link
Copy Markdown
Member

@JasonStoltz JasonStoltz left a comment

Choose a reason for hiding this comment

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

Nice work, quick turn around on this! There's a couple of small changes we may want to consider here.

@kibanamachine
Copy link
Copy Markdown
Contributor

💚 Build Succeeded

Metrics [docs]

async chunks size

id before after diff
enterpriseSearch 654.9KB 657.3KB +2.3KB

History

To update your PR or re-run it, just comment with:
@elasticmachine merge upstream

cee-chen pushed a commit to cee-chen/kibana that referenced this pull request Oct 26, 2020
…81519)

* Add fullEngineAccessChecked logic

* Add onEngineSelect logic

* [Refactor] DRY out/simplify http mocks

Note: import reorder is required in for mocks to work correctly

* Add onApiTokenChange logic

* Update flyout footer to use onApiTokenChange

* Add new POST/PUT server routes

+ some opinionated comments

* [PR feedback] tests copy, extra data tests

* [PR feedback] Reuse fullEngineAccessChecked, fix fullEngineAccessChecked being undefined vs a bool
cee-chen pushed a commit that referenced this pull request Oct 26, 2020
…81540)

* Add fullEngineAccessChecked logic

* Add onEngineSelect logic

* [Refactor] DRY out/simplify http mocks

Note: import reorder is required in for mocks to work correctly

* Add onApiTokenChange logic

* Update flyout footer to use onApiTokenChange

* Add new POST/PUT server routes

+ some opinionated comments

* [PR feedback] tests copy, extra data tests

* [PR feedback] Reuse fullEngineAccessChecked, fix fullEngineAccessChecked being undefined vs a bool

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Feature:Plugins release_note:skip Skip the PR/issue when compiling release notes v7.11.0

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants