feat: refactor.

This commit is contained in:
tx7do
2024-05-14 16:37:22 +08:00
parent edbcad5973
commit 5e85934e35
3 changed files with 50 additions and 4 deletions

View File

@@ -21,6 +21,14 @@ func NewServiceInfo(name, version, id string) *ServiceInfo {
}
}
func (s *ServiceInfo) SetName(name string) {
s.Name = name
}
func (s *ServiceInfo) SetVersion(version string) {
s.Version = version
}
func (s *ServiceInfo) GetInstanceId() string {
return s.Id + "." + s.Name
}