You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by GitBox <gi...@apache.org> on 2020/05/08 10:12:57 UTC

[GitHub] [flink] leonardBang opened a new pull request #12036: [FLINK-17537][connectors / jdbc] Refactor flink-jdbc connector structure

leonardBang opened a new pull request #12036:
URL: https://github.com/apache/flink/pull/12036


   
   <!--
   *Thank you very much for contributing to Apache Flink - we are happy that you want to help us improve Flink. To help the community review your contribution in the best possible way, please go through the checklist below, which will get the contribution into a shape in which it can be best reviewed.*
   
   *Please understand that we do not do this to make contributions to Flink a hassle. In order to uphold a high standard of quality for code contributions, while at the same time managing a large number of contributions, we need contributors to prepare the contributions well, and give reviewers enough contextual information for the review. Please also understand that contributions that do not follow this guide will take longer to review and thus typically be picked up with lower priority by the community.*
   
   ## Contribution Checklist
   
     - Make sure that the pull request corresponds to a [JIRA issue](https://issues.apache.org/jira/projects/FLINK/issues). Exceptions are made for typos in JavaDoc or documentation files, which need no JIRA issue.
   
     - Name the pull request in the form "[FLINK-XXXX] [component] Title of the pull request", where *FLINK-XXXX* should be replaced by the actual issue number. Skip *component* if you are unsure about which is the best component.
     Typo fixes that have no associated JIRA issue should be named following this pattern: `[hotfix] [docs] Fix typo in event time introduction` or `[hotfix] [javadocs] Expand JavaDoc for PuncuatedWatermarkGenerator`.
   
     - Fill out the template below to describe the changes contributed by the pull request. That will give reviewers the context they need to do the review.
   
     - Make sure that the change passes the automated tests, i.e., `mvn clean verify` passes. You can set up Travis CI to do that following [this guide](https://flink.apache.org/contributing/contribute-code.html#open-a-pull-request).
   
     - Each pull request should address only one issue, not mix up code from multiple issues.
   
     - Each commit in the pull request has a meaningful commit message (including the JIRA id)
   
     - Once all items of the checklist are addressed, remove the above text and this checklist, leaving only the filled out template below.
   
   
   **(The sections below can be removed for hotfixes of typos)**
   -->
   
   ## What is the purpose of the change
   
   * This pull request refactor flink-jdbc connector structure and make it align with others in connector family. I split the PR to two commits to keep them clear enough.
   
   
   ## Brief change log
   #### commit: 6aff2b509
       (1) Use Jdbc instead of JDBC;
       (2) Move interfaces and classes to org.apache.flink.connector.jdbc;
       (3) Keep ancient JDBCOutputFormat, JDBCInputFormat and ParameterValuesProvider in old package;
       (4) Add tests/ITCase for ancient Classes and new classes.
    ####   commit: 173ded8 
       (1) Rename flink-jdbc module to flink-connector-jdbc;
       (2) Update docs.
   
   ## Verifying this change
   * Add tests for reserved class in old package
   * Update tests for new package
   
   ## Does this pull request potentially affect one of the following parts:
   
     - Dependencies (does it add or upgrade a dependency): (no)
     - The public API, i.e., is any changed class annotated with `@Public(Evolving)`: (no)
     - The serializers: (no)
     - The runtime per-record code paths (performance sensitive): ( no)
     - Anything that affects deployment or recovery: JobManager (and its components), Checkpointing, Yarn/Mesos, ZooKeeper: (no)
     - The S3 file system connector: (no)
   
   ## Documentation
   
     - Does this pull request introduce a new feature? (no)
     - If yes, how is the feature documented? (not applicable / docs / JavaDocs / not documented)
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [flink] flinkbot commented on pull request #12036: [FLINK-17537][connectors / jdbc] Refactor flink-jdbc connector structure

Posted by GitBox <gi...@apache.org>.
flinkbot commented on pull request #12036:
URL: https://github.com/apache/flink/pull/12036#issuecomment-625870744


   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "173ded87a6bbdc639582e62245de653ce562e0ef",
       "status" : "UNKNOWN",
       "url" : "TBD",
       "triggerID" : "173ded87a6bbdc639582e62245de653ce562e0ef",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * 173ded87a6bbdc639582e62245de653ce562e0ef UNKNOWN
   
   <details>
   <summary>Bot commands</summary>
     The @flinkbot bot supports the following commands:
   
    - `@flinkbot run travis` re-run the last Travis build
    - `@flinkbot run azure` re-run the last Azure build
   </details>


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [flink] flinkbot commented on pull request #12036: [FLINK-17537][connectors / jdbc] Refactor flink-jdbc connector structure

Posted by GitBox <gi...@apache.org>.
flinkbot commented on pull request #12036:
URL: https://github.com/apache/flink/pull/12036#issuecomment-625745888


   Thanks a lot for your contribution to the Apache Flink project. I'm the @flinkbot. I help the community
   to review your pull request. We will use this comment to track the progress of the review.
   
   
   ## Automated Checks
   Last check on commit 173ded87a6bbdc639582e62245de653ce562e0ef (Fri May 08 10:15:17 UTC 2020)
   
   **Warnings:**
    * **2 pom.xml files were touched**: Check for build and licensing issues.
   
   
   <sub>Mention the bot in a comment to re-run the automated checks.</sub>
   ## Review Progress
   
   * ❓ 1. The [description] looks good.
   * ❓ 2. There is [consensus] that the contribution should go into to Flink.
   * ❓ 3. Needs [attention] from.
   * ❓ 4. The change fits into the overall [architecture].
   * ❓ 5. Overall code [quality] is good.
   
   Please see the [Pull Request Review Guide](https://flink.apache.org/contributing/reviewing-prs.html) for a full explanation of the review process.<details>
    The Bot is tracking the review progress through labels. Labels are applied according to the order of the review items. For consensus, approval by a Flink committer of PMC member is required <summary>Bot commands</summary>
     The @flinkbot bot supports the following commands:
   
    - `@flinkbot approve description` to approve one or more aspects (aspects: `description`, `consensus`, `architecture` and `quality`)
    - `@flinkbot approve all` to approve all aspects
    - `@flinkbot approve-until architecture` to approve everything until `architecture`
    - `@flinkbot attention @username1 [@username2 ..]` to require somebody's attention
    - `@flinkbot disapprove architecture` to remove an approval you gave earlier
   </details>


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [flink] flinkbot edited a comment on pull request #12036: [FLINK-17537][connectors / jdbc] Refactor flink-jdbc connector structure

Posted by GitBox <gi...@apache.org>.
flinkbot edited a comment on pull request #12036:
URL: https://github.com/apache/flink/pull/12036#issuecomment-625870744


   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "173ded87a6bbdc639582e62245de653ce562e0ef",
       "status" : "PENDING",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=829",
       "triggerID" : "173ded87a6bbdc639582e62245de653ce562e0ef",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * 173ded87a6bbdc639582e62245de653ce562e0ef Azure: [PENDING](https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=829) 
   
   <details>
   <summary>Bot commands</summary>
     The @flinkbot bot supports the following commands:
   
    - `@flinkbot run travis` re-run the last Travis build
    - `@flinkbot run azure` re-run the last Azure build
   </details>


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [flink] wuchong commented on a change in pull request #12036: [FLINK-17537][connectors / jdbc] Refactor flink-jdbc connector structure

Posted by GitBox <gi...@apache.org>.
wuchong commented on a change in pull request #12036:
URL: https://github.com/apache/flink/pull/12036#discussion_r422091825



##########
File path: flink-connectors/flink-connector-jdbc/src/main/java/org/apache/flink/api/java/io/jdbc/JDBCInputFormat.java
##########
@@ -0,0 +1,163 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.flink.api.java.io.jdbc;
+
+import org.apache.flink.annotation.VisibleForTesting;
+import org.apache.flink.api.java.typeutils.RowTypeInfo;
+import org.apache.flink.connector.jdbc.JdbcInputFormat;
+import org.apache.flink.connector.jdbc.source.row.converter.JdbcRowConverter;
+import org.apache.flink.connector.jdbc.split.JdbcParameterValuesProvider;
+import org.apache.flink.util.Preconditions;
+
+import java.sql.Connection;
+import java.sql.PreparedStatement;
+import java.sql.ResultSet;
+
+/**
+ * InputFormat to read data from a database and generate Rows.
+ * The InputFormat has to be configured using the supplied InputFormatBuilder.

Review comment:
       You can keep the original class Javadoc here. 

##########
File path: flink-connectors/flink-connector-jdbc/src/main/java/org/apache/flink/api/java/io/jdbc/split/GenericParameterValuesProvider.java
##########
@@ -0,0 +1,43 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.flink.api.java.io.jdbc.split;
+
+import org.apache.flink.api.java.io.jdbc.JDBCInputFormat;
+import org.apache.flink.connector.jdbc.split.JdbcGenericParameterValuesProvider;
+
+import java.io.Serializable;
+
+/**
+ * This splits generator actually does nothing but wrapping the query parameters
+ * computed by the user before creating the {@link JDBCInputFormat} instance.
+ *
+ * @deprecated Please use {@link JdbcGenericParameterValuesProvider}.
+ */
+@Deprecated
+public class GenericParameterValuesProvider extends JdbcGenericParameterValuesProvider implements ParameterValuesProvider{

Review comment:
       ```suggestion
   public class GenericParameterValuesProvider extends JdbcGenericParameterValuesProvider implements ParameterValuesProvider {
   ```

##########
File path: flink-connectors/flink-connector-jdbc/src/main/java/org/apache/flink/connector/jdbc/dialect/JdbcDialect.java
##########
@@ -80,7 +80,7 @@ default String quoteIdentifier(String identifier) {
 	 * the use of select + update/insert, this performance is poor.
 	 */
 	default Optional<String> getUpsertStatement(
-			String tableName, String[] fieldNames, String[] uniqueKeyFields) {
+		String tableName, String[] fieldNames, String[] uniqueKeyFields) {

Review comment:
       indent

##########
File path: flink-connectors/flink-connector-jdbc/src/main/java/org/apache/flink/api/java/io/jdbc/split/ParameterValuesProvider.java
##########
@@ -0,0 +1,35 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.flink.api.java.io.jdbc.split;
+
+import org.apache.flink.api.java.io.jdbc.JDBCInputFormat;
+import org.apache.flink.connector.jdbc.split.JdbcParameterValuesProvider;
+
+/**
+ * This interface is used by the {@link JDBCInputFormat} to compute the list of parallel query to run (i.e. splits).
+ * Each query will be parameterized using a row of the matrix provided by each {@link ParameterValuesProvider}
+ * implementation.
+ *
+ * @deprecated Please use {@link JdbcParameterValuesProvider}.
+ * Flink proposes class name start with "Jdbc" rather than "JDBC".

Review comment:
       remove this line.

##########
File path: flink-connectors/flink-connector-jdbc/src/main/java/org/apache/flink/connector/jdbc/dialect/JdbcDialects.java
##########
@@ -39,27 +39,27 @@
 /**
  * Default JDBC dialects.
  */
-public final class JDBCDialects {
+public class JdbcDialects {

Review comment:
       Why removes the `final`? 

##########
File path: flink-connectors/flink-connector-jdbc/src/main/java/org/apache/flink/connector/jdbc/JdbcBatchingOutputFormat.java
##########
@@ -40,10 +39,13 @@
 import java.util.concurrent.TimeUnit;
 import java.util.function.Function;
 
-import static org.apache.flink.api.java.io.jdbc.JDBCUtils.setRecordToStatement;
+import static org.apache.flink.connector.jdbc.JdbcUtils.setRecordToStatement;
 import static org.apache.flink.util.Preconditions.checkNotNull;
 
-class JdbcBatchingOutputFormat<In, JdbcIn, JdbcExec extends JdbcBatchStatementExecutor<JdbcIn>> extends AbstractJdbcOutputFormat<In> {
+/**
+ * A JDBC outputFormat support batching records before writing records to database.
+ */
+public class JdbcBatchingOutputFormat<In, JdbcIn, JdbcExec extends JdbcBatchStatementExecutor<JdbcIn>> extends AbstractJdbcOutputFormat<In> {

Review comment:
       The package-visible is on purpose, so that users can't extend this class. 

##########
File path: flink-connectors/flink-connector-jdbc/src/main/java/org/apache/flink/connector/jdbc/JdbcOutputFormat.java
##########
@@ -37,15 +36,16 @@
  * @see Row
  * @see DriverManager
  */
+
 /**
  * @deprecated use {@link JdbcBatchingOutputFormat}
  */
 @Deprecated
-public class JDBCOutputFormat extends AbstractJdbcOutputFormat<Row> {
+public class JdbcOutputFormat extends AbstractJdbcOutputFormat<Row> {

Review comment:
       Please remove this class. 

##########
File path: flink-connectors/flink-connector-jdbc/src/main/java/org/apache/flink/connector/jdbc/JdbcSinkFunction.java
##########
@@ -31,9 +31,9 @@
  */
 @Deprecated
 class JdbcSinkFunction extends RichSinkFunction<Row> implements CheckpointedFunction {

Review comment:
       remove this file? I think nobody is using it, and `GenericJdbcSinkFunction` is not accessible for users.

##########
File path: flink-connectors/flink-connector-jdbc/src/test/java/org/apache/flink/connector/jdbc/JdbcITCase.java
##########
@@ -35,26 +33,22 @@
 import java.util.Arrays;
 import java.util.List;
 
-import static org.apache.flink.api.java.io.jdbc.JdbcTestFixture.INPUT_TABLE;
-import static org.apache.flink.api.java.io.jdbc.JdbcTestFixture.INSERT_TEMPLATE;
-import static org.apache.flink.api.java.io.jdbc.JdbcTestFixture.TEST_DATA;

Review comment:
       I think keeping this static imports can make code more concise. 

##########
File path: flink-connectors/pom.xml
##########
@@ -36,7 +36,7 @@ under the License.
 	<packaging>pom</packaging>
 
 	<modules>
-		<module>flink-jdbc</module>
+		<module>flink-connector-jdbc</module>

Review comment:
       Put it after `hive` moedule in alphabetical order? 

##########
File path: flink-connectors/flink-connector-jdbc/src/main/java/org/apache/flink/connector/jdbc/source/row/converter/JdbcRowConverter.java
##########
@@ -16,7 +16,7 @@
  * limitations under the License.
  */
 
-package org.apache.flink.api.java.io.jdbc.source.row.converter;
+package org.apache.flink.connector.jdbc.source.row.converter;

Review comment:
       Move to `org.apache.flink.connector.jdbc.source.converter` package? I think converter is always used for Row (or RowData in the future). 

##########
File path: flink-connectors/flink-connector-jdbc/src/main/java/org/apache/flink/connector/jdbc/dialect/JdbcDialect.java
##########
@@ -31,7 +31,7 @@
 /**
  * Handle the SQL dialect of jdbc driver.
  */
-public interface JDBCDialect extends Serializable {
+public interface JdbcDialect extends Serializable {

Review comment:
       How about to add an `@Internal` annotation on this to tell this is not ready to be exposed to users.




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [flink] flinkbot edited a comment on pull request #12036: [FLINK-17537][connectors / jdbc] Refactor flink-jdbc connector structure

Posted by GitBox <gi...@apache.org>.
flinkbot edited a comment on pull request #12036:
URL: https://github.com/apache/flink/pull/12036#issuecomment-625870744


   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "173ded87a6bbdc639582e62245de653ce562e0ef",
       "status" : "CANCELED",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=829",
       "triggerID" : "173ded87a6bbdc639582e62245de653ce562e0ef",
       "triggerType" : "PUSH"
     }, {
       "hash" : "0fc75d8ca4b1834b402d7be49d803bc757810fa9",
       "status" : "UNKNOWN",
       "url" : "TBD",
       "triggerID" : "0fc75d8ca4b1834b402d7be49d803bc757810fa9",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * 173ded87a6bbdc639582e62245de653ce562e0ef Azure: [CANCELED](https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=829) 
   * 0fc75d8ca4b1834b402d7be49d803bc757810fa9 UNKNOWN
   
   <details>
   <summary>Bot commands</summary>
     The @flinkbot bot supports the following commands:
   
    - `@flinkbot run travis` re-run the last Travis build
    - `@flinkbot run azure` re-run the last Azure build
   </details>


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [flink] leonardBang commented on pull request #12036: [FLINK-17537][connectors / jdbc] Refactor flink-jdbc connector structure

Posted by GitBox <gi...@apache.org>.
leonardBang commented on pull request #12036:
URL: https://github.com/apache/flink/pull/12036#issuecomment-625830095


   Thanks @faisalmoeen and @wuchong ‘s notes and comments.
   I'll update the PR soon.
   Hi, @fpompermaier For your first note about StreamITCase.clear() I‘ll skip too because FLIP-84 is not ready now(but should be soon). For the second note, this PR will try not to  modify JDBCDDialect.java and keep the PR clean and I think the JDBC Dialect need a better design too but not in this time(It will be a public API and need disscuss and design and even a FLIP from my unserstanding) 


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [flink] flinkbot edited a comment on pull request #12036: [FLINK-17537][connectors / jdbc] Refactor flink-jdbc connector structure

Posted by GitBox <gi...@apache.org>.
flinkbot edited a comment on pull request #12036:
URL: https://github.com/apache/flink/pull/12036#issuecomment-625870744


   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "173ded87a6bbdc639582e62245de653ce562e0ef",
       "status" : "CANCELED",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=829",
       "triggerID" : "173ded87a6bbdc639582e62245de653ce562e0ef",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * 173ded87a6bbdc639582e62245de653ce562e0ef Azure: [CANCELED](https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=829) 
   
   <details>
   <summary>Bot commands</summary>
     The @flinkbot bot supports the following commands:
   
    - `@flinkbot run travis` re-run the last Travis build
    - `@flinkbot run azure` re-run the last Azure build
   </details>


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [flink] fpompermaier commented on a change in pull request #12036: [FLINK-17537][connectors / jdbc] Refactor flink-jdbc connector structure

Posted by GitBox <gi...@apache.org>.
fpompermaier commented on a change in pull request #12036:
URL: https://github.com/apache/flink/pull/12036#discussion_r422124179



##########
File path: flink-connectors/flink-connector-jdbc/src/main/java/org/apache/flink/connector/jdbc/dialect/JdbcDialects.java
##########
@@ -39,27 +39,27 @@
 /**
  * Default JDBC dialects.
  */
-public final class JDBCDialects {
+public class JdbcDialects {

Review comment:
       And what about moving each dialect in its own class (instead of having all the implementation insidide this class)? Or better: why don't load them via SPI (so we could support more dialects just adding external jars to Flink lib directory without requiring to have them in the official jdbc connector code)?




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [flink] fpompermaier commented on pull request #12036: [FLINK-17537][connectors / jdbc] Refactor flink-jdbc connector structure

Posted by GitBox <gi...@apache.org>.
fpompermaier commented on pull request #12036:
URL: https://github.com/apache/flink/pull/12036#issuecomment-625783987


   Just two notes: since you are refactoring the entire JDBC connector I have collected 2 observations from the other PR I have opened:
   
   - made by @aljoscha on pull #11986 for FLINK-17361: the usage of StreamITCase.clear() in JDBCTableSourceITCase.java is an anti-pattern that should be avoided
   - made by me on pull #12038 and #11999: in all methods in JDBCDialect.java it would be better to have the tableName parameter as an object on which we can extract **schema** and the non-qualified **tableName**, in order to avoid to wrongly quote table names. In those PR I removed the quoteIdentifier(tableName) within the getMergeIntoStatement() but I think the same principle applies also to other methods such as getInsertIntoStatement() or getRowExistsStatement().


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [flink] flinkbot edited a comment on pull request #12036: [FLINK-17537][connectors / jdbc] Refactor flink-jdbc connector structure

Posted by GitBox <gi...@apache.org>.
flinkbot edited a comment on pull request #12036:
URL: https://github.com/apache/flink/pull/12036#issuecomment-625870744


   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "173ded87a6bbdc639582e62245de653ce562e0ef",
       "status" : "CANCELED",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=829",
       "triggerID" : "173ded87a6bbdc639582e62245de653ce562e0ef",
       "triggerType" : "PUSH"
     }, {
       "hash" : "0fc75d8ca4b1834b402d7be49d803bc757810fa9",
       "status" : "PENDING",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=976",
       "triggerID" : "0fc75d8ca4b1834b402d7be49d803bc757810fa9",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * 173ded87a6bbdc639582e62245de653ce562e0ef Azure: [CANCELED](https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=829) 
   * 0fc75d8ca4b1834b402d7be49d803bc757810fa9 Azure: [PENDING](https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=976) 
   
   <details>
   <summary>Bot commands</summary>
     The @flinkbot bot supports the following commands:
   
    - `@flinkbot run travis` re-run the last Travis build
    - `@flinkbot run azure` re-run the last Azure build
   </details>


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org