carbondata-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From gvramana <...@git.apache.org>
Subject [GitHub] carbondata pull request #1178: [WIP]Added tableProvider to supply carbonTabl...
Date Tue, 18 Jul 2017 09:26:57 GMT
Github user gvramana commented on a diff in the pull request:

    https://github.com/apache/carbondata/pull/1178#discussion_r127925159
  
    --- Diff: core/src/main/java/org/apache/carbondata/core/dictionary/generator/IncrementalColumnDictionaryGenerator.java
---
    @@ -113,20 +115,21 @@ public IncrementalColumnDictionaryGenerator(CarbonDimension dimension,
int maxVa
         // initialize params
         CarbonMetadata metadata = CarbonMetadata.getInstance();
         CarbonTable carbonTable = metadata.getCarbonTable(tableUniqueName);
    +    TableProvider tableProvider = new SingleTableProvider(carbonTable);
         CarbonTableIdentifier tableIdentifier = carbonTable.getCarbonTableIdentifier();
         ColumnIdentifier columnIdentifier = dimension.getColumnIdentifier();
         String storePath = carbonTable.getStorePath();
         DictionaryService dictionaryService = CarbonCommonFactory.getDictionaryService();
         // create dictionary cache from dictionary File
         DictionaryColumnUniqueIdentifier identifier =
    -            new DictionaryColumnUniqueIdentifier(tableIdentifier, columnIdentifier,
    -                    columnIdentifier.getDataType());
    +        new DictionaryColumnUniqueIdentifier(tableIdentifier, columnIdentifier,
    +            columnIdentifier.getDataType(), tableProvider);
         Boolean isDictExists = CarbonUtil.isFileExistsForGivenColumn(storePath, identifier);
         Dictionary dictionary = null;
         long t1 = System.currentTimeMillis();
         if (isDictExists) {
    -      Cache<DictionaryColumnUniqueIdentifier, Dictionary> dictCache = CacheProvider.getInstance()
    -              .createCache(CacheType.REVERSE_DICTIONARY, storePath);
    +      Cache<DictionaryColumnUniqueIdentifier, Dictionary> dictCache =
    --- End diff --
    
    Remove all indentation changes


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

Mime
View raw message