Documentation ¶
Index ¶
- func CleanExpiredProjectInfo(expiredTimeSeconds int64)
- func CleanExpiredProjectInfoJob(expiredTimeSeconds int64)
- func FetchUserProjectList(token string, url string) []string
- func GetAllManagedClusterLabelNames() map[string]bool
- func GetAllManagedClusterNames() map[string]string
- func GetManagedClusterEventHandler() cache.ResourceEventHandlerFuncs
- func GetManagedClusterLabelAllowListEventHandler(kubeClient kubernetes.Interface) cache.ResourceEventHandlerFuncs
- func GetUserName(token string, url string) string
- func GetUserProjectList(token string) ([]string, bool)
- func InitAllManagedClusterLabelNames()
- func InitAllManagedClusterNames()
- func InitScheduler()
- func InitUserProjectInfo()
- func ModifyMetricsQueryParams(req *http.Request, reqUrl string)
- func ScheduleManagedClusterLabelAllowlistResync(kubeClient kubernetes.Interface)
- func StopScheduleManagedClusterLabelAllowlistResync()
- func UpdateUserProject(up UserProject)
- func WatchManagedCluster(clusterClient clusterclientset.Interface, kubeClient kubernetes.Interface)
- func WatchManagedClusterLabelAllowList(kubeClient kubernetes.Interface)
- type UserProject
- type UserProjectInfo
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CleanExpiredProjectInfo ¶
func CleanExpiredProjectInfo(expiredTimeSeconds int64)
func CleanExpiredProjectInfoJob ¶
func CleanExpiredProjectInfoJob(expiredTimeSeconds int64)
func FetchUserProjectList ¶
func GetAllManagedClusterLabelNames ¶
GetAllManagedClusterLabelNames returns all managed cluster labels.
func GetAllManagedClusterNames ¶
GetAllManagedClusterNames returns all managed cluster names.
func GetManagedClusterEventHandler ¶
func GetManagedClusterEventHandler() cache.ResourceEventHandlerFuncs
GetManagedClusterEventHandler return event handler functions for managed cluster watch events.
func GetManagedClusterLabelAllowListEventHandler ¶
func GetManagedClusterLabelAllowListEventHandler(kubeClient kubernetes.Interface) cache.ResourceEventHandlerFuncs
GetManagedClusterLabelAllowListEventHandler return event handler for managedcluster label allow list watch event.
func GetUserName ¶
func GetUserProjectList ¶
func InitAllManagedClusterLabelNames ¶
func InitAllManagedClusterLabelNames()
InitAllManagedClusterLabelNames initializes all managed cluster labels map.
func InitAllManagedClusterNames ¶
func InitAllManagedClusterNames()
InitAllManagedClusterNames initializes all managed cluster names map.
func InitScheduler ¶
func InitScheduler()
func InitUserProjectInfo ¶
func InitUserProjectInfo()
func ModifyMetricsQueryParams ¶
ModifyMetricsQueryParams will modify request url params for query metrics.
func ScheduleManagedClusterLabelAllowlistResync ¶
func ScheduleManagedClusterLabelAllowlistResync(kubeClient kubernetes.Interface)
func StopScheduleManagedClusterLabelAllowlistResync ¶
func StopScheduleManagedClusterLabelAllowlistResync()
func UpdateUserProject ¶
func UpdateUserProject(up UserProject)
func WatchManagedCluster ¶
func WatchManagedCluster(clusterClient clusterclientset.Interface, kubeClient kubernetes.Interface)
WatchManagedCluster will watch and save managedcluster when create/update/delete managedcluster.
func WatchManagedClusterLabelAllowList ¶
func WatchManagedClusterLabelAllowList(kubeClient kubernetes.Interface)
WatchManagedClusterLabelAllowList will watch and save managedcluster label allowlist configmap when create/update/delete.
Types ¶
type UserProject ¶
func NewUserProject ¶
func NewUserProject(userName string, token string, projects []string) UserProject
type UserProjectInfo ¶
type UserProjectInfo struct { sync.RWMutex ProjectInfo map[string]UserProject }