Reusing code between resources
還沒有人認領這個 Issue。
評估
- 難度
- 5/5
- 預估耗時
- 一週以上
- 新手友好度
- 25/100
- Issue 類型
- 功能
- 描述清晰度
- 需要釐清
- 活躍度
- 停滯
- 技術堆疊
- java
- 領域
- build-system, tooling
研究方向
從 Translator.java 和 HandlerUtils.java 中連結的 AWS IoT 範例開始,著重於資源 Maven 專案之間重複的例外轉換和 listTags 方法。接著檢查此 Java 外掛程式如何產生個別專案,並判斷是否能支援共用程式碼。完成標準是記錄或實作一種具體的方法來重複使用這些處理常式。
由索引模型根據 Issue 內容生成。
描述
Hi, I'm from AWS IoT, we have a question/feature request.
Our handlers across different resources use the same code for exception translations and listing resource tags. These resources reside in the same GitHub repository, yet, since each resource has its own Maven project, we're unable to reuse that common code and haven't seen solutions in other repositories.
Specific examples from our AWS IoT repo (code is still in PRs):
- Exception translation code - link. We have this method in the Translator class for each resource.
listTagsmethod (calls IoT::ListTagsForResource) - link.
For both of these, we're able to reuse the code between handlers for the same resource, but we had to copy paste this piece of code for each resource.
Is there a solution available for our use case?
- 主要語言
- Java
- 星號
- 30
- 分支
- 48
- PR 合併指標
- 30 天內沒有已合併 PR
環境準備
從這裡開始
- 先讀完整個 Issue,再讀專案的貢獻指南。
- 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
- Fork 儲存庫,在一個分支上完成修改。
- 送出 Pull Request,並在描述裡引用這個 Issue 編號。
aws-cloudformation/cloudformation-cli-java-plugin 的其他 Issue
-
難度 4/5 3-5 天 新手友好度 25/100
aws-cloudformation/cloudformation-cli-java-plugin#415 · 1 則留言 ·
-
難度 4/5 3-5 天 新手友好度 42/100
-
難度 5/5 一週以上 新手友好度 25/100
-
難度 4/5 3-5 天 新手友好度 20/100
-
injectCredentialsAndInvokeV2 method in proxy class doesn't support API's like PutObject from S3.未關閉
難度 5/5 一週以上 新手友好度 25/100
查看 aws-cloudformation/cloudformation-cli-java-plugin 的全部 Issue
相似的 Issue
-
bug
難度 2/5 1-3 小時 新手友好度 84/100
維護者通常 1 天內回覆
-
bug
難度 2/5 1-3 小時 新手友好度 82/100
維護者通常 1 天內回覆
-
ci-failure-cause test-failure
難度 2/5 1-3 小時 新手友好度 72/100
維護者通常 1 天內回覆
-
enhancement
難度 2/5 1-3 小時 新手友好度 65/100
nextcloud/notes-android#3367 ·
維護者通常 1 天內回覆
-
:wave: team-triage a:chore in:isolated-projects in:kotlin-dsl
難度 2/5 1-3 小時 新手友好度 78/100
維護者通常 1 天內回覆