[ 
https://issues.apache.org/jira/browse/CARBONDATA-30?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15358974#comment-15358974
 ] 

ASF GitHub Bot commented on CARBONDATA-30:
------------------------------------------

Github user ravipesala commented on a diff in the pull request:

    https://github.com/apache/incubator-carbondata/pull/8#discussion_r69299886
  
    --- Diff: 
core/src/main/java/org/carbondata/core/util/CarbonTimeStatisticsUtil.java ---
    @@ -0,0 +1,362 @@
    +/*
    + * Licensed to the Apache Software Foundation (ASF) under one or more
    + * contributor license agreements.  See the NOTICE file distributed with
    + * this work for additional information regarding copyright ownership.
    + * The ASF licenses this file to You under the Apache License, Version 2.0
    + * (the "License"); you may not use this file except in compliance with
    + * the License.  You may obtain a copy of the License at
    + *
    + *    http://www.apache.org/licenses/LICENSE-2.0
    + *
    + * Unless required by applicable law or agreed to in writing, software
    + * distributed under the License is distributed on an "AS IS" BASIS,
    + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    + * See the License for the specific language governing permissions and
    + * limitations under the License.
    + */
    +
    +package org.carbondata.core.util;
    +
    +import java.util.concurrent.ConcurrentHashMap;
    +
    +import org.carbondata.common.logging.LogService;
    +import org.carbondata.common.logging.LogServiceFactory;
    +
    +/**
    + * A util which provide methods used to record time information druing 
data loading.
    + */
    +public class CarbonTimeStatisticsUtil implements 
AbstractTimeStatisticsUtil {
    +  private CarbonTimeStatisticsUtil() {
    +
    +  }
    +
    +  private static CarbonTimeStatisticsUtil carbonTimeStatisticsUtil =
    +          new CarbonTimeStatisticsUtil();
    +
    +  public static  CarbonTimeStatisticsUtil getInstance() {
    +    return carbonTimeStatisticsUtil;
    +  }
    +
    +  private static final LogService LOGGER =
    +          
LogServiceFactory.getLogService(CarbonTimeStatisticsUtil.class.getName());
    +
    +  /*
    +   *We only care about the earliest start time(EST) and the latest end 
time(LET) of different
    +   *threads, who does the same thing, LET - EST is the cost time of doing 
one thing using
    +   *multiple thread.
    + */
    +  private static long loadCsvfilesToDfStartTime = 0;
    --- End diff --
    
    It is singleton class so why used `static` modifier for all variables.


> Record load performance statistics
> ----------------------------------
>
>                 Key: CARBONDATA-30
>                 URL: https://issues.apache.org/jira/browse/CARBONDATA-30
>             Project: CarbonData
>          Issue Type: New Feature
>            Reporter: zhangshunyu
>            Assignee: zhangshunyu
>
> We should use a parameter which can be configured by user to determine 
> whether the statistics will be recorded and calculated during data loading.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to