Uploaded image for project: 'Tajo'
  1. Tajo
  2. TAJO-911

Refactoring Mysql/Maria Catalog Store

    Details

    • Type: Improvement
    • Status: Resolved
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 0.9.0
    • Component/s: None
    • Labels:
      None

      Description

      MysqlStore and MariaDBStore are almost same.
      so, it is better to make one parent class.

        Activity

        Hide
        githubbot ASF GitHub Bot added a comment -

        GitHub user charsyam opened a pull request:

        https://github.com/apache/tajo/pull/59

        TAJO-911 Refactoring MySQL/MariaDB Catalog Store

        MySQLStore and MariaDBStore are almost same.
        so it is better to extract parent class for them.

        You can merge this pull request into a Git repository by running:

        $ git pull https://github.com/charsyam/tajo TAJO-911

        Alternatively you can review and apply these changes as the patch at:

        https://github.com/apache/tajo/pull/59.patch

        To close this pull request, make a commit to your master/trunk branch
        with (at least) the following in the commit message:

        This closes #59


        commit dac64ac5ea009b2df37084bd54d2176c47f61d21
        Author: clark.kang <clark.kang@kakao.com>
        Date: 2014-07-06T12:35:05Z

        TAJO-911 Refactoring MySQL/MariaDB Catalog Store


        Show
        githubbot ASF GitHub Bot added a comment - GitHub user charsyam opened a pull request: https://github.com/apache/tajo/pull/59 TAJO-911 Refactoring MySQL/MariaDB Catalog Store MySQLStore and MariaDBStore are almost same. so it is better to extract parent class for them. You can merge this pull request into a Git repository by running: $ git pull https://github.com/charsyam/tajo TAJO-911 Alternatively you can review and apply these changes as the patch at: https://github.com/apache/tajo/pull/59.patch To close this pull request, make a commit to your master/trunk branch with (at least) the following in the commit message: This closes #59 commit dac64ac5ea009b2df37084bd54d2176c47f61d21 Author: clark.kang <clark.kang@kakao.com> Date: 2014-07-06T12:35:05Z TAJO-911 Refactoring MySQL/MariaDB Catalog Store
        Hide
        githubbot ASF GitHub Bot added a comment -

        Github user hyunsik commented on the pull request:

        https://github.com/apache/tajo/pull/59#issuecomment-48141635

        The patch looks good to me. It's just a question. Did you test it on a local or real cluster? This is because I'm concerned with the difficulty of integrated unit tests of catalog drivers like MySQL or MariaDB.

        Show
        githubbot ASF GitHub Bot added a comment - Github user hyunsik commented on the pull request: https://github.com/apache/tajo/pull/59#issuecomment-48141635 The patch looks good to me. It's just a question. Did you test it on a local or real cluster? This is because I'm concerned with the difficulty of integrated unit tests of catalog drivers like MySQL or MariaDB.
        Hide
        githubbot ASF GitHub Bot added a comment -

        Github user charsyam commented on the pull request:

        https://github.com/apache/tajo/pull/59#issuecomment-48141804

        @hyunsik I just test it in my local system.
        I just changed TestCatalog.java to use MariaDB Driver.
        ant it made Tables well.

        after test. TestCatalog made below tables;

        MariaDB [tajo]> show tables;
        -------------------

        Tables_in_tajo

        -------------------

        COLUMNS
        DATABASES_
        INDEXES
        META
        OPTIONS
        PARTITIONS
        PARTITION_METHODS
        STATS
        TABLES
        TABLESPACES

        -------------------

        MariaDB [tajo]> select * from DATABASES_;
        ----------------------

        DB_ID DB_NAME SPACE_ID

        ----------------------

        1 default 1
        20 tmpdb3 1
        21 tmpdb4 1

        ----------------------

        Show
        githubbot ASF GitHub Bot added a comment - Github user charsyam commented on the pull request: https://github.com/apache/tajo/pull/59#issuecomment-48141804 @hyunsik I just test it in my local system. I just changed TestCatalog.java to use MariaDB Driver. ant it made Tables well. after test. TestCatalog made below tables; MariaDB [tajo] > show tables; ------------------- Tables_in_tajo ------------------- COLUMNS DATABASES_ INDEXES META OPTIONS PARTITIONS PARTITION_METHODS STATS TABLES TABLESPACES ------------------- MariaDB [tajo] > select * from DATABASES_; ------ ------- --------- DB_ID DB_NAME SPACE_ID ------ ------- --------- 1 default 1 20 tmpdb3 1 21 tmpdb4 1 ------ ------- ---------
        Hide
        githubbot ASF GitHub Bot added a comment -

        Github user hyunsik commented on the pull request:

        https://github.com/apache/tajo/pull/59#issuecomment-48268446

        +1
        the patch looks good to me. Thank you for sharing your test result. I've also tested TestCatalog agsinst MySQL. I'll commit it shortly.

        This documentation may be useful to you.
        https://cwiki.apache.org/confluence/display/TAJO/Unit+Tests

        Aside from this issue, I'm concerning with integration test of mysql/mariadb catalog driver. For example, we can do 'mvn clean install' with an external mysql as a catalog store. I'll discuss it more in another Jira issue when we needed.
        Aside from this issue, I'm concerning with

        Show
        githubbot ASF GitHub Bot added a comment - Github user hyunsik commented on the pull request: https://github.com/apache/tajo/pull/59#issuecomment-48268446 +1 the patch looks good to me. Thank you for sharing your test result. I've also tested TestCatalog agsinst MySQL. I'll commit it shortly. This documentation may be useful to you. https://cwiki.apache.org/confluence/display/TAJO/Unit+Tests Aside from this issue, I'm concerning with integration test of mysql/mariadb catalog driver. For example, we can do 'mvn clean install' with an external mysql as a catalog store. I'll discuss it more in another Jira issue when we needed. Aside from this issue, I'm concerning with
        Hide
        githubbot ASF GitHub Bot added a comment -

        Github user asfgit closed the pull request at:

        https://github.com/apache/tajo/pull/59

        Show
        githubbot ASF GitHub Bot added a comment - Github user asfgit closed the pull request at: https://github.com/apache/tajo/pull/59
        Hide
        hudson Hudson added a comment -

        SUCCESS: Integrated in Tajo-master-build #279 (See https://builds.apache.org/job/Tajo-master-build/279/)
        TAJO-911: Refactoring Mysql/Maria Catalog Store. (DaeMyung Kang via hyunsik) (hyunsik: rev b9a39728f9a18f8a9f986f35a40c17005795257b)

        • tajo-catalog/tajo-catalog-server/src/main/java/org/apache/tajo/catalog/store/AbstractMySQLMariaDBStore.java
        • tajo-catalog/tajo-catalog-server/src/main/java/org/apache/tajo/catalog/store/MySQLStore.java
        • tajo-catalog/tajo-catalog-server/src/main/java/org/apache/tajo/catalog/store/MariaDBStore.java
        • CHANGES
        Show
        hudson Hudson added a comment - SUCCESS: Integrated in Tajo-master-build #279 (See https://builds.apache.org/job/Tajo-master-build/279/ ) TAJO-911 : Refactoring Mysql/Maria Catalog Store. (DaeMyung Kang via hyunsik) (hyunsik: rev b9a39728f9a18f8a9f986f35a40c17005795257b) tajo-catalog/tajo-catalog-server/src/main/java/org/apache/tajo/catalog/store/AbstractMySQLMariaDBStore.java tajo-catalog/tajo-catalog-server/src/main/java/org/apache/tajo/catalog/store/MySQLStore.java tajo-catalog/tajo-catalog-server/src/main/java/org/apache/tajo/catalog/store/MariaDBStore.java CHANGES
        Hide
        hyunsik Hyunsik Choi added a comment -

        committed it to master branch.

        Show
        hyunsik Hyunsik Choi added a comment - committed it to master branch.

          People

          • Assignee:
            charsyam DaeMyung Kang
            Reporter:
            charsyam DaeMyung Kang
          • Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development