Skip to content

fix: resourcerepository interface cascade#1727

Merged
matthiasbruns merged 9 commits into
open-component-model:mainfrom
matthiasbruns:fix/oci_repository_interface_mismatch
Feb 5, 2026
Merged

fix: resourcerepository interface cascade#1727
matthiasbruns merged 9 commits into
open-component-model:mainfrom
matthiasbruns:fix/oci_repository_interface_mismatch

Conversation

@matthiasbruns

@matthiasbruns matthiasbruns commented Feb 5, 2026

Copy link
Copy Markdown
Contributor

What this PR does / why we need it

Follow up from #1718

We forgot to add

UploadResource(ctx context.Context, res *descriptor.Resource, content blob.ReadOnlyBlob, credentials map[string]string) (*descriptor.Resource, error)

to the bindings/go/oci/repository/resource/resource_repository.go implementation.

Which issue(s) this PR fixes

Contributes: open-component-model/ocm-project#796

@matthiasbruns matthiasbruns requested a review from a team as a code owner February 5, 2026 08:48
Comment thread bindings/go/oci/repository/resource/resource_repository.go Outdated
Comment thread bindings/go/oci/repository/resource/resource_repository.go Outdated
On-behalf-of: SAP <matthias.bruns@sap.com>
Signed-off-by: Matthias Bruns <git@matthiasbruns.com>
On-behalf-of: SAP <matthias.bruns@sap.com>
Signed-off-by: Matthias Bruns <git@matthiasbruns.com>
On-behalf-of: SAP <matthias.bruns@sap.com>
Signed-off-by: Matthias Bruns <git@matthiasbruns.com>
On-behalf-of: SAP <matthias.bruns@sap.com>
Signed-off-by: Matthias Bruns <git@matthiasbruns.com>
On-behalf-of: SAP <matthias.bruns@sap.com>
Signed-off-by: Matthias Bruns <git@matthiasbruns.com>
@matthiasbruns matthiasbruns force-pushed the fix/oci_repository_interface_mismatch branch from a490eb2 to 7d198ef Compare February 5, 2026 13:28
On-behalf-of: SAP <matthias.bruns@sap.com>
Signed-off-by: Matthias Bruns <git@matthiasbruns.com>
On-behalf-of: SAP <matthias.bruns@sap.com>
Signed-off-by: Matthias Bruns <git@matthiasbruns.com>
@matthiasbruns matthiasbruns force-pushed the fix/oci_repository_interface_mismatch branch from 2357d82 to ae23e35 Compare February 5, 2026 14:26
On-behalf-of: SAP <matthias.bruns@sap.com>
Signed-off-by: Matthias Bruns <git@matthiasbruns.com>
@matthiasbruns matthiasbruns force-pushed the fix/oci_repository_interface_mismatch branch from ae23e35 to d605848 Compare February 5, 2026 14:27
@matthiasbruns matthiasbruns enabled auto-merge (squash) February 5, 2026 14:32
@matthiasbruns matthiasbruns merged commit 1725a07 into open-component-model:main Feb 5, 2026
18 checks passed
@matthiasbruns matthiasbruns deleted the fix/oci_repository_interface_mismatch branch February 5, 2026 15:51
matthiasbruns added a commit that referenced this pull request Feb 13, 2026
<!-- markdownlint-disable MD041 -->
#### What this PR does / why we need it
This PR ties all the changes related to
open-component-model/ocm-project#796 together
in the cli package and implement oci transfer with tests.
It also adds two new flags, which were taken from old ocm
https://ocm.software/docs/reference/ocm-cli/transfer/componentversions/

- `FlagCopyResources      = "copy-resources"`

in addition, I've added an integration test, that:
- creates two oci registries
- uploads one artifact to the first registry
- creates a cv pointing to the artifact
- calls:

```go
transferCMD.SetArgs([]string{
		"transfer",
		"component-version",
		sourceRef,
		targetRef,
		"--config", cfgPath,
		"--copy-resources", // required, otherwise we wouldn't transfer oci artifacts
	})
```
- verifies, that the oci artifact is in the 2nd registry

#### Which issue(s) this PR fixes
Contributes:
open-component-model/ocm-project#796

Split PRs:
- #1730
- #1751
- #1736
- #1727
- #1718
- #1717

---------

Signed-off-by: Matthias Bruns <git@matthiasbruns.com>
Signed-off-by: Matthias Bruns <github@matthiasbruns.com>
Signed-off-by: Fabian Burth <fabian.burth@sap.com>
Co-authored-by: Fabian Burth <fabian.burth@sap.com>
morri-son pushed a commit to morri-son/open-component-model that referenced this pull request Feb 16, 2026
<!-- markdownlint-disable MD041 -->
#### What this PR does / why we need it
This PR ties all the changes related to
open-component-model/ocm-project#796 together
in the cli package and implement oci transfer with tests.
It also adds two new flags, which were taken from old ocm
https://ocm.software/docs/reference/ocm-cli/transfer/componentversions/

- `FlagCopyResources      = "copy-resources"`

in addition, I've added an integration test, that:
- creates two oci registries
- uploads one artifact to the first registry
- creates a cv pointing to the artifact
- calls:

```go
transferCMD.SetArgs([]string{
		"transfer",
		"component-version",
		sourceRef,
		targetRef,
		"--config", cfgPath,
		"--copy-resources", // required, otherwise we wouldn't transfer oci artifacts
	})
```
- verifies, that the oci artifact is in the 2nd registry

#### Which issue(s) this PR fixes
Contributes:
open-component-model/ocm-project#796

Split PRs:
- open-component-model#1730
- open-component-model#1751
- open-component-model#1736
- open-component-model#1727
- open-component-model#1718
- open-component-model#1717

---------

Signed-off-by: Matthias Bruns <git@matthiasbruns.com>
Signed-off-by: Matthias Bruns <github@matthiasbruns.com>
Signed-off-by: Fabian Burth <fabian.burth@sap.com>
Co-authored-by: Fabian Burth <fabian.burth@sap.com>
morri-son pushed a commit to morri-son/open-component-model that referenced this pull request Feb 18, 2026
<!-- markdownlint-disable MD041 -->
#### What this PR does / why we need it
This PR ties all the changes related to
open-component-model/ocm-project#796 together
in the cli package and implement oci transfer with tests.
It also adds two new flags, which were taken from old ocm
https://ocm.software/docs/reference/ocm-cli/transfer/componentversions/

- `FlagCopyResources      = "copy-resources"`

in addition, I've added an integration test, that:
- creates two oci registries
- uploads one artifact to the first registry
- creates a cv pointing to the artifact
- calls:

```go
transferCMD.SetArgs([]string{
		"transfer",
		"component-version",
		sourceRef,
		targetRef,
		"--config", cfgPath,
		"--copy-resources", // required, otherwise we wouldn't transfer oci artifacts
	})
```
- verifies, that the oci artifact is in the 2nd registry

#### Which issue(s) this PR fixes
Contributes:
open-component-model/ocm-project#796

Split PRs:
- open-component-model#1730
- open-component-model#1751
- open-component-model#1736
- open-component-model#1727
- open-component-model#1718
- open-component-model#1717

---------

Signed-off-by: Matthias Bruns <git@matthiasbruns.com>
Signed-off-by: Matthias Bruns <github@matthiasbruns.com>
Signed-off-by: Fabian Burth <fabian.burth@sap.com>
Co-authored-by: Fabian Burth <fabian.burth@sap.com>
Signed-off-by: Gerald Morrison (SAP) <gerald.morrison@sap.com>
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.

3 participants