Skip to content

Commit

Permalink
Merge pull request #162 from River-sh/fix_raven_l7_restart
Browse files Browse the repository at this point in the history
fix restart
  • Loading branch information
njucjc authored Jan 24, 2024
2 parents ecae7e8 + b6e168d commit e005d59
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions pkg/engine/proxy.go
Original file line number Diff line number Diff line change
Expand Up @@ -109,13 +109,16 @@ func (p *ProxyEngine) handler(gw *v1beta1.Gateway) error {

switch JudgeType(p.proxyOption.GetServerStatus(), specServer) {
case StartType:
srcAddr := getSrcAddressForProxyServer(p.client, p.nodeName)
err = p.startProxyServer()
if err != nil {
klog.Errorf(utils.FormatProxyServer("failed to start proxy server, error %s", err.Error()))
return err
}
p.serverLocalEndpoints = srcAddr
case StopType:
p.stopProxyServer()
p.serverLocalEndpoints = []string{}
case RestartType:
srcAddr := getSrcAddressForProxyServer(p.client, p.nodeName)
if computeHash(strings.Join(p.serverLocalEndpoints, ",")) != computeHash(strings.Join(srcAddr, ",")) {
Expand Down

0 comments on commit e005d59

Please sign in to comment.