Close closes all connections
()
| 32 | |
| 33 | // Close closes all connections |
| 34 | func (uw *upgraderWrapper) Close() error { |
| 35 | errs := []error{} |
| 36 | for _, conn := range uw.Connections { |
| 37 | err := conn.Close() |
| 38 | if err != nil { |
| 39 | errs = append(errs, err) |
| 40 | } |
| 41 | } |
| 42 | |
| 43 | return utilerrors.NewAggregate(errs) |
| 44 | } |
| 45 | |
| 46 | // GetUpgraderWrapper returns an upgrade wrapper for the given config @Factory |
| 47 | func GetUpgraderWrapper(client Client) (http.RoundTripper, UpgraderWrapper, error) { |