Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: SAP/component-operator-runtime
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: v0.3.82
Choose a base ref
...
head repository: SAP/component-operator-runtime
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: v0.3.83
Choose a head ref
  • 3 commits
  • 12 files changed
  • 4 contributors

Commits on Mar 24, 2025

  1. fix(deps): update non-minor dependencies (#258)

    Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
    renovate[bot] authored Mar 24, 2025

    Verified

    This commit was signed with the committer’s verified signature.
    flavorjones Mike Dalessio
    Copy the full SHA
    c6c69be View commit details

Commits on Mar 25, 2025

  1. Reuse Version update from dep to toml (#259)

    Co-authored-by: ajinkyapatil8190 <ajinkyarangnathpatil@gmail.com>
    sap-ospo-bot and ajinkyapatil8190 authored Mar 25, 2025

    Verified

    This commit was signed with the committer’s verified signature.
    flavorjones Mike Dalessio
    Copy the full SHA
    953b01a View commit details
  2. revisit timeout handling (#254)

    * revisit timeout handling
    
    * cleanup
    
    * cleanup
    
    * comments ...
    
    * tweak backoff, update status on every reconile
    
    * simplify timeout handling
    
    * fix comments
    
    * set Timeout condition in error situations as well
    
    * do not set timeout when deleting
    
    * fix commments
    cbarbian-sap authored Mar 25, 2025

    Verified

    This commit was signed with the committer’s verified signature.
    flavorjones Mike Dalessio
    Copy the full SHA
    ab08dfb View commit details
Showing with 164 additions and 112 deletions.
  1. +0 −29 .reuse/dep5
  2. +11 −0 REUSE.toml
  3. +1 −1 clm/cmd/apply.go
  4. +2 −2 go.mod
  5. +4 −0 go.sum
  6. +8 −9 internal/backoff/backoff.go
  7. +92 −55 pkg/component/reconciler.go
  8. +32 −5 pkg/component/reference.go
  9. +4 −4 pkg/component/target.go
  10. +6 −4 pkg/reconciler/reconciler.go
  11. +1 −1 pkg/reconciler/types.go
  12. +3 −2 pkg/reconciler/util.go
29 changes: 0 additions & 29 deletions .reuse/dep5

This file was deleted.

11 changes: 11 additions & 0 deletions REUSE.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
version = 1
SPDX-PackageName = "component-operator-runtime"
SPDX-PackageSupplier = "SAP_ERP4SME_DevOps@sap.com"
SPDX-PackageDownloadLocation = "https://github.com/sap/component-operator-runtime"
SPDX-PackageComment = "The code in this project may include calls to APIs (\"API Calls\") of\n SAP or third-party products or services developed outside of this project\n (\"External Products\").\n \"APIs\" means application programming interfaces, as well as their respective\n specifications and implementing code that allows software to communicate with\n other software.\n API Calls to External Products are not licensed under the open source license\n that governs this project. The use of such API Calls and related External\n Products are subject to applicable additional agreements with the relevant\n provider of the External Products. In no event shall the open source license\n that governs this project grant any rights in or to any External Products,or\n alter, expand or supersede any terms of the applicable additional agreements.\n If you have a valid license agreement with SAP for the use of a particular SAP\n External Product, then you may make use of any API Calls included in this\n project's code for that SAP External Product, subject to the terms of such\n license agreement. If you do not have a valid license agreement for the use of\n a particular SAP External Product, then you may only make use of any API Calls\n in this project for that SAP External Product for your internal, non-productive\n and non-commercial test and evaluation of such API Calls. Nothing herein grants\n you any rights to use or access any SAP External Product, or provide any third\n parties the right to use of access any SAP External Product, through API Calls."

[[annotations]]
path = "**"
precedence = "aggregate"
SPDX-FileCopyrightText = "2024 SAP SE or an SAP affiliate company and component-operator-runtime contributors"
SPDX-License-Identifier = "Apache-2.0"
2 changes: 1 addition & 1 deletion clm/cmd/apply.go
Original file line number Diff line number Diff line change
@@ -117,7 +117,7 @@ func newApplyCmd() *cobra.Command {

for {
release.State = component.StateProcessing
ok, err := reconciler.Apply(context.TODO(), &release.Inventory, objects, namespace, ownerId, release.Revision)
ok, err := reconciler.Apply(context.TODO(), &release.Inventory, objects, namespace, ownerId, fmt.Sprintf("%d", release.Revision))
if err != nil {
if !isEphmeralError(err) || errCount >= maxErrCount {
return err
4 changes: 2 additions & 2 deletions go.mod
Original file line number Diff line number Diff line change
@@ -11,7 +11,7 @@ require (
github.com/onsi/gomega v1.36.3
github.com/pkg/errors v0.9.1
github.com/prometheus/client_golang v1.21.1
github.com/sap/go-generics v0.2.29
github.com/sap/go-generics v0.2.30
github.com/spf13/cast v1.7.1
github.com/spf13/cobra v1.9.1
github.com/spf13/pflag v1.0.6
@@ -23,7 +23,7 @@ require (
k8s.io/client-go v0.32.3
k8s.io/kube-aggregator v0.32.3
sigs.k8s.io/cli-utils v0.37.2
sigs.k8s.io/controller-runtime v0.20.3
sigs.k8s.io/controller-runtime v0.20.4
sigs.k8s.io/kustomize/api v0.19.0
sigs.k8s.io/kustomize/kyaml v0.19.0
sigs.k8s.io/structured-merge-diff/v4 v4.6.0
4 changes: 4 additions & 0 deletions go.sum
Original file line number Diff line number Diff line change
@@ -153,6 +153,8 @@ github.com/sap/go-generics v0.2.28 h1:Aad95UymJE95s/bpiNemM2FXNWkVMdGkcMrfXizRaI
github.com/sap/go-generics v0.2.28/go.mod h1:yNx3OnTozQTSIXZo/nulcBjew3dYzoB1LfIuRCf1dYE=
github.com/sap/go-generics v0.2.29 h1:LNpgNq9xHSunq1D4+OBASxb55Yj5+xnu/Hg+Eb7FA2k=
github.com/sap/go-generics v0.2.29/go.mod h1:aSmYDdyp2kVjEgjtnkzBqPdtufGojQRoNWgcGD801N4=
github.com/sap/go-generics v0.2.30 h1:9M1q7aPsjq/afcswjEPqe0BiFP0TD0qdWZlwk8pbh/o=
github.com/sap/go-generics v0.2.30/go.mod h1:RahWFdEaztludxH9GOvH8N5kJJkpxTfn93C/o1gXcHE=
github.com/sergi/go-diff v1.2.0 h1:XU+rvMAioB0UC3q1MFrIQy4Vo5/4VsRDQQXHsEya6xQ=
github.com/sergi/go-diff v1.2.0/go.mod h1:STckp+ISIX8hZLjrqAeVduY0gWCT9IjLuqbuNXdaHfM=
github.com/shopspring/decimal v1.4.0 h1:bxl37RwXBklmTi0C79JfXCEBD1cqqHt0bbgBAGFp81k=
@@ -306,6 +308,8 @@ sigs.k8s.io/controller-runtime v0.20.2 h1:/439OZVxoEc02psi1h4QO3bHzTgu49bb347Xp4
sigs.k8s.io/controller-runtime v0.20.2/go.mod h1:xg2XB0K5ShQzAgsoujxuKN4LNXR2LfwwHsPj7Iaw+XY=
sigs.k8s.io/controller-runtime v0.20.3 h1:I6Ln8JfQjHH7JbtCD2HCYHoIzajoRxPNuvhvcDbZgkI=
sigs.k8s.io/controller-runtime v0.20.3/go.mod h1:xg2XB0K5ShQzAgsoujxuKN4LNXR2LfwwHsPj7Iaw+XY=
sigs.k8s.io/controller-runtime v0.20.4 h1:X3c+Odnxz+iPTRobG4tp092+CvBU9UK0t/bRf+n0DGU=
sigs.k8s.io/controller-runtime v0.20.4/go.mod h1:xg2XB0K5ShQzAgsoujxuKN4LNXR2LfwwHsPj7Iaw+XY=
sigs.k8s.io/json v0.0.0-20241010143419-9aa6b5e7a4b3 h1:/Rv+M11QRah1itp8VhT6HoVx1Ray9eB4DBr+K+/sCJ8=
sigs.k8s.io/json v0.0.0-20241010143419-9aa6b5e7a4b3/go.mod h1:18nIHnGi6636UCz6m8i4DhaJ65T6EruyzmoQqI2BVDo=
sigs.k8s.io/kustomize/api v0.19.0 h1:F+2HB2mU1MSiR9Hp1NEgoU2q9ItNOaBJl0I4Dlus5SQ=
17 changes: 8 additions & 9 deletions internal/backoff/backoff.go
Original file line number Diff line number Diff line change
@@ -22,16 +22,15 @@ type Backoff struct {
func NewBackoff(maxDelay time.Duration) *Backoff {
return &Backoff{
activities: make(map[any]any),
// resulting per-item backoff is the maximum of a 200-times-50ms-then-maxDelay per-item limiter,
// and an overall 5-per-second-burst-20 bucket limiter;
// as a consequence, we have up to
// - up to 20 almost immediate retries
// - then then a phase of 5 guaranteed retries per seconnd (could be more if burst capacity is refilled
// because of the duration of the reconcile logic execution itself)
// - finally (after 200 iterations) slow retries at the rate given by maxDelay
// resulting per-item backoff is the maximum of a 120-times-100ms-then-maxDelay per-item limiter,
// and an overall 1-per-second-burst-50 bucket limiter;
// as a consequence, we have
// - a phase of 10 retries per second for the first 5 seconds
// - then a phase of 1 retry per second for the next 60 seconds
// - finally slow retries at the rate given by maxDelay
limiter: workqueue.NewMaxOfRateLimiter(
workqueue.NewItemFastSlowRateLimiter(50*time.Millisecond, maxDelay, 200),
&workqueue.BucketRateLimiter{Limiter: rate.NewLimiter(rate.Limit(5), 20)},
workqueue.NewItemFastSlowRateLimiter(100*time.Millisecond, maxDelay, 120),
&workqueue.BucketRateLimiter{Limiter: rate.NewLimiter(rate.Limit(1), 50)},
),
}
}
Loading