-
Notifications
You must be signed in to change notification settings - Fork 4
Conversation
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.
take a look at the GitHub CI failures too
cmd/main.go
Outdated
} | ||
}else if conf.ServiceDiscovery == config.Consul { |
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.
you will need to run go fmt
on your files
internal/consul/services.go
Outdated
func ListServices (consul *api.Client) (map[string][]string){ | ||
|
||
catalog:= consul.Catalog() |
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.
func ListServices (consul *api.Client) (map[string][]string){ | |
catalog:= consul.Catalog() | |
func ListServices (consul *api.Client) (map[string][]string){ | |
catalog:= consul.Catalog() |
internal/entry/types.go
Outdated
package entry | ||
|
||
|
||
type RawEntry struct { |
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.
package entry | |
type RawEntry struct { | |
package entry | |
type RawEntry struct { |
@@ -0,0 +1,21 @@ | |||
package entry |
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.
why have you renamed Labels to Entry?
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.
last name for thi type was container I would like something who work in both case but we can change entry by label if ou want
internal/entry/types.go
Outdated
} | ||
|
||
|
||
func (c RawEntry) GetLabelValue(label string) (string, bool) { |
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.
} | |
func (c RawEntry) GetLabelValue(label string) (string, bool) { | |
} | |
func (c RawEntry) GetLabelValue(label string) (string, bool) { |
I have apply a go fmt |
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.
can you provide some steps for me to test as well?
const ( | ||
Docker = "Docker" | ||
Consul = "Consul" | ||
) |
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.
I dont find this necessary, unless you have a reason?
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.
I just would like test to create something like an enumeration to avoid to modify all the if the configuration variable change
to test you can launch a consul server
add a service
and reload consul config
|
i'm on leave, will review this when i'm back |
done |
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.
i have tested successfully. i'll write some tests and make a release
Description
this PR bring suppport of consul catalog to get label
it's my first try in go devlelopment feel free to modify code if my work is a litle dirty
Type of change
Checklist: