streampipes
streampipes copied to clipboard
Update_versions script of installer is broken
Body
To bump the current StreamPipes version in the various installers (docker-compose, CLI and k8s helm charts), we use the upgrade_version.sh script in the installer folder.
After some changes to the `values.yaml file, the versions script seems to be broken as it not only replaces StreamPipes versions, but also the versions of Consul, CouchDB and InfluxDB.
-
Link to the commit where the bug was first seen: https://github.com/apache/streampipes/pull/1658/commits/b3ff92127ee7a41e89ea91df4501160ef9c9e245
-
How to resolve Revisit the logic in the
upgrade_versionsmodule and make sure that only the versions related to StreamPipes are updated.
Mentoring
As this issue is marked as good first issue: one of @dominikriemer, @tenthe, are happy to provide help for getting started, just tag (one of) them if you want to start working on this issue and need some help. This issue is ideal for people that are interested in getting started with StreamPipes and like to apply some bash magic..
StreamPipes Committer
I acknowledge that I am a maintainer/committer of the Apache StreamPipes project.
Hi @dominikriemer, maybe I can have a try. I think we can simply match the version field between the streampipes and external sections to solve the problem.
Another approach could be to check the current version and only replace those values
Another approach could be to check the current version and only replace those values
Great idea! However, this behavior could be risky if the version of StreamPipes is the same as the version of other components.
Hi @tenthe, I've drafted a version that works well, but we still need to discuss the special cases mentioned before.
Hi, thanks for the PR. You are right the script will not work for this case. Unfortunately, I do not have a good idea yet except for checking the git diff manually after running the script 🤔 Do you have an idea how we could catch this problem?
I have a couple of ideas that might be helpful, but I'm not sure if they're good ideas or not.
- Add locators like this to the file to help improve the script positioning.
- Explore using ConfigMaps in k8s. Maybe this could potentially help us use an alias to replace the value of StreamPipes' version.
BTW, maybe we can use the previous PR as a workaround and keep this issue open for further exploration.
Thanks, yes I agree. We should merge your PR and leave this issue open.
I have a couple of ideas that might be helpful, but I'm not sure if they're good ideas or not.
* Add locators like [this](https://github.com/apache/streampipes/blob/7fff17c768f7511d39bed38ed7dc455c1058670f/installer/k8s/README.md?plain=1#L21) to the file to help improve the script positioning. * Explore using [ConfigMaps](https://kubernetes.io/docs/concepts/configuration/configmap/) in k8s. Maybe this could potentially help us use an alias to replace the value of StreamPipes' version.BTW, maybe we can use the previous PR as a workaround and keep this issue open for further exploration.
Thanks a lot for your input @loststar 🙏🏼 FYI: this might relate to a project we have in this year's OSPP challenge: https://summer-ospp.ac.cn/org/prodetail/23fc00416?lang=en&list=pro
I have a couple of ideas that might be helpful, but I'm not sure if they're good ideas or not.
* Add locators like [this](https://github.com/apache/streampipes/blob/7fff17c768f7511d39bed38ed7dc455c1058670f/installer/k8s/README.md?plain=1#L21) to the file to help improve the script positioning. * Explore using [ConfigMaps](https://kubernetes.io/docs/concepts/configuration/configmap/) in k8s. Maybe this could potentially help us use an alias to replace the value of StreamPipes' version.BTW, maybe we can use the previous PR as a workaround and keep this issue open for further exploration.
Thanks a lot for your input @loststar 🙏🏼 FYI: this might relate to a project we have in this year's OSPP challenge: https://summer-ospp.ac.cn/org/prodetail/23fc00416?lang=en&list=pro
Thanks for the information. If the OSPP participants will refine this feature, I'm willing to stay engaged in the discussion, or I'll continue to follow this issue. @bossenti After consideration, I think the following approach aligns better with our goals: incorporating specific comments before and after the version number, similar to this example, and utilizing a script to match the version number within the restricted section. I will make an attempt to draft a version at a later date to assess its effectiveness.
@RobertIndie how is the status of the OSPP challenge?
Thanks for reminding me of this issue. @bossenti Yes. This is related to the upgrading support of the OSPP challenge. @luoluoyuyu Could you take a look at this issue?
@loststar thank you very much for your input here 🙏 Would be great if you continue bringing your knowledge into to discussion 🙂
Hi @bossenti,
I have executed the script, and it appears that the Update_versions script can only modify the version number of Streampipes. Is the question we are facing about precisely determining the location where the version number needs to be changed?
Yes, if my understanding is correct @dominikriemer am I right?