Make AuthorizationPolicy spec usable with controller-gen
メンテナーはふだん 1 日以内に返信
まだ誰も着手していません。
評価
調査の方向性
security/v1beta1/authorization_policy.pb.go を読み、エクスポートされた ActionDetail プロパティと既存の GetActionDetail メソッドに注目します。埋め込まれた AuthorizationPolicy spec を使用して kubebuilder または controller-tools で失敗を再現し、コピーした型を必要とせずに controller-gen が処理できるアプローチを決定するとともに、公開プロパティの呼び出し元との互換性を考慮します。
索引モデルが issue の本文から書いたものです。
説明
Describe the feature request
The AuthorizationPolicy spec (security/v1beta1/authorization_policy.pb.go) go type can't be used with controller-tools
If I try to create a CRD with kubebuilder / controller-tools that embeds an AuthorizationPolicy spec as part of my CRD object, I have to create my own copy of the existing type, which adds more work to translate it to an actual AuthorizationPolicy later on.
The reason this fails is that the type has an ActionDetail property which lacks any json tag.
This is because this property is not part of the CRD itself I believe. However, controller-tools at best allows to ignore private properties from a type but not public properties. So it fails to create the CRD object.
One option would be to make ActionDetail private (actionDetail - there is already a GetActionDetail method defined) but this is an interface change that would likely introduce breakages in existing code if they access that property directly
Describe alternatives you've considered
Alternative is to create a "copy" of the type and create methods to get an istio AuthorizationPolicy object out of the clone type
Affected product area (please put an X in all that apply)
[ ] Configuration Infrastructure
[ ] Docs
[ ] Installation
[ ] Networking
[ ] Performance and Scalability
[ ] Policies and Telemetry
[ ] Security
[ ] Test and Release
[ ] User Experience
Additional context
- 主要言語
- Go
- スター
- 523
- フォーク
- 623
- 平均マージ
- 5日 20時間
- マージ済み PR(30日)
- 4
環境構築
このプロジェクトの開発コンテナを、あなたの GitHub アカウントでブラウザ上に起動します。
- Dockerfile・Docker Compose ファイルなし
- プルリクエストのテンプレートなし
- コントリビューションガイドを読む
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
istio/api のほかの issue
-
Gateway CRD accepts both credentialName and tlsCertificates in server TLS settings対応中かも @RaphaelFakhri が 23 日前に担当しました。 オープンarea/networking area/user experience
難易度 2/5 1〜3時間 初心者へのやさしさ 35/100
メンテナーはふだん 1 日以内に返信
-
area/user experience kind/docs kind/enhancement
難易度 5/5 1週間以上 初心者へのやさしさ 40/100
メンテナーはふだん 1 日以内に返信
-
area/networking area/user experience kind/docs kind/enhancement
難易度 5/5 1週間以上 初心者へのやさしさ 45/100
メンテナーはふだん 1 日以内に返信
-
[release-1.29] change default of statsCompression to true再び着手できるかも @keithmattix が 304 日前に担当しましたが、オープン中のプルリクエストはありません。 オープン
メンテナーはふだん 1 日以内に返信
-
難易度 3/5 1〜2日 初心者へのやさしさ 45/100
メンテナーはふだん 1 日以内に返信
似ている issue
-
bug raised-by:verifier to:worker
難易度 2/5 1〜3時間 初心者へのやさしさ 88/100
medici-finance/assay#7835 ·
メンテナーはふだん 1 日以内に返信
-
bug
難易度 2/5 1〜3時間 初心者へのやさしさ 84/100
golang-malawi/qatarina#496 ·
メンテナーはふだん 2 日以内に返信
-
hive size:simple
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
メンテナーはふだん 1 日以内に返信
-
documentation stage:review
難易度 1/5 1〜3時間 初心者へのやさしさ 70/100
メンテナーはふだん 1 日以内に返信
-
Type/Bug
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
wso2/identity-customer-data-service#430 ·
メンテナーはふだん 1 日以内に返信