Skip to content

Commit ae7f41d

Browse files
committed
Update comments.
1 parent cf9b7d2 commit ae7f41d

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

cmd/outline-ss-server/main.go

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -111,9 +111,9 @@ func (s *SSServer) loadConfig(filename string) error {
111111
return fmt.Errorf("failed to load config (%v): %w", filename, err)
112112
}
113113

114-
// We hot swap the services by having them both live at the same time. This
115-
// means we create services for the new config first, and then take down the
116-
// services from the old config.
114+
// We hot swap the config by having the old and new listeners both live at
115+
// the same time. This means we create listeners for the new config first,
116+
// and then close the old ones after.
117117
oldListenerSet := s.lnSet
118118
s.lnSet = s.lnManager.NewListenerSet()
119119
var totalCipherCount int
@@ -152,7 +152,7 @@ func (s *SSServer) loadConfig(filename string) error {
152152
logger.Infof("Loaded %d access keys over %d listeners", totalCipherCount, s.lnSet.Len())
153153
s.m.SetNumAccessKeys(totalCipherCount, s.lnSet.Len())
154154

155-
// Take down the old services now that the new ones are created and serving.
155+
// Take down the old listeners now that the new ones are created and serving.
156156
if oldListenerSet != nil {
157157
if err := oldListenerSet.Close(); err != nil {
158158
logger.Errorf("Failed to stop old listeners: %w", err)
@@ -163,7 +163,7 @@ func (s *SSServer) loadConfig(filename string) error {
163163
return nil
164164
}
165165

166-
// Stop serving on all existing services.
166+
// Stop serving on all existing listeners.
167167
func (s *SSServer) Stop() error {
168168
if s.lnSet == nil {
169169
return nil

0 commit comments

Comments
 (0)