-
Notifications
You must be signed in to change notification settings - Fork 8.2k
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
Migrate CCR to new ES JS client. #100131
Merged
cjcenizal
merged 7 commits into
elastic:master
from
cjcenizal:ccr/migrate-legacy-es-client
Jun 1, 2021
Merged
Migrate CCR to new ES JS client. #100131
Changes from all commits
Commits
Show all changes
7 commits
Select commit
Hold shift + click to select a range
1a3ee00
Migrate CCR to new ES JS client.
cjcenizal e0b22af
Update SectionError component to render error root causes correctly.
cjcenizal bf26708
Fix 404 error rendering.
cjcenizal f8714b2
Update API integration tests.
cjcenizal 7439e7b
Add test for follower index update API route.
cjcenizal 7882b5f
Merge branch 'master' into ccr/migrate-legacy-es-client
cjcenizal f2f583d
Remove default generic from router type def.
cjcenizal File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -11,21 +11,19 @@ import { EuiCallOut, EuiSpacer } from '@elastic/eui'; | |
export function SectionError(props) { | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I'll migrate this to use our shared |
||
const { title, error, ...rest } = props; | ||
const data = error.body ? error.body : error; | ||
const { | ||
error: errorString, | ||
attributes, // wrapEsError() on the server add a "cause" array | ||
message, | ||
} = data; | ||
const { error: errorString, attributes, message } = data; | ||
|
||
return ( | ||
<EuiCallOut title={title} color="danger" iconType="alert" {...rest}> | ||
<div>{message || errorString}</div> | ||
{attributes && attributes.cause && ( | ||
{attributes?.error?.root_cause && ( | ||
<Fragment> | ||
<EuiSpacer size="m" /> | ||
<ul> | ||
{attributes.cause.map((message, i) => ( | ||
<li key={i}>{message}</li> | ||
{attributes.error.root_cause.map(({ type, reason }, i) => ( | ||
<li key={i}> | ||
{type}: {reason} | ||
</li> | ||
))} | ||
</ul> | ||
</Fragment> | ||
|
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
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
199 changes: 0 additions & 199 deletions
199
x-pack/plugins/cross_cluster_replication/server/client/elasticsearch_ccr.ts
This file was deleted.
Oops, something went wrong.
78 changes: 0 additions & 78 deletions
78
x-pack/plugins/cross_cluster_replication/server/lib/format_es_error.ts
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@yuliacech I believe you wrote these originally, but I wasn't able to get the original instructions to work. Can you check this and see if I was just doing it wrong?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for updating those instructions, @cjcenizal! I can confirm that the previous instructions didn't work for me either, tested your steps and it worked like a charm 👍