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

Provide default implementation for RowFunction evalDimension method #15452

Merged

Conversation

pagrawal10
Copy link
Contributor

Description

The PR: #13947 introduced a function evalDimension() in the interface RowFunction.
There was no default implementation added for this interface which causes all the implementations and custom transforms to fail and require to implement their own version of evalDimension method. This PR adds a default implementation in the interface which allows the evalDimension to return value as a Singleton array of eval result.

Fixed the bug ...

#13947 is a breaking change for custom transform RowFunction implementations.

Renamed the class ...

None

Added a forbidden-apis entry ...

None

Release note

Default implementation for evalDimension method in RowFunction.


Key changed/added classes in this PR
  • MyFoo
  • OurBar
  • TheirBaz

This PR has:

  • been self-reviewed.
  • added documentation for new or modified features or behaviors.
  • a release note entry in the PR description.
  • added Javadocs for most classes and all non-trivial methods. Linked related entities via Javadoc links.
  • added or updated version, license, or notice information in licenses.yaml
  • added comments explaining the "why" and the intent of the code wherever would not be obvious for an unfamiliar reader.
  • added unit tests or modified existing tests to cover new code paths, ensuring the threshold for code coverage is met.
  • added integration tests.
  • been tested in a test Druid cluster.

Copy link
Contributor

@gianm gianm left a comment

Choose a reason for hiding this comment

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

Sounds OK to me in concept.

@pagrawal10 pagrawal10 requested a review from gianm December 4, 2023 05:20
@Test
public void defaultEvalDimensionTest()
{
Row row = new Row()

Check warning

Code scanning / CodeQL

Inconsistent compareTo Warning test

This class declares
compareTo
but inherits equals; the two could be inconsistent.
@abhishekagarwal87 abhishekagarwal87 merged commit 8505e8a into apache:master Jan 2, 2024
83 checks passed
@LakshSingla LakshSingla added this to the 29.0.0 milestone Jan 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants