[ 
https://issues.apache.org/jira/browse/GOBBLIN-1035?focusedWorklogId=379149&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-379149
 ]

ASF GitHub Bot logged work on GOBBLIN-1035:
-------------------------------------------

                Author: ASF GitHub Bot
            Created on: 30/Jan/20 04:46
            Start Date: 30/Jan/20 04:46
    Worklog Time Spent: 10m 
      Work Description: sv2000 commented on pull request #2877: [GOBBLIN-1035] 
make hive dataset descriptor accepts regexed db and tables
URL: https://github.com/apache/incubator-gobblin/pull/2877#discussion_r372757716
 
 

 ##########
 File path: 
gobblin-service/src/main/java/org/apache/gobblin/service/modules/dataset/HiveDatasetDescriptor.java
 ##########
 @@ -69,12 +70,21 @@ public HiveDatasetDescriptor(Config config) throws 
IOException {
         .withValue(CONFLICT_POLICY, 
ConfigValueFactory.fromAnyRef(conflictPolicy))
         .withValue(PARTITION_COLUMN, 
ConfigValueFactory.fromAnyRef(partitionColumn))
         .withValue(PARTITION_FORMAT, 
ConfigValueFactory.fromAnyRef(partitionFormat))
-        .withValue(WHITELIST_TABLES, 
ConfigValueFactory.fromAnyRef(createWhitelistedTables())
+        .withValue(HiveDatasetFinder.HIVE_DATASET_PREFIX + "." + 
WhitelistBlacklist.WHITELIST,
+            ConfigValueFactory.fromAnyRef(createWhitelistedTables())
         ));
   }
 
-  private String createWhitelistedTables() {
-    return this.tableName.replace(',', '|');
+  // If the db name contains wildcards, whitelist is created <regex_db>.*
+  // Otherwise, whitelist is created as <db>.tables.
+  // This is the format which HiveDatasetFinder understands.
+  // e.g. db=ei_tracking, table=zephyr*,abook*, whitelist will 
ei_tracking.zephyr*|abook*
+  String createWhitelistedTables() {
 
 Review comment:
   createWhitelistDbTablePattern()? 
 
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Issue Time Tracking
-------------------

    Worklog Id:     (was: 379149)
    Time Spent: 0.5h  (was: 20m)

> make hive dataset descriptor accepts regexed db and tables
> ----------------------------------------------------------
>
>                 Key: GOBBLIN-1035
>                 URL: https://issues.apache.org/jira/browse/GOBBLIN-1035
>             Project: Apache Gobblin
>          Issue Type: Improvement
>            Reporter: Arjun Singh Bora
>            Priority: Major
>          Time Spent: 0.5h
>  Remaining Estimate: 0h
>




--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to