Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upgrade to 31.0.0 ; PRO-1257 #5

Open
wants to merge 4 commits into
base: master
Choose a base branch
from
Open

Conversation

Sybrand
Copy link
Contributor

@Sybrand Sybrand commented Dec 10, 2024

#Overview

Upgrade extension to be compatible with druid 31.0.0

Change in dimensions spec going to 31:

public boolean hasCustomDimensions()
{
   return !(dimensions == null || dimensions.isEmpty());
}

changed to:

public boolean hasFixedDimensions()
{
  return dimensions != null && !dimensions.isEmpty() && !useSchemaDiscovery && !includeAllDimensions;
}

"Rename DimensionsSpec#hasCustomDimensions to hasFixedDimensions and change the meaning subtly: it now
returns true if the DimensionsSpec represents an unchanging list of dimensions, or false if there is
some discovery happening. This is what call sites had expected anyway."

Test

Imported zen data - compared total rows - it matches 29.0.0 and 29.0.1

Copy link

linear bot commented Dec 10, 2024

PRO-1257

    public boolean hasCustomDimensions()
    {
      return !(dimensions == null || dimensions.isEmpty());
    }
    changed to:
    public boolean hasFixedDimensions()
    {
      return dimensions != null && !dimensions.isEmpty() && !useSchemaDiscovery && !includeAllDimensions;
    }
    Rename DimensionsSpec#hasCustomDimensions to hasFixedDimensions and change the meaning subtly: it now
    returns true if the DimensionsSpec represents an unchanging list of dimensions, or false if there is
    some discovery happening. This is what call sites had expected anyway.
@@ -84,7 +84,7 @@ public NestedJSONInputRowParser(
// Maybe assert that pivotSpec's dimension names exist in the
// existing specified dimensions?
Preconditions.checkArgument(
parseSpec.getDimensionsSpec().hasCustomDimensions(),
parseSpec.getDimensionsSpec().hasFixedDimensions(),
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

public boolean hasCustomDimensions()
{
   return !(dimensions == null || dimensions.isEmpty());
}

changed to:

public boolean hasFixedDimensions()
{
  return dimensions != null && !dimensions.isEmpty() && !useSchemaDiscovery && !includeAllDimensions;
}

"Rename DimensionsSpec#hasCustomDimensions to hasFixedDimensions and change the meaning subtly: it now
returns true if the DimensionsSpec represents an unchanging list of dimensions, or false if there is
some discovery happening. This is what call sites had expected anyway."

@Sybrand Sybrand requested a review from AbbyBeeler December 13, 2024 08:59
@Sybrand Sybrand marked this pull request as ready for review December 13, 2024 08:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant