You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@druid.apache.org by GitBox <gi...@apache.org> on 2018/08/22 22:45:24 UTC

[GitHub] gianm opened a new pull request #6220: Fix four bugs with numeric dimension output types.

gianm opened a new pull request #6220: Fix four bugs with numeric dimension output types.
URL: https://github.com/apache/incubator-druid/pull/6220
 
 
   This patch includes the following bug fixes:
   
   - TopNColumnSelectorStrategyFactory: Cast dimension values to the output type
     during dimExtractionScanAndAggregate instead of updateDimExtractionResults.
     This fixes a bug where, for example, grouping on doubles-cast-to-longs would
     fail to merge two doubles that should have been combined into the same long value.
   - TopNQueryEngine: Use DimExtractionTopNAlgorithm when treating string columns
     as numeric dimensions. This fixes a similar bug: grouping on string-cast-to-long
     would fail to merge two strings that should have been combined.
   - GroupByQuery: Cast numeric types to the expected output type before comparing them
     in compareDimsForLimitPushDown. This fixes #6123.
   - GroupByQueryQueryToolChest: Convert Jackson-deserialized dimension values into
     the proper output type. This fixes an inconsistency between results that came
     from cache vs. not-cache: for example, Jackson sometimes deserializes integers
     as Integers and sometimes as Longs.
   
   And the following code-cleanup changes, related to the fixes above:
   
   - DimensionHandlerUtils: Introduce convertObjectToType, compareObjectsAsType,
     and converterFromTypeToType to make it easier to handle casting operations.
   - TopN in general: Rename various "dimName" variables to "dimValue" where they
     actually represent dimension values. The old names were confusing.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

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