[GitHub] incubator-carbondata pull request #310: [CARBONDATA-401] One Pass Load

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

[GitHub] incubator-carbondata pull request #310: [CARBONDATA-401] One Pass Load

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

    https://github.com/apache/incubator-carbondata/pull/310#discussion_r92760541
 
    --- Diff: processing/src/main/java/org/apache/carbondata/processing/newflow/converter/impl/RowConverterImpl.java ---
    @@ -73,10 +79,39 @@ public void initialize() {
     
         long lruCacheStartTime = System.currentTimeMillis();
     
    +    // for one pass load, start the dictionary client
    +    if (configuration.getUseOnePass()) {
    +      executorService = Executors.newFixedThreadPool(1);
    +      Future<DictionaryClient> result = executorService.submit(new Callable<DictionaryClient>() {
    +        @Override
    +        public DictionaryClient call() throws Exception {
    +          Thread.currentThread().setName("Dictionary client");
    +          DictionaryClient dictionaryClient = new DictionaryClient();
    +          dictionaryClient.startClient(configuration.getDictionaryServerHost(),
    +                  configuration.getDictionaryServerPort());
    +          return dictionaryClient;
    +        }
    +      });
    +
    +      try {
    +        Thread.sleep(1000);
    --- End diff --
   
    Why sleep 1 second? please add comment


---
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 [hidden email] or file a JIRA ticket
with INFRA.
---