Skip to content

feat: add / get local blob transformers#1654

Merged
jakobmoellerdev merged 9 commits into
open-component-model:mainfrom
jakobmoellerdev:add-get-localblob
Jan 27, 2026
Merged

feat: add / get local blob transformers#1654
jakobmoellerdev merged 9 commits into
open-component-model:mainfrom
jakobmoellerdev:add-get-localblob

Conversation

@jakobmoellerdev

@jakobmoellerdev jakobmoellerdev commented Jan 23, 2026

Copy link
Copy Markdown
Member

What this PR does / why we need it

creates AddLocalBlob / GetLocalBlob transformation variants for OCI / CTF

Which issue(s) this PR fixes

creates the transformers in OCI required for local blob transformations.
add / get for now based on file buffers. copy op coming up separately

NOTE: blocked until blob module is released 0.0.11 released

part of open-component-model/ocm-project#795

@github-actions github-actions Bot added size/l Large kind/feature new feature, enhancement, improvement, extension labels Jan 23, 2026
Signed-off-by: Jakob Möller <contact@jakob-moeller.com>
Signed-off-by: Jakob Möller <jakob.moeller@sap.com>
makes sure that the generators we run dont clash by being sequential. a bit slower, but shouldnt hurt too much

Signed-off-by: Jakob Möller <jakob.moeller@sap.com>
Signed-off-by: Jakob Möller <jakob.moeller@sap.com>
### What was done
- Updated the error message during artifact access conversion to provide clearer context about the failure with local blob access.
- Adjusted a related test case to match the refined error message.

### Why
Improves error clarity for developers by providing actionable insights into invalid conversions.

Signed-off-by: Jakob Möller <jakob.moeller@sap.com>
@jakobmoellerdev jakobmoellerdev marked this pull request as ready for review January 26, 2026 05:56
@jakobmoellerdev jakobmoellerdev requested a review from a team as a code owner January 26, 2026 05:56
Comment thread bindings/go/oci/transformer/add_local_resource.go
Comment thread bindings/go/oci/transformer/add_local_resource.go
Comment thread bindings/go/oci/transformer/get_local_resource.go

@fabianburth fabianburth left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Looks good! go mod still needs an update, right?

Comment thread bindings/go/oci/internal/pack/pack.go Outdated
Comment thread bindings/go/oci/spec/transformation/v1alpha1/ctf_add_local_resource.go Outdated
Comment thread bindings/go/oci/spec/transformation/v1alpha1/ctf_get_local_resource.go Outdated
Comment thread bindings/go/oci/transformer/add_local_resource.go Outdated
Comment thread bindings/go/oci/transformer/add_local_resource_test.go Outdated
jakobmoellerdev and others added 2 commits January 27, 2026 10:18
…dependency

### What was done
- Replaced `v0.0.11-0.20260123164636-4d10ccc182e4` with the stable `v0.0.11` version of `ocm.software/open-component-model/bindings/go/blob`.
- Updated dependency references in `bindings/go/oci/integration` and `bindings/go/oci`.

### Why
Ensures stability and consistency by locking the dependency to a stable release version.

Signed-off-by: Jakob Möller <jakob.moeller@sap.com>
…tions

### What was done
- Updated `ArtifactBlob` function signature to improve type clarity.
- Refined error message for missing file URI to give more descriptive guidance.
- Enforced `ID` field as required in multiple transformation specs (`CTFAddLocalResource`, `CTFGetLocalResource`, `OCIAddLocalResource`, `OCIGetLocalResource`).
- Removed unused methods in `mockRepository` for cleaner and more maintainable tests.

### Why
- Enhances developer experience with clearer error messages and stricter validation.
- Simplifies codebase by eliminating unused mocks, ensuring the focus is on relevant functionality.
- Enforces consistency across transformation specifications, aligning with intended schema design.

Co-authored-by: Fabian Burth <fabian.burth@sap.com>
Signed-off-by: Jakob Möller <jakob.moeller@sap.com>
@jakobmoellerdev jakobmoellerdev merged commit 96b7457 into open-component-model:main Jan 27, 2026
19 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

kind/feature new feature, enhancement, improvement, extension size/l Large

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants