[GitHub] carbondata pull request #2352: [CARBONDATA-2555]Fixed SDK reader set default...

classic Classic list List threaded Threaded
24 messages Options
12
Reply | Threaded
Open this post in threaded view
|

[GitHub] carbondata pull request #2352: [CARBONDATA-2555]Fixed SDK reader set default...

qiuchenjian-2
Github user ajantha-bhat commented on a diff in the pull request:

    https://github.com/apache/carbondata/pull/2352#discussion_r191690950
 
    --- Diff: store/sdk/src/test/java/org/apache/carbondata/sdk/file/CarbonReaderTest.java ---
    @@ -305,7 +309,7 @@ public void testWriteAndReadFilesNonTransactional() throws IOException, Interrup
         // Write to a Non Transactional Table
         TestUtil.writeFilesAndVerify(new Schema(fields), path, true, false);
     
    -    CarbonReader reader = CarbonReader.builder(path, "_temp")
    +    CarbonReader reader = CarbonReader.builder(path, "_temp").isTransactionalTable(true)
    --- End diff --
   
    This came by conflict resolve. This will be removed in the next commit. No harm.


---
Reply | Threaded
Open this post in threaded view
|

[GitHub] carbondata pull request #2352: [CARBONDATA-2555]Fixed SDK reader set default...

qiuchenjian-2
In reply to this post by qiuchenjian-2
Github user ajantha-bhat commented on a diff in the pull request:

    https://github.com/apache/carbondata/pull/2352#discussion_r191691253
 
    --- Diff: store/sdk/src/test/java/org/apache/carbondata/sdk/file/CarbonReaderTest.java ---
    @@ -305,7 +309,7 @@ public void testWriteAndReadFilesNonTransactional() throws IOException, Interrup
         // Write to a Non Transactional Table
         TestUtil.writeFilesAndVerify(new Schema(fields), path, true, false);
     
    -    CarbonReader reader = CarbonReader.builder(path, "_temp")
    +    CarbonReader reader = CarbonReader.builder(path, "_temp").isTransactionalTable(true)
    --- End diff --
   
    This is a conflict resolve problem. Will be removed in the next commit.  Finally it should be false for this testcase


---
Reply | Threaded
Open this post in threaded view
|

[GitHub] carbondata pull request #2352: [CARBONDATA-2555]Fixed SDK reader set default...

qiuchenjian-2
In reply to this post by qiuchenjian-2
Github user xubo245 commented on a diff in the pull request:

    https://github.com/apache/carbondata/pull/2352#discussion_r191695582
 
    --- Diff: examples/spark2/src/main/java/org/apache/carbondata/examples/sdk/SDKS3Example.java ---
    @@ -44,34 +44,14 @@ public static void main(String[] args) throws Exception {
                 num = Integer.parseInt(args[4]);
             }
     
    -        Boolean persistSchema = true;
    -        if (args.length > 5) {
    -            if (args[5].equalsIgnoreCase("true")) {
    -                persistSchema = true;
    -            } else {
    -                persistSchema = false;
    -            }
    -        }
    -
    -        Boolean transactionalTable = true;
    -        if (args.length > 6) {
    -            if (args[6].equalsIgnoreCase("true")) {
    -                transactionalTable = true;
    -            } else {
    -                transactionalTable = false;
    -            }
    -        }
    -
             Field[] fields = new Field[2];
             fields[0] = new Field("name", DataTypes.STRING);
             fields[1] = new Field("age", DataTypes.INT);
             CarbonWriterBuilder builder = CarbonWriter.builder()
                     .setAccessKey(args[0])
                     .setSecretKey(args[1])
                     .setEndPoint(args[2])
    -                .outputPath(path)
    -                .persistSchemaFile(persistSchema)
    -                .isTransactionalTable(transactionalTable);
    --- End diff --
   
    remove this one , this example can't change  value of isTransactionalTable and persistSchemaFile when we test it.  I suggest it better to keep it.


---
Reply | Threaded
Open this post in threaded view
|

[GitHub] carbondata pull request #2352: [CARBONDATA-2555]Fixed SDK reader set default...

qiuchenjian-2
In reply to this post by qiuchenjian-2
Github user xubo245 commented on a diff in the pull request:

    https://github.com/apache/carbondata/pull/2352#discussion_r191695689
 
    --- Diff: store/sdk/src/test/java/org/apache/carbondata/sdk/file/CarbonReaderTest.java ---
    @@ -305,7 +309,7 @@ public void testWriteAndReadFilesNonTransactional() throws IOException, Interrup
         // Write to a Non Transactional Table
         TestUtil.writeFilesAndVerify(new Schema(fields), path, true, false);
     
    -    CarbonReader reader = CarbonReader.builder(path, "_temp")
    +    CarbonReader reader = CarbonReader.builder(path, "_temp").isTransactionalTable(true)
    --- End diff --
   
    ok, It's fine.


---
12