Skip to content

Document case sensitivity of name fields in API docs#5079

Merged
philippthun merged 1 commit into
cloudfoundry:mainfrom
sap-contributions:document-name-case-sensitivity
May 19, 2026
Merged

Document case sensitivity of name fields in API docs#5079
philippthun merged 1 commit into
cloudfoundry:mainfrom
sap-contributions:document-name-case-sensitivity

Conversation

@philippthun
Copy link
Copy Markdown
Member

The API has inconsistent case sensitivity behavior across resources due to historical schema choices: some name columns use citext (case-insensitive) while others use plain varchar (case-sensitive). This was completely undocumented, causing confusion for API consumers.

Add (case-insensitive) or (case-sensitive) annotations to:

  • Create endpoint name parameters, including uniqueness scope
  • List endpoint name filter parameters
  • Cross-resource name filters (e.g. service_broker_names)

Case-insensitive: apps, organizations, spaces, domains, isolation segments, organization quotas, service plans, service offerings, tasks

Case-sensitive: service instances, buildpacks, stacks, security groups, service brokers, space quotas, service credential bindings

Also remove the misspelled 'case_insenstive' option from three migrations (stacks, lockings, frameworks). The typo meant the option was silently ignored, so these columns were always case-sensitive. Removing the dead option makes the code reflect actual behavior.

  • I have reviewed the contributing guide

  • I have viewed, signed, and submitted the Contributor License Agreement

  • I have made this pull request to the main branch

  • I have run all the unit tests using bundle exec rake

  • I have run CF Acceptance Tests

@philippthun
Copy link
Copy Markdown
Member Author

Backwards Compatibility Tests need this fix: #5085

The API has inconsistent case sensitivity behavior across resources
due to historical schema choices: some name columns use citext
(case-insensitive) while others use plain varchar (case-sensitive).
This was completely undocumented, causing confusion for API consumers.

Add (case-insensitive) or (case-sensitive) annotations to:
- Create endpoint name parameters, including uniqueness scope
- List endpoint name filter parameters
- Cross-resource name filters (e.g. service_broker_names)

Case-insensitive: apps, organizations, spaces, domains, isolation
segments, organization quotas, service plans, service offerings, tasks

Case-sensitive: service instances, buildpacks, stacks, security
groups, service brokers, space quotas, service credential bindings

Also remove the misspelled 'case_insenstive' option from three
migrations (stacks, lockings, frameworks). The typo meant the option
was silently ignored, so these columns were always case-sensitive.
Removing the dead option makes the code reflect actual behavior.
@philippthun philippthun force-pushed the document-name-case-sensitivity branch from 0d9771f to 3d74764 Compare May 5, 2026 08:28
@philippthun philippthun marked this pull request as ready for review May 5, 2026 08:49
@philippthun philippthun merged commit 4e9956d into cloudfoundry:main May 19, 2026
17 checks passed
ari-wg-gitbot added a commit to cloudfoundry/capi-release that referenced this pull request May 19, 2026
Changes in cloud_controller_ng:

- Use have_queried_db_times matcher in lifecycle ordering tests
    PR: cloudfoundry/cloud_controller_ng#5095
    Author: Philipp Thun <philipp.thun@sap.com>

- Fix two flaky test failures caused by test isolation issues
    PR: cloudfoundry/cloud_controller_ng#5084
    Author: Philipp Thun <philipp.thun@sap.com>

- Document case sensitivity of name fields in API docs
    PR: cloudfoundry/cloud_controller_ng#5079
    Author: Philipp Thun <philipp.thun@sap.com>

- Add rubocop cop to prevent model usage in migration specs
    PR: cloudfoundry/cloud_controller_ng#5066
    Author: Philipp Thun <philipp.thun@sap.com>

Dependency updates in cloud_controller_ng:

- build(deps-dev): bump mock_redis from 0.53.0 to 0.54.0
    PR: cloudfoundry/cloud_controller_ng#5106
    Author: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

- build(deps): bump zeitwerk from 2.7.5 to 2.8.0
    PR: cloudfoundry/cloud_controller_ng#5107
    Author: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

- build(deps): bump oj from 3.17.0 to 3.17.1
    PR: cloudfoundry/cloud_controller_ng#5108
    Author: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

- build(deps-dev): bump solargraph from 0.59.0 to 0.59.1
    PR: cloudfoundry/cloud_controller_ng#5109
    Author: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
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.

2 participants