Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cannot upgrade from 1.8.x to 1.9.0-SNAPSHOT #3063

Closed
phantomjinx opened this issue Mar 2, 2022 · 3 comments
Closed

Cannot upgrade from 1.8.x to 1.9.0-SNAPSHOT #3063

phantomjinx opened this issue Mar 2, 2022 · 3 comments

Comments

@phantomjinx
Copy link
Contributor

During upgrade tests, the 1.9.0-SNAPSHOT operator is installed in a 1.8.1 namespace but crashes on spin-up.
The log of the operator reveals the following:

± oc logs camel-k-operator-745c79d9f8-5w2wk -n test-bac474ed-5077-444c-9292-d95f2aa603c5
{"level":"info","ts":1646161125.95206,"logger":"cmd","msg":"maxprocs: Leaving GOMAXPROCS=[8]: CPU quota undefined"}
{"level":"info","ts":1646161125.952098,"logger":"cmd","msg":"Go Version: go1.16.7"}
{"level":"info","ts":1646161125.9521048,"logger":"cmd","msg":"Go OS/Arch: linux/amd64"}
{"level":"info","ts":1646161125.9521096,"logger":"cmd","msg":"Buildah Version: 1.14.0"}
{"level":"info","ts":1646161125.9521139,"logger":"cmd","msg":"Kaniko Version: 0.17.1"}
{"level":"info","ts":1646161125.9521186,"logger":"cmd","msg":"Camel K Operator Version: 1.9.0-SNAPSHOT"}
{"level":"info","ts":1646161125.9521232,"logger":"cmd","msg":"Camel K Default Runtime Version: 1.11.0"}
{"level":"info","ts":1646161125.952128,"logger":"cmd","msg":"Camel K Git Commit: e8298e719e267234d8c286a7b480f6c86d081938"}
{"level":"info","ts":1646161126.0073845,"logger":"controller-runtime.metrics","msg":"Metrics server is starting to listen","addr":":8080"}
{"level":"info","ts":1646161126.0078557,"logger":"cmd","msg":"Configuring manager"}
{"level":"info","ts":1646161126.0215087,"logger":"cmd","msg":"Installing operator resources"}
fatal error: sync: unlock of unlocked mutex

goroutine 544 [running]:
runtime.throw(0x24fdf29, 0x1e)
        runtime/panic.go:1117 +0x72 fp=0xc000c8dd90 sp=0xc000c8dd60 pc=0x4385b2
sync.throw(0x24fdf29, 0x1e)
        runtime/panic.go:1103 +0x35 fp=0xc000c8ddb0 sp=0xc000c8dd90 pc=0x46d1f5
sync.(*Mutex).unlockSlow(0x3925a34, 0xc0ffffffff)
        sync/mutex.go:196 +0xd8 fp=0xc000c8ddd8 sp=0xc000c8ddb0 pc=0x47d4b8
sync.(*Mutex).Unlock(0x3925a34)
        sync/mutex.go:190 +0x48 fp=0xc000c8ddf8 sp=0xc000c8ddd8 pc=0x47d3c8
sync.(*Once).doSlow(0x3925a30, 0xc000a47f20)
        sync/once.go:70 +0x9a fp=0xc000c8de48 sp=0xc000c8ddf8 pc=0x47d5da
sync.(*Once).Do(...)
        sync/once.go:59
[github.com/apache/camel-k/pkg/install.KameletCatalog.func1.1(0x0](http://github.com/apache/camel-k/pkg/install.KameletCatalog.func1.1%280x0), 0x0)
        [github.com/apache/camel-k/pkg/install/kamelets.go:98](http://github.com/apache/camel-k/pkg/install/kamelets.go:98) +0x3f7 fp=0xc000c8df78 sp=0xc000c8de48 pc=0x1d069f7
[golang.org/x/sync/errgroup.(*Group).Go.func1(0xc0008d1650](http://golang.org/x/sync/errgroup.%28*Group%29.Go.func1%280xc0008d1650), 0xc00080b440)
        [golang.org/x/sync@v0.0.0-20210220032951-036812b2e83c/errgroup/errgroup.go:57](http://golang.org/x/sync@v0.0.0-20210220032951-036812b2e83c/errgroup/errgroup.go:57) +0x59 fp=0xc000c8dfd0 sp=0xc000c8df78 pc=0x1b1cad9
runtime.goexit()
        runtime/asm_amd64.s:1371 +0x1 fp=0xc000c8dfd8 sp=0xc000c8dfd0 pc=0x4721c1
created by [golang.org/x/sync/errgroup.(*Group).Go](http://golang.org/x/sync/errgroup.%28*Group%29.Go)
        [golang.org/x/sync@v0.0.0-20210220032951-036812b2e83c/errgroup/errgroup.go:54](http://golang.org/x/sync@v0.0.0-20210220032951-036812b2e83c/errgroup/errgroup.go:54) +0x66
...
...
...

Suggestion seems to be that the change in kamelet syntax is to blame (see #2987).

@astefanutti
Copy link
Member

A migration path during the installation of the embedded catalog must be performed to address #2987.

@phantomjinx
Copy link
Contributor Author

I upgraded 1.9.0-SNAPSHOT's build to 0.7.1 catalog release and that installed correctly.

phantomjinx added a commit to phantomjinx/camel-k that referenced this issue Mar 3, 2022
* Reassigning sync.Once causes unlocking of unlocked mutex error and
  recommended should not be done inside the function called by the
  sync.Once

* Instead log the error and bail out as something is wrong with the
  kamelets and needs to be fixed.

* Upgrades the kamelet branch to load compatible kamelets, ie. those that
  define with spec.template rather than spec.flow
phantomjinx added a commit to phantomjinx/camel-k that referenced this issue Mar 3, 2022
* Reassigning sync.Once causes unlocking of unlocked mutex error and
  recommended should not be done inside the function called by the
  sync.Once

* Instead log the error and bail out as something is wrong with the
  kamelets and needs to be fixed.

* Upgrades the kamelet branch to load compatible kamelets, ie. those that
  define with spec.template rather than spec.flow
phantomjinx added a commit to phantomjinx/camel-k that referenced this issue Mar 3, 2022
* Reassigning sync.Once causes unlocking of unlocked mutex error and
  recommended should not be done inside the function called by the
  sync.Once

* Instead log the error and bail out as something is wrong with the
  kamelets and needs to be fixed.

* Upgrades the kamelet branch to load compatible kamelets, ie. those that
  define with spec.template rather than spec.flow
phantomjinx added a commit to phantomjinx/camel-k that referenced this issue Mar 3, 2022
* Reassigning sync.Once causes unlocking of unlocked mutex error and
  recommended should not be done inside the function called by the
  sync.Once

* Instead log the error and bail out as something is wrong with the
  kamelets and needs to be fixed.

* Upgrades the kamelet branch to load compatible kamelets, ie. those that
  define with spec.template rather than spec.flow
phantomjinx added a commit to phantomjinx/camel-k that referenced this issue Mar 3, 2022
* Reassigning sync.Once causes unlocking of unlocked mutex error and
  recommended should not be done inside the function called by the
  sync.Once

* Instead log the error and bail out as something is wrong with the
  kamelets and needs to be fixed.

* Upgrades the kamelet branch to load compatible kamelets, ie. those that
  define with spec.template rather than spec.flow
@phantomjinx
Copy link
Contributor Author

Fixed with #3078

phantomjinx added a commit to phantomjinx/camel-k that referenced this issue Mar 7, 2022
* Reassigning sync.Once causes unlocking of unlocked mutex error and
  recommended should not be done inside the function called by the
  sync.Once

* Instead log the error and bail out as something is wrong with the
  kamelets and needs to be fixed.

* Upgrades the kamelet branch to load compatible kamelets, ie. those that
  define with spec.template rather than spec.flow
phantomjinx added a commit to phantomjinx/camel-k that referenced this issue Mar 11, 2022
* Reassigning sync.Once causes unlocking of unlocked mutex error and
  recommended should not be done inside the function called by the
  sync.Once

* Instead log the error and bail out as something is wrong with the
  kamelets and needs to be fixed.

* Upgrades the kamelet branch to load compatible kamelets, ie. those that
  define with spec.template rather than spec.flow
phantomjinx added a commit to phantomjinx/camel-k that referenced this issue Mar 25, 2022
* Reassigning sync.Once causes unlocking of unlocked mutex error and
  recommended should not be done inside the function called by the
  sync.Once

* Instead log the error and bail out as something is wrong with the
  kamelets and needs to be fixed.

* Upgrades the kamelet branch to load compatible kamelets, ie. those that
  define with spec.template rather than spec.flow
phantomjinx added a commit to phantomjinx/camel-k that referenced this issue Apr 11, 2022
* Reassigning sync.Once causes unlocking of unlocked mutex error and
  recommended should not be done inside the function called by the
  sync.Once

* Instead log the error and bail out as something is wrong with the
  kamelets and needs to be fixed.

* Upgrades the kamelet branch to load compatible kamelets, ie. those that
  define with spec.template rather than spec.flow
squakez pushed a commit that referenced this issue Apr 18, 2022
* Reassigning sync.Once causes unlocking of unlocked mutex error and
  recommended should not be done inside the function called by the
  sync.Once

* Instead log the error and bail out as something is wrong with the
  kamelets and needs to be fixed.

* Upgrades the kamelet branch to load compatible kamelets, ie. those that
  define with spec.template rather than spec.flow
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants