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

Add metadata to ShardOperationFailedException #27729

Closed
DaveCTurner opened this issue Dec 8, 2017 · 4 comments
Closed

Add metadata to ShardOperationFailedException #27729

DaveCTurner opened this issue Dec 8, 2017 · 4 comments
Assignees
Labels
:Core/Infra/Core Core issues without another label >enhancement feedback_needed Team:Core/Infra Meta label for core/infra team

Comments

@DaveCTurner
Copy link
Contributor

... (the implementations thereof) rather than implementing ToXContent directly. This should reduce the number of ways that errors are reported to clients.

This was suggested as part of #27672 but worthy of another discussion next week as this particular design choice is very well-established and may not be worth changing.

@DaveCTurner
Copy link
Contributor Author

We discussed this in FixItFriday and the main question was whether this'd have any effect on clients of the API or whether the effect would just be on our code. Could @cbuescher and/or @tlrx investigate the impact of this and form a view about whether we want to do it or not?

@tlrx
Copy link
Member

tlrx commented Jan 9, 2018

Sorry to come back so late!

I'm not sure to understand the investigation you're asking for: ShardOperationFailedException are different from the exceptions listed in #27672 as it is not an exception but instead it represents a shard failure with a potential exception as the reason/cause of the failure. To me ShardOperationFailure would be a better name. I agree they are rendered at the REST level in a similar manner than the exceptions, but they are containers of exceptions, not the underlying exception that is rendered using ElasticsearchException.generateThrowableXContent() in failures.

@lcawl lcawl added :Core/Infra/Core Core issues without another label and removed :Exceptions labels Feb 13, 2018
@rjernst rjernst added the Team:Core/Infra Meta label for core/infra team label May 4, 2020
@rjernst rjernst added the needs:triage Requires assignment of a team area label label Dec 3, 2020
@jaymode
Copy link
Member

jaymode commented Dec 14, 2020

@tlrx @DaveCTurner do you think we should add metadata and remove the ToXContent implementation within these exceptions? If not, can we close this issue?

@jaymode jaymode added feedback_needed and removed needs:triage Requires assignment of a team area label labels Dec 14, 2020
@DaveCTurner
Copy link
Contributor Author

I can believe it would be better for clients for all operations that fail on a shard to report themselves with a consistent XContent structure (i.e. shard/index/node in standard fields). However I don't really think we need to keep this open independently of #27672 so I am closing this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
:Core/Infra/Core Core issues without another label >enhancement feedback_needed Team:Core/Infra Meta label for core/infra team
Projects
None yet
Development

No branches or pull requests

8 participants