-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Implement vpc poller on account add.
- Perform cloud inventory poll for vpcs on CPA add, vm instanes are skipped as configured filters are nil. - Move account poller(fetches cloud data from internal snapshot) to CPA. - Account poller is applicable for both vpc and vm instance purpose. - Maintain vpc list globally using cache indexers. - In CES, use existing account poller(created during CPA add). - On CES delete, reset vmSelector filters and skip inventory poll for vms, do not distub inventory poll for vpcs. - On CPA delete, stop cloud inventory poll and remove account poller. - Add unit test the changes introduced. Signed-off-by: Archana Holla <[email protected]>
- Loading branch information
1 parent
49aec49
commit f24f620
Showing
22 changed files
with
1,775 additions
and
309 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
// Copyright 2022 Antrea Authors. | ||
// | ||
// Licensed under the Apache License, Version 2.0 (the "License"); | ||
// you may not use this file except in compliance with the License. | ||
// You may obtain a copy of the License at | ||
// | ||
// http://www.apache.org/licenses/LICENSE-2.0 | ||
// | ||
// Unless required by applicable law or agreed to in writing, software | ||
// distributed under the License is distributed on an "AS IS" BASIS, | ||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
// See the License for the specific language governing permissions and | ||
// limitations under the License. | ||
|
||
package v1alpha1 | ||
|
||
import ( | ||
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" | ||
) | ||
|
||
type VpcInfo struct { | ||
Name string | ||
Id string | ||
Tags map[string]string | ||
Cidrs []string | ||
} | ||
|
||
// +kubebuilder:object:root=true | ||
type Vpc struct { | ||
metav1.TypeMeta `json:",inline"` | ||
metav1.ObjectMeta `json:"metadata,omitempty"` | ||
|
||
Info VpcInfo `json:"spec,omitempty"` | ||
} | ||
|
||
// +kubebuilder:object:root=true | ||
// VpcList is a list of Vpc objects. | ||
type VpcList struct { | ||
metav1.TypeMeta `json:",inline"` | ||
metav1.ListMeta `json:"metadata,omitempty"` | ||
Items []Vpc `json:"items"` | ||
} |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.