You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pinot.apache.org by si...@apache.org on 2020/05/31 20:44:42 UTC

[incubator-pinot] branch hotfix-0530 updated (f7e1e5c -> 67ab425)

This is an automated email from the ASF dual-hosted git repository.

siddteotia pushed a change to branch hotfix-0530
in repository https://gitbox.apache.org/repos/asf/incubator-pinot.git.


 discard f7e1e5c  Initialize _aggregateMetric in constructor
 discard 7a18f68  Check aggregateMetrics from RealtimeSegmentConfig
     new 67ab425  Initialize _aggregateMetric in constructor

This update added new revisions after undoing existing revisions.
That is to say, some revisions that were in the old version of the
branch are not in the new version.  This situation occurs
when a user --force pushes a change and generates a repository
containing something like this:

 * -- * -- B -- O -- O -- O   (f7e1e5c)
            \
             N -- N -- N   refs/heads/hotfix-0530 (67ab425)

You should already have received notification emails for all of the O
revisions, and so the following emails describe only the N revisions
from the common base, B.

Any revisions marked "omit" are not gone; other references still
refer to them.  Any revisions marked "discard" are gone forever.

The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 .../apache/pinot/core/indexsegment/mutable/MutableSegmentImpl.java  | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org


[incubator-pinot] 01/01: Initialize _aggregateMetric in constructor

Posted by si...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

siddteotia pushed a commit to branch hotfix-0530
in repository https://gitbox.apache.org/repos/asf/incubator-pinot.git

commit 67ab425655c9b95d0a796f105170d9b746b50ea5
Author: Siddharth Teotia <st...@steotia-mn1.linkedin.biz>
AuthorDate: Sat May 30 21:10:30 2020 -0700

    Initialize _aggregateMetric in constructor
---
 .../pinot/core/indexsegment/mutable/MutableSegmentImpl.java      | 9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)

diff --git a/pinot-core/src/main/java/org/apache/pinot/core/indexsegment/mutable/MutableSegmentImpl.java b/pinot-core/src/main/java/org/apache/pinot/core/indexsegment/mutable/MutableSegmentImpl.java
index 0e24664..709fefa 100644
--- a/pinot-core/src/main/java/org/apache/pinot/core/indexsegment/mutable/MutableSegmentImpl.java
+++ b/pinot-core/src/main/java/org/apache/pinot/core/indexsegment/mutable/MutableSegmentImpl.java
@@ -171,6 +171,7 @@ public class MutableSegmentImpl implements MutableSegment {
     _partitionFunction = config.getPartitionFunction();
     _partitionId = config.getPartitionId();
     _nullHandlingEnabled = config.isNullHandlingEnabled();
+    _aggregateMetrics = config.aggregateMetrics();
 
     Collection<FieldSpec> allFieldSpecs = _schema.getAllFieldSpecs();
     List<FieldSpec> physicalFieldSpecs = new ArrayList<>(allFieldSpecs.size());
@@ -219,7 +220,7 @@ public class MutableSegmentImpl implements MutableSegment {
       FieldSpec.DataType dataType = fieldSpec.getDataType();
       boolean isFixedWidthColumn = dataType.isFixedWidth();
       int forwardIndexColumnSize = -1;
-      if (isNoDictionaryColumn(noDictionaryColumns, invertedIndexColumns, fieldSpec, column)) {
+      if (isNoDictionaryColumn(noDictionaryColumns, invertedIndexColumns, fieldSpec, column, config)) {
         // no dictionary
         // each forward index entry will be equal to size of data for that row
         // For INT, LONG, FLOAT, DOUBLE it is equal to the number of fixed bytes used to store the value,
@@ -329,7 +330,7 @@ public class MutableSegmentImpl implements MutableSegment {
    * @return true if column is no-dictionary, false if dictionary encoded
    */
   private boolean isNoDictionaryColumn(Set<String> noDictionaryColumns, Set<String> invertedIndexColumns,
-      FieldSpec fieldSpec, String column) {
+      FieldSpec fieldSpec, String column, RealtimeSegmentConfig config) {
     FieldSpec.DataType dataType = fieldSpec.getDataType();
     if (noDictionaryColumns.contains(column)) {
       // Earlier we didn't support noDict in consuming segments for STRING and BYTES columns.
@@ -344,7 +345,8 @@ public class MutableSegmentImpl implements MutableSegment {
       // if the column is part of noDictionary set from table config
       if (fieldSpec instanceof DimensionFieldSpec && _aggregateMetrics && (dataType == FieldSpec.DataType.STRING ||
           dataType == FieldSpec.DataType.BYTES)) {
-        _logger.info("Not creating dictionary in consuming segment for column {} of type {}", column, dataType.toString());
+        _logger.info("Aggregate metrics is enabled. Will create dictionary in consuming segment for column {} of type {}",
+            column, dataType.toString());
         return false;
       }
       // So don't create dictionary if the column is member of noDictionary, is single-value
@@ -857,7 +859,6 @@ public class MutableSegmentImpl implements MutableSegment {
    */
   private IdMap<FixedIntArray> enableMetricsAggregationIfPossible(RealtimeSegmentConfig config,
       Set<String> noDictionaryColumns) {
-    _aggregateMetrics = config.aggregateMetrics();
     if (!_aggregateMetrics) {
       _logger.info("Metrics aggregation is disabled.");
       return null;


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org