Skip to content

Commit 8a2bb9c

Browse files
authored
Merge pull request #404 from jojimt/dns
Update service plugin to reflect epg key changes
2 parents 7ba1ed3 + 2fa6790 commit 8a2bb9c

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

svcplugin/bridge/bridge.go

+2-2
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ func (b *Bridge) AddService(srvID string, srvName string, nwName string, tenantN
8383
log.Errorf("Service registration failed for %v. Error: %s",
8484
service, err)
8585
}
86-
b.services[srvName+nwName] = append(b.services[srvName+nwName], service)
86+
b.services[srvName] = append(b.services[srvName], service)
8787
}
8888

8989
// RemoveService removes service from registry when triggered from dockplugin
@@ -98,7 +98,7 @@ func (b *Bridge) RemoveService(srvID string, srvName string, nwName string, tena
9898
log.Warningf("Service removal failed for service %v. Error: %s:",
9999
service, err)
100100
}
101-
delete(b.services, srvName+nwName)
101+
delete(b.services, srvName)
102102
}
103103

104104
func (b *Bridge) createService(srvID string, srvName string, nwName string, tenantName string, srvIP string) *Service {

svcplugin/skydns2extension/skydns2.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -79,5 +79,5 @@ func (r *Skydns2Adapter) Refresh(service *bridge.Service) error {
7979
}
8080

8181
func (r *Skydns2Adapter) servicePath(service *bridge.Service) string {
82-
return "/skydns/" + service.Tenant + "/" + service.Network + "/" + service.Name + "/" + service.ID
82+
return "/skydns/" + service.Tenant + "/" + service.Name + "/" + service.ID
8383
}

systemtests/basic_test.go

+2-2
Original file line numberDiff line numberDiff line change
@@ -172,8 +172,8 @@ func (s *systemtestSuite) testBasicSvcDiscovery(c *C, encap string) {
172172
}
173173

174174
// Check name resolution
175-
c.Assert(s.pingTestByName(containers, fmt.Sprintf("svc1%d.private.default", i)), IsNil)
176-
c.Assert(s.pingTestByName(containers, fmt.Sprintf("svc2%d.private.default", i)), IsNil)
175+
c.Assert(s.pingTestByName(containers, fmt.Sprintf("svc1%d.default", i)), IsNil)
176+
c.Assert(s.pingTestByName(containers, fmt.Sprintf("svc2%d.default", i)), IsNil)
177177

178178
// cleanup
179179
c.Assert(s.removeContainers(containers), IsNil)

0 commit comments

Comments
 (0)