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

[1.15] cli: Infer gloo deploy name && optimize glooctl check #9724

Merged
merged 6 commits into from
Jul 9, 2024

Conversation

davidjumani
Copy link
Contributor

@davidjumani davidjumani commented Jul 4, 2024

Description

Forward port of solo-io#9719 && backport of solo-io#9674

Fixes solo-io#9644
Fix a bug where the service and function names of a discovered gRPC service are not printed when running glooctl get upstreams

Steps to reproduce :

Install edge

helm upgrade --install -n gloo-system --create-namespace gloo ./_test/gloo-1.0.0-ci1.tgz --wait --wait-for-jobs --set gatewayProxies.gatewayProxy.service.type=ClusterIP --values test/kube2e/helm/artifacts/helm.yaml --set discovery.fdsMode=BLACKLIST

Deploy a grpc service && label it

kubectl -n gloo-system create deployment grpcstore-demo --image=docker.io/soloio/grpcstore-demo
kubectl -n gloo-system expose deployment grpcstore-demo --port 80 --target-port=8080
kubectl -n gloo-system label svc/grpcstore-demo discovery.solo.io/function_discovery=enabled

Verify the upstream has been created and has the grpcJsonTranscoder

kubectl -n gloo-system get upstream gloo-system-grpcstore-demo-80 -o yaml

Verify that glooctl now displays the grpc functions

./_output/glooctl-darwin-arm64 get upstreams

| gloo-system-grpcstore-demo-80 | Kubernetes | Accepted | svc name:      grpcstore-demo  |
|                               |            |          | svc namespace: gloo-system     |
|                               |            |          | port:          80              |
|                               |            |          | gRPC service:                  |
|                               |            |          |                                |
|                               |            |          | solo.examples.v1.StoreService  |
|                               |            |          |   - CreateItem                 |
|                               |            |          |   - ListItems                  |
|                               |            |          |   - DeleteItem                 |
|                               |            |          |   - GetItem                    |
|                               |            |          |                                |

Checklist:

  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • I have added tests that prove my fix is effective or that my feature works

BOT NOTES:
resolves solo-io#9673

@github-actions github-actions bot added the keep pr updated signals bulldozer to keep pr up to date with base branch label Jul 4, 2024
@solo-changelog-bot
Copy link

Issues linked to changelog:
solo-io#9163

davidjumani and others added 3 commits July 3, 2024 22:14
…reation of clients (#9674)

* glooctl: optimize creating clients

* adding changelog

* fix tests

---------

Co-authored-by: soloio-bulldozer[bot] <48420018+soloio-bulldozer[bot]@users.noreply.github.com>
@solo-changelog-bot
Copy link

Issues linked to changelog:
solo-io#9163
solo-io#9673

@davidjumani davidjumani changed the title [1.15] cli: Infer gloo deploy name [1.15] cli: Infer gloo deploy name && optimize glooctl check Jul 4, 2024
@solo-changelog-bot
Copy link

Issues linked to changelog:
solo-io#9163
solo-io#9673
solo-io#9644

@davidjumani
Copy link
Contributor Author

/kick

Step #1 - "run-tests": Step #8 - "run-e2e-tests":   to contain substring
Step #1 - "run-tests": Step #8 - "run-e2e-tests":       <string>: body before transformation: test�[0m
Step #1 - "run-tests": Step #8 - "run-e2e-tests":   �[38;5;9mIn �[1m[It]�[0m�[38;5;9m at: �[1m/workspace/gloo/test/e2e/staged_transformation_test.go:644�[0m �[38;5;243m@ 07/04/24 13:30:34.186�[0m
Step #1 - "run-tests": Step #8 - "run-e2e-tests": 
Step #1 - "run-tests": Step #8 - "run-e2e-tests":   �[38;5;9mFull Stack Trace�[0m
Step #1 - "run-tests": Step #8 - "run-e2e-tests":     github.com/solo-io/gloo/test/e2e_test.glob..func32.5.8({0xc002948000, 0x2f31a})
Step #1 - "run-tests": Step #8 - "run-e2e-tests":     	/workspace/gloo/test/e2e/staged_transformation_test.go:644 +0x402
Step #1 - "run-tests": Step #8 - "run-e2e-tests":     github.com/solo-io/gloo/test/e2e_test.glob..func32.5.11(0x1, 0x1, 0x6a0b028)
Step #1 - "run-tests": Step #8 - "run-e2e-tests":     	/workspace/gloo/test/e2e/staged_transformation_test.go:747 +0x31f
Step #1 - "run-tests": Step #8 - "run-e2e-tests":     reflect.Value.call({0x6134c80?, 0xc000903100?, 0x13?}, {0x6882b7d, 0x4}, {0xc002849810, 0x3, 0x3?})
Step #1 - "run-tests": Step #8 - "run-e2e-tests":     	/usr/local/go/src/reflect/value.go:596 +0x14ce
Step #1 - "run-tests": Step #8 - "run-e2e-tests":     reflect.Value.Call({0x6134c80?, 0xc000903100?, 0x760e3d8?}, {0xc002849810, 0x3, 0x3})
Step #1 - "run-tests": Step #8 - "run-e2e-tests":     	/usr/local/go/src/reflect/value.go:380 +0xb6
Step #1 - "run-tests": Step #8 - "run-e2e-tests": �[38;5;243m------------------------------�[0m
Step #1 - "run-tests": Step #8 - "run-e2e-tests": �[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m�[38;5;14mS�[0m
Step #1 - "run-tests": Step #8 - "run-e2e-tests": 
Step #1 - "run-tests": Step #8 - "run-e2e-tests": �[38;5;9m�[1mSummarizing 1 Failure:�[0m
Step #1 - "run-tests": Step #8 - "run-e2e-tests":   �[38;5;9m[FAIL]�[0m �[0mStaged Transformation �[38;5;243mno auth �[0mcan enable enhanced logging �[38;5;9m�[1m[It] staged logging enabled, individual logging enabled�[0m
Step #1 - "run-tests": Step #8 - "run-e2e-tests":   �[38;5;243m/workspace/gloo/test/e2e/staged_transformation_test.go:644�[0m

Copy link
Contributor

@bewebi bewebi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

One nit around naming
Since this is a forward-port and it was previously approved I do not consider it a blocker

@@ -28,6 +28,9 @@ var (
return fmt.Sprintf("Gloo has detected that the data plane is out of sync. The following types of resources have not been accepted: %v. "+
"Gloo will not be able to process any other configuration updates until these errors are resolved.", resourceNames)
}

// Initialize the custom deployment name that is overwritten later on in the `CheckResources` function
customGlooDeploymentName = helpers.GlooDeploymentName
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Contributor

@bewebi bewebi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Meant to approve previously

@soloio-bulldozer soloio-bulldozer bot merged commit 2d6603a into v1.15.x Jul 9, 2024
12 checks passed
@soloio-bulldozer soloio-bulldozer bot deleted the infer-gloo-deploy-name-115 branch July 9, 2024 17:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
keep pr updated signals bulldozer to keep pr up to date with base branch
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants