[CDAP-17402] Upgrade debizum version to 1.3.1.Final#109
Conversation
| } | ||
|
|
||
| jdbcConfig = jdbcConfigBuilder.build(); | ||
| String driverClassName = jdbcConfig.getString(MySqlConnectorConfig.JDBC_DRIVER); |
There was a problem hiding this comment.
looks like the local variable driverClassName is not referenced in this method
There was a problem hiding this comment.
Yes thats correct. driverClassName is used in the original file - https://github.com/debezium/debezium/blob/v1.3.1.Final/debezium-connector-mysql/src/main/java/io/debezium/connector/mysql/MySqlJdbcContext.java#L84 however we pass in the connectionFactory that we set. To keep the changes in these copied file minimum, I kept this variable as it is.
There was a problem hiding this comment.
thanks for the information :)
| .filter(x -> !(x.startsWith(DatabaseHistory.CONFIGURATION_FIELD_PREFIX_STRING) || | ||
| x.equals(MySqlConnectorConfig.DATABASE_HISTORY.name()))) | ||
| .edit() | ||
| .withDefault(MySqlConnectorConfig.PORT, MySqlConnectorConfig.PORT.defaultValue()) |
There was a problem hiding this comment.
do we need this line ? If the Field already has a "defaultValue" method , do we need to override the default value here this way ?
I might be wrong since I'm not familiar with Debezium API. Looks like this method is for overriding the default value of a field. Otherwise it just need one argument Field
| public EventProcessingFailureHandlingMode eventProcessingFailureHandlingMode() { | ||
| String mode = config.getString(CommonConnectorConfig.EVENT_PROCESSING_FAILURE_HANDLING_MODE); | ||
| if (mode == null) { | ||
| mode = config.getString(MySqlConnectorConfig.EVENT_DESERIALIZATION_FAILURE_HANDLING_MODE); |
There was a problem hiding this comment.
so this can't be null ? Do we need to handle the error if this one is null too ?
| } | ||
|
|
||
| /** | ||
| * Determine the difference between two sets. |
There was a problem hiding this comment.
nit : "between two GTID sets"
seanzhougoogle
left a comment
There was a problem hiding this comment.
Thank you sagar:)
|
Thanks Sean for the review. As discussed keeping the classes from debezium as it is except where we absolutely need to change them. |
Upgrade the debezium version to 1.3.1.Final. Currently we use 0.9.5.Final which is outdated.
This PR mainly copies and fixes checkstyle issues in the debezium classes: MySQLConnectorConfig, MySqlJdbcContext, MySqlValueConverters, and SqlServerConnections corresponding to version 1.3.1.Final. This was done for 0.9.5.Final version in these PRs - #35 and #38.