(opts *kmeta.ListOptions)
| 147 | } |
| 148 | |
| 149 | func (c *Client) ListHPAs(opts *kmeta.ListOptions) ([]kautoscaling.HorizontalPodAutoscaler, error) { |
| 150 | if opts == nil { |
| 151 | opts = &kmeta.ListOptions{} |
| 152 | } |
| 153 | hpaList, err := c.hpaClient.List(context.Background(), *opts) |
| 154 | if err != nil { |
| 155 | return nil, errors.WithStack(err) |
| 156 | } |
| 157 | for i := range hpaList.Items { |
| 158 | hpaList.Items[i].TypeMeta = _hpaTypeMeta |
| 159 | } |
| 160 | return hpaList.Items, nil |
| 161 | } |
| 162 | |
| 163 | func (c *Client) ListHPAsByLabels(labels map[string]string) ([]kautoscaling.HorizontalPodAutoscaler, error) { |
| 164 | opts := &kmeta.ListOptions{ |
no test coverage detected