-
Notifications
You must be signed in to change notification settings - Fork 6
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
Feature/fir 21173 add identity support #238
Conversation
src/main/java/com/firebolt/jdbc/client/account/FireboltAccountRetriever.java
Outdated
Show resolved
Hide resolved
src/main/java/com/firebolt/jdbc/client/query/StatementClientImpl.java
Outdated
Show resolved
Hide resolved
src/main/java/com/firebolt/jdbc/connection/FireboltConnection.java
Outdated
Show resolved
Hide resolved
src/test/java/com/firebolt/jdbc/connection/FireboltConnectionTest.java
Outdated
Show resolved
Hide resolved
src/test/java/com/firebolt/jdbc/connection/settings/FireboltPropertiesTest.java
Outdated
Show resolved
Hide resolved
src/main/java/com/firebolt/jdbc/connection/settings/FireboltSessionProperty.java
Show resolved
Hide resolved
src/main/java/com/firebolt/jdbc/connection/FireboltConnection.java
Outdated
Show resolved
Hide resolved
src/main/java/com/firebolt/jdbc/connection/settings/FireboltProperties.java
Outdated
Show resolved
Hide resolved
src/main/java/com/firebolt/jdbc/connection/settings/FireboltProperties.java
Outdated
Show resolved
Hide resolved
src/main/java/com/firebolt/jdbc/connection/settings/FireboltProperties.java
Outdated
Show resolved
Hide resolved
src/main/java/com/firebolt/jdbc/connection/settings/FireboltProperties.java
Show resolved
Hide resolved
src/main/java/com/firebolt/jdbc/connection/settings/FireboltSessionProperty.java
Outdated
Show resolved
Hide resolved
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.
Generally LGTM, left one question. I would also ask to wait for an approval from Petro
return loginProperties.toBuilder().host(engine.getEndpoint()).engine(engine.getName()).systemEngine(false).database(engine.getDatabase()).build(); | ||
} | ||
|
||
private void assertDatabaseExisting(String database) throws SQLException { |
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.
Just a question, should't it also be throws FireboltException
, since we do throw new FireboltException(...)
?
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.
No. Generally the interfaces should use general terms. Prefer interface to class, prefer interface/class higher in hierarchy than specific one. This is the basics of the OOD.
Specifically here. FireboltException
extends SQLException
and therefore can be thrown from any function that is declared as throws SQLException
. The opposite is incorrect. If your function is declared as throws FireboltException
it cannot throw SQLException
. This is the reason that there many places in code that look like the following:
void someFunction() throws FireboltException {
try {
// some code that throws SQLException
} catch (SQLException e) {
throw new FireboltException(e)
}
}
This try/catch
is absolutely redundant. Just declare that function throws SQLException
.
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.
Ok, makes sense
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, thanks for the change.
Kudos, SonarCloud Quality Gate passed! |
This historical PR has been replaced by #252 |
updated minimal implementation of the new identity