Skip to content

feat(util): add ResourceLoader for loading resources from files/streams#4537

Merged
k8s-ci-robot merged 2 commits intokubernetes-client:masterfrom
brendandburns:feat/resource-loader
Feb 2, 2026
Merged

feat(util): add ResourceLoader for loading resources from files/streams#4537
k8s-ci-robot merged 2 commits intokubernetes-client:masterfrom
brendandburns:feat/resource-loader

Conversation

@brendandburns
Copy link
Contributor

Add a utility class that provides fabric8-style resource loading from various sources. Features include:

  • Load from File, InputStream, URL, or String
  • Support for typed loading with Class parameter
  • loadAll() for multi-document YAML files
  • loadAndCreate/loadAndApply/loadAndDelete for direct API operations
  • Automatic pluralization of resource kinds for API paths

Also adds comprehensive unit tests covering all loading methods and multi-document YAML parsing.

Add a utility class that provides fabric8-style resource loading from
various sources. Features include:
- Load from File, InputStream, URL, or String
- Support for typed loading with Class<T> parameter
- loadAll() for multi-document YAML files
- loadAndCreate/loadAndApply/loadAndDelete for direct API operations
- Automatic pluralization of resource kinds for API paths

Also adds comprehensive unit tests covering all loading methods
and multi-document YAML parsing.
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: brendandburns

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot added approved Indicates a PR has been approved by an approver from all required OWNERS files. size/XL Denotes a PR that changes 500-999 lines, ignoring generated files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. labels Jan 21, 2026
@brendandburns brendandburns added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Feb 2, 2026
@brendandburns
Copy link
Contributor Author

Self LGTM due to inactivity.

@k8s-ci-robot k8s-ci-robot merged commit 04f8a73 into kubernetes-client:master Feb 2, 2026
18 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved Indicates a PR has been approved by an approver from all required OWNERS files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. lgtm "Looks good to me", indicates that a PR is ready to be merged. size/XL Denotes a PR that changes 500-999 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants