Skip to content

Commit

Permalink
session bug fix
Browse files Browse the repository at this point in the history
  • Loading branch information
trheyi committed Feb 9, 2022
1 parent a43d9b7 commit fd1a3d3
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions share/const.go
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
package share

// Logs
// session -> freeport
// 更新制品目录 -> ui/downloads debug
// session -> freeport fix bug
// 更新制品目录 -> ui/downloads

// VERSION 版本号
const VERSION = "0.9.0"
Expand Down
8 changes: 4 additions & 4 deletions share/session.go
Original file line number Diff line number Diff line change
Expand Up @@ -75,8 +75,8 @@ func SessionServerStart() {
panic(fmt.Sprintf("unable to create a new memberlist config: %v", err))
}
// m.BindAddr = config.Conf.Session.Host
m.BindPort = config.Conf.Session.Port
m.AdvertisePort = config.Conf.Session.Port
m.BindPort = SessionPort
m.AdvertisePort = SessionPort
c.MemberlistConfig = m

// c.MemberlistConfig.BindAddr = config.Conf.Session.Host
Expand All @@ -102,14 +102,14 @@ func SessionServerStart() {
go func() {
err = sessServer.Start() // Call Start at background. It's a blocker call.
if err != nil {
klog.Error("olric.Start returned an error: %v", err)
klog.Panic("olric.Start returned an error: %v", err)
}
}()

<-ctx.Done()
dm, err := sessServer.NewDMap("local-session")
if err != nil {
klog.Error("olric.NewDMap returned an error: %v", err)
klog.Panic("olric.NewDMap returned an error: %v", err)
}

session.MemoryUse(session.ServerDMap{DMap: dm})
Expand Down

0 comments on commit fd1a3d3

Please sign in to comment.