You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@carbondata.apache.org by xuchuanyin <gi...@git.apache.org> on 2018/04/23 09:39:15 UTC

[GitHub] carbondata pull request #2211: [CARBONDATA-2380][DataMap] Support visible/in...

GitHub user xuchuanyin opened a pull request:

    https://github.com/apache/carbondata/pull/2211

    [CARBONDATA-2380][DataMap] Support visible/invisible datamap for performance tuning

    Support making datamap visible/invisible through session env.
    Invisible datamap will only be ignored during query and user can still
    see this datmap and its data will be updated as normal.
    We can specify a datamap as invisible by
    'set carbon.datamap.invisible.dbName.tableName.dataMapName=false' and it
    is only effective in this session.
    
    Be sure to do all of the following checklist to help us incorporate 
    your contribution quickly and easily:
    
     - [x] Any interfaces changed?
     `Add internal interface for getting visible datamaps`
     - [x] Any backward compatibility impacted?
     `NO`
     - [x] Document update required?
     `NO`
     - [x] Testing done
            Please provide details on 
            - Whether new unit test cases have been added or why no new tests are required?
    `Test added`
            - How it is tested? Please attach test report.
    `Tested in local`
            - Is it a performance related change? Please attach the performance test report.
    `No`
            - Any additional information to help reviewers in testing this change.
           
     - [x] For large changes, please consider breaking it into sub-tasks under an umbrella JIRA. 
    `Not related`


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

    $ git pull https://github.com/xuchuanyin/carbondata 0423_invisible_datamap

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

    https://github.com/apache/carbondata/pull/2211.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 #2211
    
----
commit 88342ff4d370fa4f7e4809637f5977b3032e3c03
Author: xuchuanyin <xu...@...>
Date:   2018-04-23T09:30:47Z

    Support visible/invisible datamap for performance tuning
    
    Support making datamap visible/invisible through session env.
    Invisible datamap will only be ignored during query and user can still
    see this datmap and its data will be updated as normal.
    We can specify a datamap as invisible by
    'set carbon.datamap.invisible.dbName.tableName.dataMapName=false' and it
    is only effective in this session.

----


---

[GitHub] carbondata pull request #2211: [CARBONDATA-2380][DataMap] Support visible/in...

Posted by asfgit <gi...@git.apache.org>.
Github user asfgit closed the pull request at:

    https://github.com/apache/carbondata/pull/2211


---

[GitHub] carbondata pull request #2211: [CARBONDATA-2380][DataMap] Support visible/in...

Posted by xuchuanyin <gi...@git.apache.org>.
Github user xuchuanyin commented on a diff in the pull request:

    https://github.com/apache/carbondata/pull/2211#discussion_r184031116
  
    --- Diff: core/src/main/java/org/apache/carbondata/core/datamap/DataMapStoreManager.java ---
    @@ -92,6 +95,30 @@ private DataMapStoreManager() {
         return dataMaps;
       }
     
    +  /**
    +   * It only gives the visible datamaps
    +   */
    +  private List<TableDataMap> getAllVisibleDataMap(CarbonTable carbonTable) throws IOException {
    +    CarbonSessionInfo sessionInfo = ThreadLocalSessionInfo.getCarbonSessionInfo();
    +    List<TableDataMap> allDataMaps = getAllDataMap(carbonTable);
    +    Iterator<TableDataMap> dataMapIterator = allDataMaps.iterator();
    +    while (dataMapIterator.hasNext()) {
    +      TableDataMap dataMap = dataMapIterator.next();
    +      String dbName = carbonTable.getDatabaseName();
    +      String tableName = carbonTable.getTableName();
    +      String dmName = dataMap.getDataMapSchema().getDataMapName();
    +      boolean isDmVisible = sessionInfo.getSessionParams().getProperty(
    +          String.format("%s%s.%s.%s", CarbonCommonConstants.CARBON_DATAMAP_VISIBLE,
    --- End diff --
    
    @kumarvishal09 It
    1. won't work on carbondata default datamap, such as DefaultBlockletDataMap/PreAggregate/Timeseries, 
    2. and will work for extened datamaps, such as LuceneDataMap/BloomDataMap
    
    The reason is that the visibility of datamap is done during blocklet pruning, it seems  PreAggregate/Timeseries won't arrive there and DefaultBlockletDataMap will always come to effective.


---

[GitHub] carbondata issue #2211: [CARBONDATA-2380][DataMap] Support visible/invisible...

Posted by xuchuanyin <gi...@git.apache.org>.
Github user xuchuanyin commented on the issue:

    https://github.com/apache/carbondata/pull/2211
  
    retest this please


---

[GitHub] carbondata issue #2211: [CARBONDATA-2380][DataMap] Support visible/invisible...

Posted by CarbonDataQA <gi...@git.apache.org>.
Github user CarbonDataQA commented on the issue:

    https://github.com/apache/carbondata/pull/2211
  
    Build Success with Spark 2.2.1, Please check CI http://88.99.58.216:8080/job/ApacheCarbonPRBuilder/4182/



---

[GitHub] carbondata pull request #2211: [CARBONDATA-2380][DataMap] Support visible/in...

Posted by jackylk <gi...@git.apache.org>.
Github user jackylk commented on a diff in the pull request:

    https://github.com/apache/carbondata/pull/2211#discussion_r183372467
  
    --- Diff: core/src/main/java/org/apache/carbondata/core/datamap/DataMapStoreManager.java ---
    @@ -92,6 +95,30 @@ private DataMapStoreManager() {
         return dataMaps;
       }
     
    +  /**
    +   * It only gives the visible datamaps
    +   */
    +  private List<TableDataMap> getAllVisibleDataMap(CarbonTable carbonTable) throws IOException {
    +    CarbonSessionInfo sessionInfo = ThreadLocalSessionInfo.getCarbonSessionInfo();
    +    List<TableDataMap> allDataMaps = getAllDataMap(carbonTable);
    +    Iterator<TableDataMap> dataMapIterator = allDataMaps.iterator();
    +    while (dataMapIterator.hasNext()) {
    +      TableDataMap dataMap = dataMapIterator.next();
    +      String dbName = carbonTable.getDatabaseName();
    +      String tableName = carbonTable.getTableName();
    +      String dmName = dataMap.getDataMapSchema().getDataMapName();
    +      boolean isDmVisible = sessionInfo.getSessionParams().getProperty(
    +          String.format("%s%s.%s.%s", CarbonCommonConstants.CARBON_DATAMAP_VISIBLE,
    --- End diff --
    
    And I think it is better to provide a statement for Disabling the datamap instead of a set command 


---

[GitHub] carbondata pull request #2211: [CARBONDATA-2380][DataMap] Support visible/in...

Posted by xuchuanyin <gi...@git.apache.org>.
Github user xuchuanyin commented on a diff in the pull request:

    https://github.com/apache/carbondata/pull/2211#discussion_r189502015
  
    --- Diff: integration/spark-common-test/src/test/scala/org/apache/carbondata/spark/testsuite/datamap/CGDataMapTestCase.scala ---
    @@ -383,6 +384,39 @@ class CGDataMapTestCase extends QueryTest with BeforeAndAfterAll {
           sql("select * from normal_test where name='n502670' and city='c2670'"))
       }
     
    +  test("test invisible datamap during query") {
    --- End diff --
    
    What's your proposal?
    The invisible datamap is a temporary status for a datamap. It indicates that the query will not use the datamap for now.
    See Line404 for usage.


---

[GitHub] carbondata issue #2211: [CARBONDATA-2380][DataMap] Support visible/invisible...

Posted by CarbonDataQA <gi...@git.apache.org>.
Github user CarbonDataQA commented on the issue:

    https://github.com/apache/carbondata/pull/2211
  
    Build Failed  with Spark 2.1.0, Please check CI http://136.243.101.176:8080/job/ApacheCarbonPRBuilder1/5328/



---

[GitHub] carbondata pull request #2211: [CARBONDATA-2380][DataMap] Support visible/in...

Posted by xuchuanyin <gi...@git.apache.org>.
Github user xuchuanyin commented on a diff in the pull request:

    https://github.com/apache/carbondata/pull/2211#discussion_r183375720
  
    --- Diff: core/src/main/java/org/apache/carbondata/core/datamap/DataMapStoreManager.java ---
    @@ -92,6 +95,30 @@ private DataMapStoreManager() {
         return dataMaps;
       }
     
    +  /**
    +   * It only gives the visible datamaps
    +   */
    +  private List<TableDataMap> getAllVisibleDataMap(CarbonTable carbonTable) throws IOException {
    +    CarbonSessionInfo sessionInfo = ThreadLocalSessionInfo.getCarbonSessionInfo();
    +    List<TableDataMap> allDataMaps = getAllDataMap(carbonTable);
    +    Iterator<TableDataMap> dataMapIterator = allDataMaps.iterator();
    +    while (dataMapIterator.hasNext()) {
    +      TableDataMap dataMap = dataMapIterator.next();
    +      String dbName = carbonTable.getDatabaseName();
    +      String tableName = carbonTable.getTableName();
    +      String dmName = dataMap.getDataMapSchema().getDataMapName();
    +      boolean isDmVisible = sessionInfo.getSessionParams().getProperty(
    +          String.format("%s%s.%s.%s", CarbonCommonConstants.CARBON_DATAMAP_VISIBLE,
    --- End diff --
    
    It's not going to disable the datamap forever. It is only intend to see how this datamap will enhance performance during the query.
    As described in PR description, "Invisible datamap will only be ignored during query and user can still see this datmap and its data will be updated as normal."
    
    It is named after MySQL document, and have the similar function as it. Please refer "MySQL now supports invisible indexes" in this link: https://dev.mysql.com/doc/refman/8.0/en/mysql-nutshell.html


---

[GitHub] carbondata issue #2211: [CARBONDATA-2380][DataMap] Support visible/invisible...

Posted by ravipesala <gi...@git.apache.org>.
Github user ravipesala commented on the issue:

    https://github.com/apache/carbondata/pull/2211
  
    SDV Build Fail , Please check CI http://144.76.159.231:8080/job/ApacheSDVTests/4474/



---

[GitHub] carbondata pull request #2211: [CARBONDATA-2380][DataMap] Support visible/in...

Posted by xuchuanyin <gi...@git.apache.org>.
Github user xuchuanyin commented on a diff in the pull request:

    https://github.com/apache/carbondata/pull/2211#discussion_r183378864
  
    --- Diff: core/src/main/java/org/apache/carbondata/core/datamap/DataMapStoreManager.java ---
    @@ -92,6 +95,30 @@ private DataMapStoreManager() {
         return dataMaps;
       }
     
    +  /**
    +   * It only gives the visible datamaps
    +   */
    +  private List<TableDataMap> getAllVisibleDataMap(CarbonTable carbonTable) throws IOException {
    +    CarbonSessionInfo sessionInfo = ThreadLocalSessionInfo.getCarbonSessionInfo();
    +    List<TableDataMap> allDataMaps = getAllDataMap(carbonTable);
    +    Iterator<TableDataMap> dataMapIterator = allDataMaps.iterator();
    +    while (dataMapIterator.hasNext()) {
    +      TableDataMap dataMap = dataMapIterator.next();
    +      String dbName = carbonTable.getDatabaseName();
    +      String tableName = carbonTable.getTableName();
    +      String dmName = dataMap.getDataMapSchema().getDataMapName();
    +      boolean isDmVisible = sessionInfo.getSessionParams().getProperty(
    +          String.format("%s%s.%s.%s", CarbonCommonConstants.CARBON_DATAMAP_VISIBLE,
    --- End diff --
    
    Having a statement to do this means that we need to store the related information.
    
    I also have considered to  store the visible/invisible information in DataMapSchema/DataMapStatus related, but found that currently there is no place other than file to store them.
    
    Besides, this feature is introduced for tuning, which means the status may change frequently. Having a file stored information may need frequently refresh & read the DataMapSchemaFile.
    
    By using a set command here, we don't have to make the information durable. It meets our needs and can be implemented easily.
    
    @jackylk How do you think about it?


---

[GitHub] carbondata pull request #2211: [CARBONDATA-2380][DataMap] Support visible/in...

Posted by xuchuanyin <gi...@git.apache.org>.
Github user xuchuanyin commented on a diff in the pull request:

    https://github.com/apache/carbondata/pull/2211#discussion_r189502270
  
    --- Diff: integration/spark-common-test/src/test/scala/org/apache/carbondata/spark/testsuite/datamap/CGDataMapTestCase.scala ---
    @@ -383,6 +384,39 @@ class CGDataMapTestCase extends QueryTest with BeforeAndAfterAll {
           sql("select * from normal_test where name='n502670' and city='c2670'"))
       }
     
    +  test("test invisible datamap during query") {
    --- End diff --
    
    There is no need to add a performance report here.
    You can explain the query before/after change the visibility of the datamap, the output should be different.


---

[GitHub] carbondata pull request #2211: [CARBONDATA-2380][DataMap] Support visible/in...

Posted by xubo245 <gi...@git.apache.org>.
Github user xubo245 commented on a diff in the pull request:

    https://github.com/apache/carbondata/pull/2211#discussion_r189502836
  
    --- Diff: integration/spark-common-test/src/test/scala/org/apache/carbondata/spark/testsuite/datamap/CGDataMapTestCase.scala ---
    @@ -383,6 +384,39 @@ class CGDataMapTestCase extends QueryTest with BeforeAndAfterAll {
           sql("select * from normal_test where name='n502670' and city='c2670'"))
       }
     
    +  test("test invisible datamap during query") {
    --- End diff --
    
    I think we should add some validate in test case, which ensure the function correct.


---

[GitHub] carbondata pull request #2211: [CARBONDATA-2380][DataMap] Support visible/in...

Posted by jackylk <gi...@git.apache.org>.
Github user jackylk commented on a diff in the pull request:

    https://github.com/apache/carbondata/pull/2211#discussion_r183376339
  
    --- Diff: core/src/main/java/org/apache/carbondata/core/datamap/DataMapStoreManager.java ---
    @@ -92,6 +95,30 @@ private DataMapStoreManager() {
         return dataMaps;
       }
     
    +  /**
    +   * It only gives the visible datamaps
    +   */
    +  private List<TableDataMap> getAllVisibleDataMap(CarbonTable carbonTable) throws IOException {
    +    CarbonSessionInfo sessionInfo = ThreadLocalSessionInfo.getCarbonSessionInfo();
    +    List<TableDataMap> allDataMaps = getAllDataMap(carbonTable);
    +    Iterator<TableDataMap> dataMapIterator = allDataMaps.iterator();
    +    while (dataMapIterator.hasNext()) {
    +      TableDataMap dataMap = dataMapIterator.next();
    +      String dbName = carbonTable.getDatabaseName();
    +      String tableName = carbonTable.getTableName();
    +      String dmName = dataMap.getDataMapSchema().getDataMapName();
    +      boolean isDmVisible = sessionInfo.getSessionParams().getProperty(
    +          String.format("%s%s.%s.%s", CarbonCommonConstants.CARBON_DATAMAP_VISIBLE,
    --- End diff --
    
    ok, so you mean this is temporary only? Not needed to persist it, right?


---

[GitHub] carbondata issue #2211: [CARBONDATA-2380][DataMap] Support visible/invisible...

Posted by CarbonDataQA <gi...@git.apache.org>.
Github user CarbonDataQA commented on the issue:

    https://github.com/apache/carbondata/pull/2211
  
    Build Failed  with Spark 2.1.0, Please check CI http://136.243.101.176:8080/job/ApacheCarbonPRBuilder1/5351/



---

[GitHub] carbondata issue #2211: [CARBONDATA-2380][DataMap] Support visible/invisible...

Posted by CarbonDataQA <gi...@git.apache.org>.
Github user CarbonDataQA commented on the issue:

    https://github.com/apache/carbondata/pull/2211
  
    Build Success with Spark 2.1.0, Please check CI http://136.243.101.176:8080/job/ApacheCarbonPRBuilder1/5394/



---

[GitHub] carbondata pull request #2211: [CARBONDATA-2380][DataMap] Support visible/in...

Posted by xuchuanyin <gi...@git.apache.org>.
Github user xuchuanyin commented on a diff in the pull request:

    https://github.com/apache/carbondata/pull/2211#discussion_r183411036
  
    --- Diff: core/src/main/java/org/apache/carbondata/core/datamap/DataMapStoreManager.java ---
    @@ -92,6 +95,30 @@ private DataMapStoreManager() {
         return dataMaps;
       }
     
    +  /**
    +   * It only gives the visible datamaps
    +   */
    +  private List<TableDataMap> getAllVisibleDataMap(CarbonTable carbonTable) throws IOException {
    +    CarbonSessionInfo sessionInfo = ThreadLocalSessionInfo.getCarbonSessionInfo();
    +    List<TableDataMap> allDataMaps = getAllDataMap(carbonTable);
    +    Iterator<TableDataMap> dataMapIterator = allDataMaps.iterator();
    +    while (dataMapIterator.hasNext()) {
    +      TableDataMap dataMap = dataMapIterator.next();
    +      String dbName = carbonTable.getDatabaseName();
    +      String tableName = carbonTable.getTableName();
    +      String dmName = dataMap.getDataMapSchema().getDataMapName();
    +      boolean isDmVisible = sessionInfo.getSessionParams().getProperty(
    +          String.format("%s%s.%s.%s", CarbonCommonConstants.CARBON_DATAMAP_VISIBLE,
    --- End diff --
    
    yes, it is temporary, no need to persist it.


---

[GitHub] carbondata issue #2211: [CARBONDATA-2380][DataMap] Support visible/invisible...

Posted by xuchuanyin <gi...@git.apache.org>.
Github user xuchuanyin commented on the issue:

    https://github.com/apache/carbondata/pull/2211
  
    @jackylk All reviews are resolved


---

[GitHub] carbondata pull request #2211: [CARBONDATA-2380][DataMap] Support visible/in...

Posted by xuchuanyin <gi...@git.apache.org>.
Github user xuchuanyin commented on a diff in the pull request:

    https://github.com/apache/carbondata/pull/2211#discussion_r189557032
  
    --- Diff: integration/spark-common-test/src/test/scala/org/apache/carbondata/spark/testsuite/datamap/CGDataMapTestCase.scala ---
    @@ -383,6 +384,39 @@ class CGDataMapTestCase extends QueryTest with BeforeAndAfterAll {
           sql("select * from normal_test where name='n502670' and city='c2670'"))
       }
     
    +  test("test invisible datamap during query") {
    --- End diff --
    
    @xubo245 Will you work on it or just raise a jira?


---

[GitHub] carbondata issue #2211: [CARBONDATA-2380][DataMap] Support visible/invisible...

Posted by jackylk <gi...@git.apache.org>.
Github user jackylk commented on the issue:

    https://github.com/apache/carbondata/pull/2211
  
    LGTM


---

[GitHub] carbondata pull request #2211: [CARBONDATA-2380][DataMap] Support visible/in...

Posted by xuchuanyin <gi...@git.apache.org>.
Github user xuchuanyin commented on a diff in the pull request:

    https://github.com/apache/carbondata/pull/2211#discussion_r189556850
  
    --- Diff: integration/spark-common-test/src/test/scala/org/apache/carbondata/spark/testsuite/datamap/CGDataMapTestCase.scala ---
    @@ -383,6 +384,39 @@ class CGDataMapTestCase extends QueryTest with BeforeAndAfterAll {
           sql("select * from normal_test where name='n502670' and city='c2670'"))
       }
     
    +  test("test invisible datamap during query") {
    --- End diff --
    
    Yes. We can validate it by validating the output of explain.


---

[GitHub] carbondata issue #2211: [CARBONDATA-2380][DataMap] Support visible/invisible...

Posted by xuchuanyin <gi...@git.apache.org>.
Github user xuchuanyin commented on the issue:

    https://github.com/apache/carbondata/pull/2211
  
    retest this please


---

[GitHub] carbondata pull request #2211: [CARBONDATA-2380][DataMap] Support visible/in...

Posted by kumarvishal09 <gi...@git.apache.org>.
Github user kumarvishal09 commented on a diff in the pull request:

    https://github.com/apache/carbondata/pull/2211#discussion_r183828839
  
    --- Diff: core/src/main/java/org/apache/carbondata/core/datamap/DataMapStoreManager.java ---
    @@ -92,6 +95,30 @@ private DataMapStoreManager() {
         return dataMaps;
       }
     
    +  /**
    +   * It only gives the visible datamaps
    +   */
    +  private List<TableDataMap> getAllVisibleDataMap(CarbonTable carbonTable) throws IOException {
    +    CarbonSessionInfo sessionInfo = ThreadLocalSessionInfo.getCarbonSessionInfo();
    +    List<TableDataMap> allDataMaps = getAllDataMap(carbonTable);
    +    Iterator<TableDataMap> dataMapIterator = allDataMaps.iterator();
    +    while (dataMapIterator.hasNext()) {
    +      TableDataMap dataMap = dataMapIterator.next();
    +      String dbName = carbonTable.getDatabaseName();
    +      String tableName = carbonTable.getTableName();
    +      String dmName = dataMap.getDataMapSchema().getDataMapName();
    +      boolean isDmVisible = sessionInfo.getSessionParams().getProperty(
    +          String.format("%s%s.%s.%s", CarbonCommonConstants.CARBON_DATAMAP_VISIBLE,
    --- End diff --
    
    @xuchuanyin It is applicable for all type of data maps like pre aggregate, timeseries, etc??


---

[GitHub] carbondata pull request #2211: [CARBONDATA-2380][DataMap] Support visible/in...

Posted by xubo245 <gi...@git.apache.org>.
Github user xubo245 commented on a diff in the pull request:

    https://github.com/apache/carbondata/pull/2211#discussion_r189491069
  
    --- Diff: integration/spark-common-test/src/test/scala/org/apache/carbondata/spark/testsuite/datamap/CGDataMapTestCase.scala ---
    @@ -383,6 +384,39 @@ class CGDataMapTestCase extends QueryTest with BeforeAndAfterAll {
           sql("select * from normal_test where name='n502670' and city='c2670'"))
       }
     
    +  test("test invisible datamap during query") {
    --- End diff --
    
    This test case shouldn't test the invisible/visible table directly, can you add some test case for checking invisible/visible table? Are there any performance report for this?


---

[GitHub] carbondata issue #2211: [CARBONDATA-2380][DataMap] Support visible/invisible...

Posted by CarbonDataQA <gi...@git.apache.org>.
Github user CarbonDataQA commented on the issue:

    https://github.com/apache/carbondata/pull/2211
  
    Build Success with Spark 2.2.1, Please check CI http://88.99.58.216:8080/job/ApacheCarbonPRBuilder/4163/



---

[GitHub] carbondata pull request #2211: [CARBONDATA-2380][DataMap] Support visible/in...

Posted by jackylk <gi...@git.apache.org>.
Github user jackylk commented on a diff in the pull request:

    https://github.com/apache/carbondata/pull/2211#discussion_r183372282
  
    --- Diff: core/src/main/java/org/apache/carbondata/core/datamap/DataMapStoreManager.java ---
    @@ -92,6 +95,30 @@ private DataMapStoreManager() {
         return dataMaps;
       }
     
    +  /**
    +   * It only gives the visible datamaps
    +   */
    +  private List<TableDataMap> getAllVisibleDataMap(CarbonTable carbonTable) throws IOException {
    +    CarbonSessionInfo sessionInfo = ThreadLocalSessionInfo.getCarbonSessionInfo();
    +    List<TableDataMap> allDataMaps = getAllDataMap(carbonTable);
    +    Iterator<TableDataMap> dataMapIterator = allDataMaps.iterator();
    +    while (dataMapIterator.hasNext()) {
    +      TableDataMap dataMap = dataMapIterator.next();
    +      String dbName = carbonTable.getDatabaseName();
    +      String tableName = carbonTable.getTableName();
    +      String dmName = dataMap.getDataMapSchema().getDataMapName();
    +      boolean isDmVisible = sessionInfo.getSessionParams().getProperty(
    +          String.format("%s%s.%s.%s", CarbonCommonConstants.CARBON_DATAMAP_VISIBLE,
    --- End diff --
    
    Are you intend to make FG Datamap invisible? If yes, better to persistent this state by setting DataMapStatus in DataMapStatusDetail. 


---

[GitHub] carbondata issue #2211: [CARBONDATA-2380][DataMap] Support visible/invisible...

Posted by CarbonDataQA <gi...@git.apache.org>.
Github user CarbonDataQA commented on the issue:

    https://github.com/apache/carbondata/pull/2211
  
    Build Success with Spark 2.2.1, Please check CI http://88.99.58.216:8080/job/ApacheCarbonPRBuilder/4227/



---

[GitHub] carbondata pull request #2211: [CARBONDATA-2380][DataMap] Support visible/in...

Posted by jackylk <gi...@git.apache.org>.
Github user jackylk commented on a diff in the pull request:

    https://github.com/apache/carbondata/pull/2211#discussion_r183604504
  
    --- Diff: core/src/main/java/org/apache/carbondata/core/datamap/DataMapStoreManager.java ---
    @@ -92,6 +95,30 @@ private DataMapStoreManager() {
         return dataMaps;
       }
     
    +  /**
    +   * It only gives the visible datamaps
    +   */
    +  private List<TableDataMap> getAllVisibleDataMap(CarbonTable carbonTable) throws IOException {
    +    CarbonSessionInfo sessionInfo = ThreadLocalSessionInfo.getCarbonSessionInfo();
    +    List<TableDataMap> allDataMaps = getAllDataMap(carbonTable);
    +    Iterator<TableDataMap> dataMapIterator = allDataMaps.iterator();
    +    while (dataMapIterator.hasNext()) {
    +      TableDataMap dataMap = dataMapIterator.next();
    +      String dbName = carbonTable.getDatabaseName();
    +      String tableName = carbonTable.getTableName();
    +      String dmName = dataMap.getDataMapSchema().getDataMapName();
    +      boolean isDmVisible = sessionInfo.getSessionParams().getProperty(
    +          String.format("%s%s.%s.%s", CarbonCommonConstants.CARBON_DATAMAP_VISIBLE,
    --- End diff --
    
    I think it is ok, please add a @InterfaceStability.Unstable to the property key you have introduced


---

[GitHub] carbondata issue #2211: [CARBONDATA-2380][DataMap] Support visible/invisible...

Posted by ravipesala <gi...@git.apache.org>.
Github user ravipesala commented on the issue:

    https://github.com/apache/carbondata/pull/2211
  
    SDV Build Success , Please check CI http://144.76.159.231:8080/job/ApacheSDVTests/4533/



---