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

Refactor the BaseQueryRewriter hierarchy #64

Closed
chiaradiamarcelo opened this issue Nov 13, 2020 · 0 comments · Fixed by #65
Closed

Refactor the BaseQueryRewriter hierarchy #64

chiaradiamarcelo opened this issue Nov 13, 2020 · 0 comments · Fixed by #65
Labels
refactoring Code improvement without behavior change

Comments

@chiaradiamarcelo
Copy link
Contributor

chiaradiamarcelo commented Nov 13, 2020

The BaseQueryRewriter is used to rewrite a query written in Exasol's SQL dialect to an external data source's SQL dialect.

This class is a concrete class, and provides a rewrite method, but this method is overridden by several classes, and the re-implemented methods break the substitution principle.

This makes it harder to understand, especially when implementing a new SQL dialect, given that one makes the assumption that this BaseQueryRewriter provides a common implementation but it doesn't.

We should address this, probably by making this method abstract and delegating this responsibility to the sub-classes.

@chiaradiamarcelo chiaradiamarcelo added the refactoring Code improvement without behavior change label Nov 13, 2020
@chiaradiamarcelo chiaradiamarcelo changed the title Fix the BaseQueryRewriter hierarchy Refactor the BaseQueryRewriter hierarchy Nov 26, 2020
chiaradiamarcelo added a commit that referenced this issue Nov 27, 2020
* #64: refactor query rewriter hierarchy
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
refactoring Code improvement without behavior change
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant