Skip to content

Conversation

@dansanduleac
Copy link
Contributor

@dansanduleac dansanduleac commented Aug 23, 2018

This reverts the removals that occurred here: https://github.com/palantir/http-remoting-api/pull/100/files#diff-1604ffe60cf0f42a265fa29f94cbf660
And re-adds the fallback onto the old fields exceptionClass and message but in a cleaner way:

  • no more weird exception message because of the cycles between exceptionClass <-> errorCode and message <-> errorName
  • explicit, SafeLoggable errors when the required field as well as its fallback are both missing
  • deprecated fallback fields no longer participate in equals, hashCode, toString; they are only used as a fallback if the original field wasn't set, otherwise they are essentially dropped

@dansanduleac dansanduleac requested a review from a team as a code owner August 23, 2018 16:23
@dansanduleac dansanduleac requested a review from iamdanfox August 23, 2018 16:36
@JsonProperty(value = "exceptionClass", access = JsonProperty.Access.WRITE_ONLY)
@Value.Auxiliary
@SuppressWarnings("checkstyle:designforextension")
// TODO(rfink): Remove once all error producers have switched to errorCode.
Copy link
Contributor

Choose a reason for hiding this comment

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

I don't think is really ever going to happen - possibly worth deleting entirely?

@dansanduleac dansanduleac merged commit ff297df into conjure Aug 23, 2018
@dansanduleac dansanduleac deleted the ds/backcompat-serializable-error branch August 23, 2018 16:52
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