-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
[chore][extension/observer] move extension observer to internal pkg and pass checkapi #29083
Comments
I found maybe we can just assign an exported function to a global variable and pass checkapi(ensure that multiple goroutines do not access concurrently), just wait for #28886 merged |
Move to internal package seems more reasonable as comment #29321 (comment), so reopen this issue. |
This issue has been inactive for 60 days. It will be closed in 60 days if there is no activity. To ping code owners by adding a component label, see Adding Labels via Comments, or if you are unsure of which component this issue relates to, please ping |
This issue has been closed as inactive because it has been stale for 120 days with no activity. |
Component(s)
extension/observer
Is your feature request related to a problem? Please describe.
Function
observer.NewEndpointsWatcher
is referenced by thedockerobserver
,ecstaskobserver
,hostobserver
andk8sobserver
components. Since this is an exported function which is not allow for checkapi tool, we can extract that and place it in aninternal/observer
orpkg/observer
package. When use checkapi tool(go run cmd/checkapi/main.go .
), error as shown below:Describe the solution you'd like
Before the adjustment, the directory structure:
extension/observer
├── Makefile
├── README.md
├── dockerobserver/
├── ecsobserver/
├── ecstaskobserver/
├── endpoints.go
├── endpoints_test.go
├── endpointswatcher.go
├── endpointswatcher_test.go
├── go.mod
├── go.sum
├── hostobserver/
├── k8sobserver/
├── metadata.yaml
└── observer.go
After the adjustment, the directory structure (add new directory internal/observer):
extension/observer
├── README.md
├── dockerobserver/
├── ecsobserver/
├── ecstaskobserver/
├── hostobserver/
├── k8sobserver/
└── metadata.yaml
internal/observer
├── Makefile
├── endpoints.go
├── endpoints_test.go
├── endpointswatcher.go
├── endpointswatcher_test.go
├── go.mod
├── go.sum
├── metadata.yaml
└── observer.go
Describe alternatives you've considered
No response
Additional context
No response
The text was updated successfully, but these errors were encountered: