code: func (a *Airport) processHangar() {
  	for {
  		hangar, ok := <-a.hangarChan
  		if !ok {
  			a.log.Errorf("hangar channel closed")
  			return
  		}
  		switch hangar.GetChangeType() {
  		case datasync.Put:
  			a.log.Debugf("hangar %s updated", hangar.GetKey())
  		case datasync.Delete:
  			fl := flight.Info{}
  			if _, err := fmt.Sscanf(hangar.GetKey(), hangarKeyTemplate, &(fl.Airline), &(fl.Number), &(fl.Priority)); err != nil {
  				a.log.Errorf("error creating hangar key: %v", err)
  				continue
  			}
  			if err := a.departureBroker.Put(fmt.Sprintf(flightIDFormat, fl.Airline, fl.Number), &fl); err != nil {
  				a.log.Errorf("failed to put flight to departure broker: %v", err)
  				continue
  			}
  		}
  	}
  }
docs: // Wait for hangar. Incoming flights are stored, outgoing are sent to departure.