-
Notifications
You must be signed in to change notification settings - Fork 276
feat(envoy): Return list of services in GetServiceFromEnvoyCertificate #1566
Conversation
3d24216
to
b154f7f
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ksubrmnn thank you so much for making all these changes!
Would you mind changing the []*MeshService
to []MeshService
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Change looks good. Would you mind addressing the following 2 comments at a high level:
- Adding unit tests for
GetServiceFromEnvoyCertificate()
to return multiple services - Tagging assumptions with Github issue ID using comments inline in the code
Thanks
bcf6ec3
to
dc81a3d
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you @ksubrmnn !
dc81a3d
to
b9d32c7
Compare
meshService := service.MeshService{ | ||
Namespace: cnMeta.Namespace, | ||
Name: svc.Name, | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just a thought, it might be a good idea to abstract the conversion of a service
to meshService
in a utils function and they use it everywhere. WDYT ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
From kubernetes service to meshService? I think that's a good idea. Can you make an issue and tag it as "good first issue"?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There is a helper for converting K8s service to MeshService in catalog/routes.go
: k8sSvcToMeshSvc
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ksubrmnn please could we use k8sSvcToMeshSvc
wherever possible
Please describe the motivation for this PR and provide enough
information so that others can review it.
Return a list of services for an envoy certificate instead of just the first one
Please mark with X for applicable areas.
Please answer the following questions with yes/no.
No