* Fix(context): add support for context.appLables and context.appAnnotations (#3463)
Signed-off-by: zxbyoyoyo <596908030@qq.com>
Signed-off-by: 朱晓兵 <596908030@qq.com>
* Fix: unit test
Signed-off-by: 朱晓兵 <596908030@qq.com>
* Fix: recover deleted field
Signed-off-by: 朱晓兵 <596908030@qq.com>
* Feat: support the mountPath parameter of trait-storage-secret is optional Signed-off-by: maxiangbo maxiangboo@cmbchina.com
Signed-off-by: fourierr <maxiangboo@qq.com>
* Feat: support the mountPath parameter of trait-storage is optional Signed-off-by: maxiangbo maxiangboo@cmbchina.com
Signed-off-by: fourierr <maxiangboo@qq.com>
It seems that the `issue-commands` workflow keeps failing.
This commit fixes the `issue-commands` workflow by bumping up the
action version and replacing `npm install` with `npm ci` for
reproducibility.
Refs: https://github.com/oam-dev/kubevela-github-actions/pull/11
Signed-off-by: Sunghoon Kang <hoon@linecorp.com>
* Feat: add auto clear data function for the memory cache
Signed-off-by: barnettZQG <barnett.zqg@gmail.com>
* Feat: add memory cache store
Signed-off-by: barnettZQG <barnett.zqg@gmail.com>
* Feat: add some test case for the utils package
Signed-off-by: barnettZQG <barnett.zqg@gmail.com>
* Feat: poll multi-cluster metrics and export to prometheus
Signed-off-by: zhukunshuai <jookunshuai@gmail.com>
* pass context to polling loop
Signed-off-by: zhukunshuai <jookunshuai@gmail.com>
* move metrics definition to montitor/metrics/multicluster.go
Signed-off-by: zhukunshuai <jookunshuai@gmail.com>
* remove pod usage metric and make reviewable
Signed-off-by: zhukunshuai <jookunshuai@gmail.com>
* revert the change of GetClusterMetricsFromMetricsAPI
Signed-off-by: zhukunshuai <jookunshuai@gmail.com>
* revert the change of GetClusterMetricsFromMetricsAPI
Signed-off-by: zhukunshuai <jookunshuai@gmail.com>
* Separate the polling logic into a function
Signed-off-by: zhukunshuai <jookunshuai@gmail.com>
* add start menber function
Signed-off-by: zhukunshuai <jookunshuai@gmail.com>
* make refreshPeriod a menber var
Signed-off-by: zhukunshuai <jookunshuai@gmail.com>
* fix typo
Signed-off-by: zhukunshuai <jookunshuai@gmail.com>
* Refactor: refactor multi cluster round trippers
Before adding more RoundTrippers, it would be better to expose common
logic in the utility package.
This commit exports `tryCancelRequest` at `utils` package, and make
`secretMultiClusterRoundTripper` implement `RoundTripperWrapper`
interface to allow chaining multiple round trippers.
Refs #3432
Signed-off-by: Sunghoon Kang <hoon@linecorp.com>
* Feat: reconcile app with scoped permissions
Currently, all Application resources are reconciled by the Roles bound
to the controller service account. This behavior gives us the power to
manage resources across multiple namespaces. However, this behavior can
be problematic in the soft-multitenancy environment.
This commit adds `serviceAccountName` to ApplicationSepc to reconcile
Application with the given service account for reconciling Application
with scoped permissions.
Refs #3432
Signed-off-by: Sunghoon Kang <hoon@linecorp.com>
* Refactor: extract context setter as method
https://github.com/oam-dev/kubevela/pull/3434#discussion_r825561603
Signed-off-by: Sunghoon Kang <hoon@linecorp.com>
* Feat: use annotation instead of spec
https://github.com/oam-dev/kubevela/issues/3432#issuecomment-1066460269
Signed-off-by: Sunghoon Kang <hoon@linecorp.com>
* Refactor: unify service account setter caller
https://github.com/oam-dev/kubevela/pull/3434#discussion_r825853612
Signed-off-by: Sunghoon Kang <hoon@linecorp.com>
* Refactor: rename GetServiceAccountName
https://github.com/oam-dev/kubevela/pull/3434#discussion_r826514565
Signed-off-by: Sunghoon Kang <hoon@linecorp.com>
* Feat: update api doc
Signed-off-by: barnettZQG <barnett.zqg@gmail.com>
* Feat: make the component list is in reverse order.
Signed-off-by: barnettZQG <barnett.zqg@gmail.com>
* Feat: update swagger config
Signed-off-by: barnettZQG <barnett.zqg@gmail.com>
* add doc-gen --local <LocalFile> and corresponding functions
Signed-off-by: Nicola115 <2225992901@qq.com>
* go format
Signed-off-by: Nicola115 <2225992901@qq.com>
* refactor the usage of vela def doc-gen from local file; refactor the function GenerateReferenceDoc
Signed-off-by: Nicola115 <2225992901@qq.com>
* gofmt and goimports
Signed-off-by: Nicola115 <2225992901@qq.com>
* update prompts info
Signed-off-by: Nicola115 <2225992901@qq.com>
* remove parseLocalDefinition struct, using ComponentDefinition instead
Signed-off-by: Nicola115 <2225992901@qq.com>
* standardize the function ParseLocalFile
Signed-off-by: Nicola115 <2225992901@qq.com>
* add unit test for ParseLocalFile
Signed-off-by: Nicola115 <2225992901@qq.com>
* remove redundant functions
Signed-off-by: Nicola115 <2225992901@qq.com>
* remove redundant lines and do goimports formatting
Signed-off-by: Nicola115 <2225992901@qq.com>