Skip to content

Comments

GH-49356: [C++] Remove deprecated APIs from v13.0.0 and v18.0.0#49171

Merged
kou merged 1 commit intoapache:mainfrom
AliRana30:remove-decimal-deprecation
Feb 21, 2026
Merged

GH-49356: [C++] Remove deprecated APIs from v13.0.0 and v18.0.0#49171
kou merged 1 commit intoapache:mainfrom
AliRana30:remove-decimal-deprecation

Conversation

@AliRana30
Copy link
Contributor

@AliRana30 AliRana30 commented Feb 7, 2026

Rationale for This Change

This PR removes C++ APIs that have been deprecated for more than one year, in line with Arrow's deprecation and cleanup policy. All removed APIs were deprecated before January 1, 2025.


What Changes Are Included in This PR?

This PR removes 3 deprecated C++ APIs:

1. decimal(precision, scale) function

2. cuda::DefaultMemoryMapper(device_type, device_id) function

3. HasValidityBitmap(Type::type id) global function


Are These Changes Tested?

Yes. Verified via full codebase search that all removed symbols have zero remaining usages in the C++ codebase.


Are There Any User-Facing Changes?

Yes. Downstream C++ consumers using these deprecated APIs will need to migrate to the replacement APIs listed above.


@github-actions
Copy link

github-actions bot commented Feb 7, 2026

⚠️ GitHub issue #49153 has been automatically assigned in GitHub to PR creator.

@rok
Copy link
Member

rok commented Feb 7, 2026

This PR looks ok, however test looks AI generated so I checked the statement. It turns out decimal was not deprecated "over 6 years ago" but rather in November 2024 when 18.1.0 was released. PR for deprecation was merged on 4th September 2024.

Since I don't want to search for every claim you make here, please do the following:

  • expand this PR to all C++ symbols you want to deprecate and rename it appropriately
  • provide PR links where deprecation notice was given (per symbol) and the release where this commit was then released
  • Manually check which release happened a year ago and only remove symbols with deprecation notices for releases equal of less than the year old release

e.g.:

  • decimal was deprecated on 4th September 2024 which was a part of 18.1.0 (November 2024).

@AliRana30
Copy link
Contributor Author

AliRana30 commented Feb 8, 2026

@rok You're absolutely right about the dates. I apologize - decimal() was deprecated in September 2024 (only 4 months ago), not "over 6 years ago" as I mistakenly claimed.

I'll commit the changes with properly verified deprecations >1 year old (before 2025) with PR links and release dates as you requested.

Note : There's no option for renaming the PR , should I close this and create a new one):

@AliRana30 AliRana30 closed this Feb 8, 2026
@AliRana30 AliRana30 reopened this Feb 8, 2026
@rok
Copy link
Member

rok commented Feb 8, 2026

@AliRana30 you can rename the PR - there is an edit button at the top right of the page.

@AliRana30 AliRana30 force-pushed the remove-decimal-deprecation branch from 031fe14 to 474f7c4 Compare February 18, 2026 20:07
@AliRana30 AliRana30 requested a review from lidavidm as a code owner February 18, 2026 20:07
@AliRana30 AliRana30 changed the title GH-49153: [C++] Remove deprecated decimal() factory function GH-49153: [C++] Remove deprecated APIs from v13.0.0 and v18.0.0 Feb 18, 2026
@AliRana30 AliRana30 force-pushed the remove-decimal-deprecation branch from b95061c to e49383d Compare February 18, 2026 20:13
@AliRana30 AliRana30 force-pushed the remove-decimal-deprecation branch 2 times, most recently from e91ef90 to ded7299 Compare February 18, 2026 21:54
@AliRana30 AliRana30 force-pushed the remove-decimal-deprecation branch from 73d9533 to 678b8bd Compare February 19, 2026 09:23
"flight_sql:extension",
description="Ensure Flight SQL extensions work as expected.",
skip_testers={"Rust", ".NET"}
skip_testers={"Rust", ".NET", "C++"}
Copy link
Member

Choose a reason for hiding this comment

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

Why do we need this?

Copy link
Contributor Author

@AliRana30 AliRana30 Feb 19, 2026

Choose a reason for hiding this comment

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

The flight_sql:extension scenario tests the CancelQuery action, which this PR removes from C++ (it was deprecated in v13.0.0, August 2023).

C++ now uses [CancelFlightInfo] instead, which is the replacement API. However, other languages (Java, Go) still implement the old CancelQuery action.

Without this skip, the integration tests fail with:
"Action not implemented: CancelQuery rpc error: code = Unimplemented desc = Action not implemented: CancelQuery"

Since C++ no longer supports the deprecated CancelQuery action being tested in this scenario, it needs to be skipped from cross-language testing for this specific scenario.

Copy link
Member

Choose a reason for hiding this comment

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

Can we update the Java and Go implementations instead of skipping C++ tests? If we skip the C++ implementation, non CancelQuery tests are also skipped, right?

Copy link
Contributor Author

@AliRana30 AliRana30 Feb 20, 2026

Choose a reason for hiding this comment

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

You're right - skipping C++ would skip all extension tests, not just CancelQuery.

Looking at the code, the C++ integration test already uses [CancelFlightInfo] (the replacement API). The failures were happening because the integration test servers in Java/Go still expect the CancelQuery action.

Would you prefer:

**1.**I remove CancelQuery from Java/Go integration test servers as well (they also deprecated it), OR
**2.**I keep the C++ skip for now, and we can remove CancelQuery from all languages in a coordinated PR?

Option 1 would make this PR more complete, but touches Java/Go code beyond just C++.

Copy link
Member

Choose a reason for hiding this comment

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

Option 1 is better.
We need to work on https://github.com/apache/arrow-java for Java and https://github.com/apache/arrow-go for Go.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Got it. Since Java and Go are in separate repos, should I:

1.Wait for those to be merged
2.Then update this PR to remove the C++ skip

Or would you prefer to keep the C++ skip in this PR for now, with a TODO comment that it can be removed once arrow-java and arrow-go are updated?

Copy link
Member

Choose a reason for hiding this comment

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

We should create the PRs to remove CancelQuery on Arrow Java and Arrow Go and hold this PR until this is done. Skipping the whole flight sql integration tests could introduce integration issues without us noticing. You could also split the deprecation of CancelQuery to a follow up PR until the other PRs are merged (possibly add a TODO explaining why it can't be deprecated yet) and just push the other deprecation removals. Both approaches seem reasonable.

Copy link
Member

Choose a reason for hiding this comment

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

1.Wait for those to be merged

Are there already PRs in apache/arrow-java and apache/arrow-go to migrate to CancelFlightInfo from CancelQuery?

If you want to complete this PR as soon as possible, I prefer the following step:

  1. Remove CancelQuery related change from this PR
  2. Merge this PR
  3. Open a PR to apache/arrow-java to migrate to CancelFlightInfo from CancelQuery
  4. Merge the PR
  5. Open a PR to apache/arrow-go to migrate to CancelFlightInfo from CancelQuery
  6. Merge the PR
  7. Open a separated PR to this repository to migrate to CancelFlightInfo from CancelQuery
  8. Merge the PR

If you don't mind this PR keeps opening, I prefer the following step:

  1. Open a PR to apache/arrow-java to migrate to CancelFlightInfo from CancelQuery
  2. Merge the PR
  3. Open a PR to apache/arrow-go to migrate to CancelFlightInfo from CancelQuery
  4. Merge the PR
  5. Remove the C++ skip from this PR
  6. Merge this PR

Copy link
Member

Choose a reason for hiding this comment

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

(Wow. Raúl also said the same approaches. :-)

Copy link
Contributor Author

@AliRana30 AliRana30 Feb 20, 2026

Choose a reason for hiding this comment

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

Thanks for the guidance! I'll go with option of removing CancelQuery from this PR to get the other deprecations merged faster. Because this PR is purely for only those deprecations that are linked with C++ only.

I'll remove the CancelQuery changes and revert the integration test skip until this PR , so it gets merged and does'nt create mess of the tests and changes.

@github-actions github-actions bot added awaiting changes Awaiting changes and removed awaiting review Awaiting review labels Feb 19, 2026
@AliRana30 AliRana30 requested a review from kou February 19, 2026 12:04
@AliRana30 AliRana30 force-pushed the remove-decimal-deprecation branch from 678b8bd to 01d94dd Compare February 20, 2026 17:21
@github-actions github-actions bot added awaiting change review Awaiting change review and removed Component: FlightRPC awaiting changes Awaiting changes labels Feb 20, 2026
@kou kou added the CI: Extra: CUDA Run extra CUDA CI label Feb 21, 2026
@kou
Copy link
Member

kou commented Feb 21, 2026

Could you open a new issue for the CancelQuery work?

Could you update the PR description?

@kou
Copy link
Member

kou commented Feb 21, 2026

BTW, does this cover GH-49153 entirely? If this focuses only some parts of GH-49153, we should open a new issue for this instead of using GH-49153. If we merge this PR that is associated with GH-49153, GH-49153 will be closed.

@AliRana30
Copy link
Contributor Author

AliRana30 commented Feb 21, 2026

@kou I've made the following changes:

  1. Created a new issue [C++] Remove deprecated APIs from v16-v18 releases #49356 specifically for these 3 C++ API removals
  2. Updated this PR to reference [C++] Remove deprecated APIs from v16-v18 releases #49356 instead of [C++][Python] Act on existing deprecations #49153
  3. Removed all CancelQuery-related changes from this PR (will create a separate issue for that cross-repo work)
  4. Updated the PR description

This PR now focuses only on:

  • decimal() function (v18.0.0)
  • cuda::DefaultMemoryMapper() (v16.0.0)
  • HasValidityBitmap() global function (v17.0.0)

Remove 3 deprecated C++ APIs:
- decimal() function (v18.0.0, PR apache#43957)
- cuda::DefaultMemoryMapper() (v16.0.0, PR apache#40699)
- HasValidityBitmap() global function (v17.0.0, PR apache#41115)

All deprecated before 2025.
@AliRana30 AliRana30 force-pushed the remove-decimal-deprecation branch from 01d94dd to 68262e8 Compare February 21, 2026 11:34
@kou kou changed the title GH-49153: [C++] Remove deprecated APIs from v13.0.0 and v18.0.0 GH-49356: [C++] Remove deprecated APIs from v13.0.0 and v18.0.0 Feb 21, 2026
@github-actions
Copy link

⚠️ GitHub issue #49356 has been automatically assigned in GitHub to PR creator.

@github-actions
Copy link

⚠️ GitHub issue #49356 has no components, please add labels for components.

Copy link
Member

@kou kou left a comment

Choose a reason for hiding this comment

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

+1

@github-actions github-actions bot added awaiting merge Awaiting merge and removed awaiting change review Awaiting change review labels Feb 21, 2026
@kou kou merged commit 8c27898 into apache:main Feb 21, 2026
62 of 66 checks passed
@kou kou removed the awaiting merge Awaiting merge label Feb 21, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants