-
Notifications
You must be signed in to change notification settings - Fork 12
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
Less usages of schema.getName() #107
Conversation
e24954e
to
788b772
Compare
788b772
to
8efc0fc
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM overall, needs minor corrections
@@ -136,10 +137,6 @@ public Class<ENTITY> getInSchemaType() { | |||
return schema.getType(); | |||
} | |||
|
|||
public @NonNull String getTableName() { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
let's maintain a bit more compatibility by keeping getTableName()
and just returning tableDescriptor.tableName()
from this method
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You can get this information from TableDescriptor in caller method (or from schema). This method have only one usage in our project, and there is better to fix it. I prefer to make smaller interface and remove this method
throw new IllegalStateException(String.format("Unable to find index [%s] in table [%s]", | ||
index, schema.getName())); | ||
throw new IllegalStateException( | ||
"Unable to find index [%s] in table [%s]".formatted(index, schema.getTypeName()) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
let's use: in table [%s]
-> for entity [%s]
(because we have no access to table descriptor here)
Co-authored-by: Alexander Lavrukov <[email protected]>
No description provided.