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

Helm chart installation and cluster project selection #612

Closed
martinszuc opened this issue Nov 9, 2023 · 6 comments
Closed

Helm chart installation and cluster project selection #612

martinszuc opened this issue Nov 9, 2023 · 6 comments
Assignees
Labels
bug Something isn't working
Milestone

Comments

@martinszuc
Copy link
Contributor

martinszuc commented Nov 9, 2023

related to: #676, #661, #613
[kind/bug]

What versions of software are you using?

  • Operating System: Fedora 38
  • IntelliJ version: 2023.2 Ultimate
  • OpenShift version: 1.7.0 SNAPSHOT

What i did to encounter this:

Already logged in to cluster, I created "my-test-2" cluster project next to original "my-test". The project name in the tree does not refresh. (needs restart (most likely this issue):
01-create-new-project-on-cluster

Here things branch out according to the fact if we restart intellij or not:

IF WE DONT: there is behavior when we install helm chart on this unrefreshed tree . Here, after I created the new "my-test-2" project, I installed the mysql helm chart and in the background you can see openshift console get updated configs with the helm release but under the "my-test-2" project, when the tree says "my-test" which is the original project. I guess this is correct if the tree refresh would get fixed.
02-installing-helm-chart-on-new-project

IF WE RESTART IDE:
Tree is properly refreshed. But when I delete the project the tree refreshes itself but with "Failed to load chart releases".:
03-removing-already-restarted-2-projects

When i tried to install helm chart on project with the "Failed to load chart releases". It threw error:
2023-11-09-20-55-08

Process exited with an error: 1 (Exit value: 1) Error: INSTALLATION FAILED: rendered manifests contain a resource that already exists. Unable to continue with install: could not get information about the resource Secret "mysql" in namespace "my-test-2": secrets "mysql" is forbidden: User "developer" cannot get resource "secrets" in API group "" in the namespace "my-test-2":

Expected behavior

Should helm charts get installed under a project or cluster? In that case the button "Open helm charts" is in incorrect place.
Otherwise there is a question if the user / dev should be able to switch between projects within cluster. And be able to do this within IDE.

@martinszuc martinszuc added the bug Something isn't working label Nov 9, 2023
@mohitsuman mohitsuman added this to the 1.8.0 milestone Jan 10, 2024
@mohitsuman mohitsuman moved this to 📋 Backlog in IDE Cloudaptors Jan 10, 2024
@adietish adietish moved this from 📋 Backlog to 🏗 In progress in IDE Cloudaptors Jan 25, 2024
@adietish
Copy link
Contributor

The bug where the tree won't refreshing when creating a new project is gone.

Steps:

  1. ASSERT: be logged into openshift cluster (works also with minikube)
  2. EXEC: pick "New Project" in ctx menu to the cluster, provide name and confirm

Result:
The resource tree is refreshed and is using the new project as current/active project

@adietish
Copy link
Contributor

adietish commented Jan 26, 2024

I can reproduce issue 2:

Steps:

  1. EXEC: create a new project (ex. test7)
  2. EXEC: delete the new project

Result:
The tree is refreshed but it is still displaying the deleted project.
image

VScode behaves exactly in the same way (created and deleted the project test8). It then still displays the deleted project.
image

oc also behaves in this way: if you delete the current project, kube config stays unaltered, it still points to project that was deleted.

@adietish
Copy link
Contributor

adietish commented Jan 26, 2024

I see how this the above behaviour is annoying to the user. Displaying a different project instead of the missing one isn't helpful either: the tree would not unveil to the user that kube config points to a missing project. We would therefore have to change the current project in kube config, which is unexpected, too.
@martinszuc, @sbouchet, @vrubezhny, @datho7561: thoughts?

@adietish
Copy link
Contributor

adietish commented Jan 26, 2024

@martinszuc:

Should helm charts get installed under a project or cluster? In that case the button "Open helm charts" is in incorrect place.

I fully agree on this one and raised it already. Helm charts are installed into the current project. The current UI is misleading and doesn't tell you where the charts are installed. I came to the same conclusion and thus filed #613
The latest implementation in vscode has it on the Helm node
image
We dont have a helm node with the repositories yet. I'd move the command to the namespace/project node for now: #676

Otherwise there is a question if the user / dev should be able to switch between projects within cluster. And be able to do this within IDE.

Fully agree on this one, too. I filed & implemented #661

@datho7561
Copy link

The latest implementation in vscode has it on the Helm node

We also have it as a context menu item on the project. I think we should move the "Helm" node to a different section since it's mostly used for listing and configuring Helm repos, which can be done even if you aren't connected to a cluster. If we move the "Helm" node, we should also remove the "Open Helm View" context menu item.

oc also behaves in this way: if you delete the current project, kube config stays unaltered, it still points to project that was deleted.

If you can replicate the VS Code behaviour of a node with an error icon and text that says "missing project", I think that would be the best method.

@adietish
Copy link
Contributor

The issue here where the tree isn't refreshed when a project is deleted doesnt occurr any more. All related improvements/issues were filed to separate issues.
Closing.

@github-project-automation github-project-automation bot moved this from 🏗 In progress to ✅ Done in IDE Cloudaptors Jan 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
Status: ✅ Done
Development

No branches or pull requests

4 participants