-
Notifications
You must be signed in to change notification settings - Fork 32
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
[CDAP-21093] Add ExternalDocumentationLink in abstract sink #533
base: develop
Are you sure you want to change the base?
[CDAP-21093] Add ExternalDocumentationLink in abstract sink #533
Conversation
c1663bf
to
2018b92
Compare
2018b92
to
08ccb27
Compare
08ccb27
to
5952ef7
Compare
throw ErrorUtils.getProgramFailureException(new ErrorCategory(ErrorCategory.ErrorCategoryEnum.PLUGIN), | ||
e.getMessage(), errorMessageWithDetails, ErrorType.USER, false, ErrorCodeType.SQLSTATE, | ||
e.getSQLState(), externalDocumentationLink, new SQLException(e.getMessage(), | ||
e.getSQLState(), e.getErrorCode())); |
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.
NIT : remove space
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.
This is auto formatted, with extra intendation since e.getSQLState(), e.getErrorCode())
is part of nested function call to new SQLException
* Override this method to provide a custom external documentation link. | ||
* | ||
* @return external documentation link | ||
*/ | ||
protected String getExternalDocumentationLink() { |
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.
I think we should make this abstract
and enforce the child to implement it correctly.
Returning null might cause issue if someone misses to override this.
Add ExternalDocumentationLink in abstract sink
Jira : CDAP-21093
Description
The AbstractDBSink class also throw SQLException, we also need to make the changes similar to AbstractDBSource there as well.
Ref: #530
Code change
CloudSQLMySQLSink.java
CloudSQLPostgreSQLSink.java
AbstractDBSink.java
AbstractDBSource.java
MysqlSink.java
PostgresSink.java