carbondata-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ravipesala <...@git.apache.org>
Subject [GitHub] carbondata pull request #1099: [CARBONDATA-1232] Datamap implementation for ...
Date Fri, 07 Jul 2017 08:03:41 GMT
Github user ravipesala commented on a diff in the pull request:

    https://github.com/apache/carbondata/pull/1099#discussion_r126090143
  
    --- Diff: core/src/main/java/org/apache/carbondata/core/indexstore/DataMapStoreManager.java
---
    @@ -69,20 +70,20 @@ public TableDataMap getDataMap(AbsoluteTableIdentifier identifier,
String dataMa
        * @param mapType
        * @return
        */
    -  public TableDataMap createTableDataMap(AbsoluteTableIdentifier identifier, DataMapType
mapType,
    -      String dataMapName) {
    -    Map<String, TableDataMap> map = dataMapMappping.get(mapType);
    +  public AbstractTableDataMap createTableDataMap(AbsoluteTableIdentifier identifier,
    +      DataMapType mapType, String dataMapName) {
    +    Map<String, AbstractTableDataMap> map = dataMapMappping.get(mapType);
         if (map == null) {
           map = new HashMap<>();
           dataMapMappping.put(mapType, map);
         }
    -    TableDataMap dataMap = map.get(dataMapName);
    +    AbstractTableDataMap dataMap = map.get(dataMapName);
         if (dataMap != null) {
           throw new RuntimeException("Already datamap exists in that path with type " + mapType);
         }
     
         try {
    -      //TODO create datamap using @mapType.getClassName())
    +      dataMap = (AbstractTableDataMap) (Class.forName(mapType.getClassName()).newInstance());
         } catch (Exception e) {
           LOGGER.error(e);
    --- End diff --
    
    ok


---
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