Ver Fonte

strip debug comments

reid há 2 anos atrás
pai
commit
c21b4b5afd
1 ficheiros alterados com 0 adições e 10 exclusões
  1. 0 10
      broadcast/broadcast.go

+ 0 - 10
broadcast/broadcast.go

@@ -184,7 +184,6 @@ func constructPierInfo(piers []string) (map[string]structs.Urbit, error) {
 		// and insert the struct into the map we will use as input for the broadcast struct
 		updates[pier] = urbit
 	}
-	config.Logger.Info("Pier info constructed")
 	return updates, nil
 }
 
@@ -232,7 +231,6 @@ func GetContainerNetworks(containers []string) map[string]string {
 
 // update broadcastState with a map of items
 func UpdateBroadcastState(values map[string]interface{}) error {
-	config.Logger.Info("updatestate mu lock")
 	mu.Lock()
 	v := reflect.ValueOf(&broadcastState).Elem()
 	for key, value := range values {
@@ -248,11 +246,8 @@ func UpdateBroadcastState(values map[string]interface{}) error {
 			return err
 		}
 	}
-	config.Logger.Info("Broadcasting updated state")
 	mu.Unlock()
 	BroadcastToClients()
-	config.Logger.Info("Broadcasted")
-	config.Logger.Info("getstate mu unlock")
 	return nil
 }
 
@@ -316,17 +311,14 @@ func recursiveUpdate(dst, src reflect.Value) error {
 
 // return broadcast state
 func GetState() structs.AuthBroadcast {
-	config.Logger.Info("getstate mu lock")
 	mu.Lock()
 	defer mu.Unlock()
-	config.Logger.Info("getstate mu unlock")
 	return broadcastState
 }
 
 // return json string of current broadcast state
 func GetStateJson() ([]byte, error) {
 	bState := GetState()
-	config.Logger.Info("got state")
 	broadcastJson, err := json.Marshal(bState)
 	if err != nil {
 		errmsg := fmt.Sprintf("Error marshalling response: %v", err)
@@ -339,7 +331,6 @@ func GetStateJson() ([]byte, error) {
 // broadcast the global state to auth'd clients
 func BroadcastToClients() error {
 	authJson, err := GetStateJson()
-	config.Logger.Info("returned state json")
 	if err != nil {
 		errmsg := fmt.Errorf("Error marshalling auth broadcast:", err)
 		return errmsg
@@ -352,7 +343,6 @@ func BroadcastToClients() error {
 			return err
 		}
 	}
-	config.Logger.Info("Broadcast done")
 	return nil
 }