Skip to content

refactor: remove support for Greenplum - #1722

Closed
jeskepetr wants to merge 1 commit into
gooddata:masterfrom
jeskepetr:PJE/F1-2435
Closed

refactor: remove support for Greenplum#1722
jeskepetr wants to merge 1 commit into
gooddata:masterfrom
jeskepetr:PJE/F1-2435

Conversation

@jeskepetr

@jeskepetr jeskepetr commented Aug 7, 2026

Copy link
Copy Markdown
Contributor

Summary

Greenplum is no longer used by any customer and is being removed from the backend (F1-2435, gdc-nas #25474), so the SDK no longer needs to model it.

Hand-written SDK

  • Removed CatalogDataSourceGreenplum and GreenplumAttributes and their exports from gooddata_sdk.
  • Removed the Greenplum example from the data-source docs.
  • Removed the Greenplum test. It was already inert — the whole function sat inside a """ block, and the greenplum.yaml cassette it referenced does not exist in the repo.

Generated client — updated the supported way, not by hand:

  • Dropped the GREENPLUM enum entry from the two source schemas it originates from, gooddata-metadata-client.json and gooddata-scan-client.json.
  • Regenerated gooddata-api-client/ with openapi-generator against the merged schema.

The regeneration produced exactly six deletions and no other drift, which incidentally confirms the checked-in client was in sync with its schemas.

A note on jq

schemas/gooddata-api-client.json was edited line-wise rather than rebuilt through the Makefile's cat | jq -S -s merge step.

jq 1.6 does not preserve number literals and rewrote unrelated values across the file — 2.6E+92600000000, 1.01, 100.0100. The checked-in copy was clearly produced with jq 1.7+, which does preserve them. The line-wise edit yields exactly what the merge would produce on jq 1.7, without the collateral churn.

Worth knowing for anyone regenerating: run make api-client with jq 1.7+, or you will commit spurious numeric diffs.

Test Plan

  • Pre-commit hooks pass on the change: ruff (lint), ruff format, copyright, trailing whitespace, EOF.
  • All three edited Python files compile.
  • Repo-wide sweep for greenplum (case-insensitive) returns zero hits; nothing else in the repo imported either removed class.
  • Both edited source schemas and the merged schema validate as JSON.
  • openapi-generator ran clean; the resulting diff is 6 deletions of a single enum line each, with no untracked or deleted files.

Not run: the test suite. The local toolchain could not run it — uv 0.10.7 against the repo's ~=0.11.0 pin, and the repo venv is missing gooddata_code_convertors. I confirmed that failure reproduces on a clean tree, so it predates this change, but it does mean CI is the first real execution of these tests.

Risk

Low in effect, but note this is a breaking change for a published package: anyone with from gooddata_sdk import CatalogDataSourceGreenplum (or GreenplumAttributes) gets an ImportError on upgrade — at import time, even in code that never connects to Greenplum.

Since nobody is using the datasource type, no working code should construct these. But if this repo prefers a deprecation cycle for public symbols, the alternative is to keep both names as deprecated shims now and remove them in the next major. Happy to switch to that if reviewers prefer.

test_allowed_data_source_type iterates the generated JsonApiDataSourceInAttributes.allowed_values and constructs the generic CatalogDataSource, so it is unaffected by the subclass removal and simply stops seeing GREENPLUM.

Ordering

This can land independently of the backend PR. Until gdc-nas ships, the deployed backend still accepts GREENPLUM; afterwards it will not. Nothing here depends on deploy order.

🤖 Generated with Claude Code

Summary by CodeRabbit

  • Breaking Changes
    • Removed Greenplum as a supported data source type across API clients, SDK models, and metadata schemas.
    • Greenplum-specific SDK data source classes and public exports are no longer available.
  • Documentation
    • Removed the Greenplum data source example from the documentation.
  • Tests
    • Removed obsolete Greenplum data source test coverage.

Greenplum is no longer used by any customer and is being removed from the
backend (F1-2435), so the SDK no longer needs to model it.

Drops the hand-written `CatalogDataSourceGreenplum` and `GreenplumAttributes`
classes, their exports from `gooddata_sdk`, and the Greenplum example from the
data-source docs. The Greenplum test went with them: it was already inert,
sitting inside a `"""` block and referencing a `greenplum.yaml` cassette that
does not exist in the repo.

The generated client was updated the supported way rather than by hand. The
`GREENPLUM` enum entry was removed from the two source schemas it originates
from -- gooddata-metadata-client.json and gooddata-scan-client.json -- and
`gooddata-api-client/` was then regenerated with openapi-generator against the
merged schema. The regeneration produced exactly six deletions and no other
drift, which also confirms the checked-in client was in sync with the schemas.

The merged schemas/gooddata-api-client.json was edited line-wise instead of
being rebuilt through the Makefile's `jq -S -s` step. jq 1.6 does not preserve
number literals and rewrote unrelated values (2.6E+9 -> 2600000000, 1.0 -> 1)
across the file; the checked-in copy was produced with jq 1.7+, which does.

This is a breaking change for anyone importing either class by name, including
code that never connects to Greenplum, since the failure is at import time.

JIRA: F1-2435
risk: low

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
@coderabbitai

coderabbitai Bot commented Aug 7, 2026

Copy link
Copy Markdown

Review Change Stack

📝 Walkthrough

Walkthrough

The change removes GREENPLUM from API and metadata schemas, SDK models, package exports, tests, and documentation. Greenplum-specific SDK classes and examples are deleted.

Changes

Greenplum support removal

Layer / File(s) Summary
Database type contracts
gooddata-api-client/gooddata_api_client/model/*, schemas/gooddata-api-client.json, schemas/gooddata-metadata-client.json, schemas/gooddata-scan-client.json
The GREENPLUM value is removed from database-type enumerations.
SDK entity and export removal
packages/gooddata-sdk/src/gooddata_sdk/catalog/data_source/entity_model/data_source.py, packages/gooddata-sdk/src/gooddata_sdk/__init__.py, packages/gooddata-sdk/tests/catalog/test_catalog_data_source.py
Greenplum-specific SDK classes, exports, and the commented test block are removed.
Documentation cleanup
docs/content/en/latest/data/data-source/_index.md
The Greenplum data source example is removed.

Estimated code review effort: 2 (Simple) | ~10 minutes

Poem

I nibbled old Greenplum away,
From schemas and SDK paths today.
The enums now agree,
The docs are debris,
And clean exports hop into play.

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly and concisely describes the primary change: removing Greenplum support from the SDK, schemas, and documentation.

Comment @coderabbitai help to get the list of available commands.

@jeskepetr jeskepetr added the do not merge Do not merge this yet label Aug 7, 2026
@codecov

codecov Bot commented Aug 7, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 78.58%. Comparing base (cbd27a1) to head (60e8b58).

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #1722      +/-   ##
==========================================
- Coverage   78.59%   78.58%   -0.01%     
==========================================
  Files         271      271              
  Lines       18772    18765       -7     
==========================================
- Hits        14754    14747       -7     
  Misses       4018     4018              

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@jeskepetr

Copy link
Copy Markdown
Contributor Author

Superseded by #1723, which runs the same commit from a branch in this repository instead of my fork.

The netlify-deploy check here failed with Refusing to check out fork pull request code from a 'pull_request_target' workflow — an actions/checkout security guard that fires for any fork PR, unrelated to these changes. Reopening from an in-repo branch so the docs preview can build, which matters here since this PR edits the data-source docs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

do not merge Do not merge this yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant