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

Clean-up API for usage of diffX methods in code #216

Open
idreeskhan opened this issue Dec 30, 2019 · 0 comments
Open

Clean-up API for usage of diffX methods in code #216

idreeskhan opened this issue Dec 30, 2019 · 0 comments

Comments

@idreeskhan
Copy link
Contributor

idreeskhan commented Dec 30, 2019

Over time we've had some things leak into the diff methods that make it more cumbersome to use BigDiffy via code instead of CLI.

For example diffAvro here https://github.com/spotify/ratatool/blob/master/ratatool-diffy/src/main/scala/com/spotify/ratatool/diffy/BigDiffy.scala#L284

User has to manually pass in schema otherwise we they receive a non-informative error regarding null schema, additionally user has to construct MultiKey manually even if still using a single key. We should probably automatically retrieve the schema and pass in a keys string instead which will better match other parameters such as those passed into AvroDiffy.

Trying to run the diff also has an unclear two step process (First create the diff, then call saveStats). We should document this properly or simplify the process.

Also, passing in some SpecificRecord T results in a strange casting error, and instead the user needs to pass a GenericRecord.

@idreeskhan idreeskhan changed the title Clean-up API for direct usage of diffX methods Clean-up API for usage of diffX methods in code Dec 30, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant