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

Remove vtrpc.LegacyErrorCode #8456

Merged
merged 3 commits into from
Aug 19, 2021

Conversation

ajm188
Copy link
Contributor

@ajm188 ajm188 commented Jul 12, 2021

It has been "legacy" for 4 years now, so it should be safe to just drop.

Signed-off-by: Andrew Mason [email protected]

Description

Related Issue(s)

Checklist

  • Tests were added or are not required - n/a
  • Documentation was added or is not required - n/a

I wasn't sure what component to pick since it pretty much affects all of them (since they all use vtrpc.RPCError in some form or fashion)

Deployment Notes

Copy link
Collaborator

@vmg vmg left a comment

Choose a reason for hiding this comment

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

The changes look correct to me. You're gonna need to make proto again because I merged an updated version of the compiler this morning.

Besides that, I don't know whether the LegacyErrorCode is legacy enough to be removed already!

@ajm188 ajm188 force-pushed the am_remove_legacy_error_codes branch from 3c39e53 to 4964352 Compare July 20, 2021 19:42
@ajm188
Copy link
Contributor Author

ajm188 commented Jul 21, 2021

Hmm, it looks like this is failing on the java stuff, do you have any idea how I update that to stop expecting these types?

Error:  Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.8.1:compile (default-compile) on project vitess-client: Compilation failure: Compilation failure: 
Error:  /vt/src/vitess.io/vitess/java/client/src/main/java/io/vitess/client/Proto.java:[96,20] cannot find symbol
Error:    symbol:   method getLegacyCode()
Error:    location: variable error of type io.vitess.proto.Vtrpc.RPCError
... (more like this)

more specifically, is this client codegen'd from the protos somehow? i don't see a make target anywhere. i can obviously just delete the references to the old types, but i am not sure if there's something else i should be doing since i'm not familiar with the java client

@vmg
Copy link
Collaborator

vmg commented Jul 21, 2021

@systay maybe you know how this Java stuff is generated?

@deepthi deepthi requested a review from harshit-gangal July 26, 2021 16:54
@systay
Copy link
Collaborator

systay commented Jul 28, 2021

hmm... if it's not created with make proto, I don't know

@harshit-gangal
Copy link
Member

The only thing to change is removing the switch condition in java/client/src/main/java/io/vitess/client/Proto.java
which uses the LegacyErrorCode.

ajm188 added 3 commits August 19, 2021 11:23
It has been "legacy" for 4 years now, so it should be safe to just drop.

Signed-off-by: Andrew Mason <[email protected]>
@ajm188 ajm188 force-pushed the am_remove_legacy_error_codes branch from 403a352 to e2a37bc Compare August 19, 2021 15:23
@ajm188 ajm188 merged commit 1f5a7ed into vitessio:main Aug 19, 2021
@ajm188 ajm188 deleted the am_remove_legacy_error_codes branch August 19, 2021 16:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants