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

Throw PlanningException when Creating table with Partition exception COLUMN

    Details

    • Type: Improvement
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 0.8.0
    • Component/s: Planner/Optimizer
    • Labels:
      None

      Description

      currently Tajo just support COLUMN Partitoner
      but Tajo accept other Partitioner (HASH, LIST, RANGE)
      so users can create table with unsupported Partitioner.
      but tajo will throws NULL Pointer Exception.

      so. until supporting these Partitioner(HASH, LIST, RANGE)
      I think it is better blcok to create table with Partitioner except COLUMN.

      but, they will be supported soon in future.
      I don't remove codes and tests.
      and just block them.

      1. throw exception when creating table with Partitioner except(COLUMN) in logicalPlanner.
      2. just remove @Test clauese from some test cases.
      3. add testcase to check failing create table with hash, list, range partitioner

      I might think this patch give more good experience to users.

      1. TAJO-455.2.patch
        8 kB
        DaeMyung Kang
      2. TAJO-455.patch
        8 kB
        DaeMyung Kang

        Activity

        Hide
        hyunsik Hyunsik Choi added a comment -

        Could you please rebase this patch? The patch gone stale.

        Show
        hyunsik Hyunsik Choi added a comment - Could you please rebase this patch? The patch gone stale.
        Hide
        hyunsik Hyunsik Choi added a comment -

        This is my mistake. My source tree is old one. The patch is applied to the latest revision well.

        Show
        hyunsik Hyunsik Choi added a comment - This is my mistake. My source tree is old one. The patch is applied to the latest revision well.
        Hide
        hyunsik Hyunsik Choi added a comment - - edited

        I like this fix. By the way, wrong format strings are used in this patch.

        792 in LogicalPlanner will cause java.util.IllegalFormatConversionException because the format string is '%d' but PartitionType is an enum type.
        357 in GlobalPlanner will be the same to the above.

        In addition, 792 and 835 lines width in LogicalPlanner exceed 120 column. Could you reformat them?

        Thanks!

        Show
        hyunsik Hyunsik Choi added a comment - - edited I like this fix. By the way, wrong format strings are used in this patch. 792 in LogicalPlanner will cause java.util.IllegalFormatConversionException because the format string is '%d' but PartitionType is an enum type. 357 in GlobalPlanner will be the same to the above. In addition, 792 and 835 lines width in LogicalPlanner exceed 120 column. Could you reformat them? Thanks!
        Hide
        charsyam DaeMyung Kang added a comment -

        Hyunsik Choi Thank you for your review.
        "%d" will cause expection with Enum Class.

        I aligned some lines that you pointed out.
        and changed "%d" to "%s".

        Thank you.

        Show
        charsyam DaeMyung Kang added a comment - Hyunsik Choi Thank you for your review. "%d" will cause expection with Enum Class. I aligned some lines that you pointed out. and changed "%d" to "%s". Thank you.
        Hide
        hyunsik Hyunsik Choi added a comment -

        +1

        I verified 'mvn clean install', and I also tested it with tsql. The fix works well.
        Thank you for the contribution.

        Show
        hyunsik Hyunsik Choi added a comment - +1 I verified 'mvn clean install', and I also tested it with tsql. The fix works well. Thank you for the contribution.
        Hide
        hyunsik Hyunsik Choi added a comment -

        committed it to master.

        Show
        hyunsik Hyunsik Choi added a comment - committed it to master.
        Hide
        hudson Hudson added a comment -

        SUCCESS: Integrated in Tajo-trunk-postcommit #649 (See https://builds.apache.org/job/Tajo-trunk-postcommit/649/)
        TAJO-455: Throw PlanningException when Creating table with Partition exception COLUMN. (DaeMyung Kang via hyunsik) (hyunsik: https://git-wip-us.apache.org/repos/asf?p=incubator-tajo.git&a=commit&h=2a419306a5b90e74b4f9653ce8a439c9e373f389)

        • tajo-core/tajo-core-backend/src/main/java/org/apache/tajo/engine/planner/LogicalPlanner.java
        • CHANGES.txt
        • tajo-core/tajo-core-backend/src/main/java/org/apache/tajo/engine/planner/global/GlobalPlanner.java
        • tajo-core/tajo-core-backend/src/test/java/org/apache/tajo/client/TestTajoClient.java
        Show
        hudson Hudson added a comment - SUCCESS: Integrated in Tajo-trunk-postcommit #649 (See https://builds.apache.org/job/Tajo-trunk-postcommit/649/ ) TAJO-455 : Throw PlanningException when Creating table with Partition exception COLUMN. (DaeMyung Kang via hyunsik) (hyunsik: https://git-wip-us.apache.org/repos/asf?p=incubator-tajo.git&a=commit&h=2a419306a5b90e74b4f9653ce8a439c9e373f389 ) tajo-core/tajo-core-backend/src/main/java/org/apache/tajo/engine/planner/LogicalPlanner.java CHANGES.txt tajo-core/tajo-core-backend/src/main/java/org/apache/tajo/engine/planner/global/GlobalPlanner.java tajo-core/tajo-core-backend/src/test/java/org/apache/tajo/client/TestTajoClient.java

          People

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

            Dates

            • Created:
              Updated:
              Resolved:

              Development