Identify component factories by identifier string
@kevinwallimann đang làm issue này rồi.
Từ ngày 19/2/2020.
Đánh giá
- Độ khó
- 4/5
- Thời gian dự kiến
- 3-5 ngày
- Mức phù hợp với người mới
- 28/100
- Loại issue
- Tính năng
- Độ rõ ràng
- Khá rõ ràng
- Mức độ hoạt động
- Đình trệ
- Công nghệ
- scala
- Lĩnh vực
- backend, developer-experience
Hướng nghiên cứu
Bắt đầu bằng cách đọc ComponentFactory và ClassLoaderUtils, cùng với phần công việc về SPI được tham chiếu trong #83. Nhiệm vụ là thêm getIdentifier với tên lớp làm giá trị mặc định, sau đó thay đổi việc tra cứu factory để tìm các factory do ServiceLoader cung cấp theo identifier. Được xem là hoàn tất khi các cấu hình hiện có dựa trên tên lớp vẫn hoạt động và các cấu hình có thể sử dụng một identifier ổn định thay thế.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Description
Currently, component factories are loaded in ClassLoaderUtils given their fully qualified classnames. The classname is passed by the configuration. (e.g. component.writer)
That means that components don't have the possibility to be refactored (renaming, moving to a different package) without introducing a breaking change which would require updating any existing configuration that uses that component.
Tasks
- Add a method
getIdentifier: Stringto the interfaceComponentFactory.getClass.getNamemay be used as a default value. (so this feature won't be a breaking change) - Implementing components are responsible for providing a unique identifier. It's advisable to prefix the identifier with a human readable name, because it will be referenced in the configuration, logged, etc..
- Use
getIdentifierto load the factory inClassLoaderUtils. Currently, it loads the class directly given the class name. This approach doesn't work to efficiently load the factory by the identifier. With #83, component factories can be loaded using the Service Provider Interface (SPI), i.e. withServiceLoader. All factories expose thegetIdentifiermethod, that's how it can be found
Other
- The same identifier might be used by each component to prefix its configuration properties to avoid name clashes.
- Ngôn ngữ chính
- Scala
- Star
- 47
- Fork
- 14
- Chỉ số merge pull request
- Không có pull request nào được merge trong 30 ngày
Hướng dẫn đóng góp
Chưa lập chỉ mục được hướng dẫn đóng góp cho kho mã nguồn này
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của AbsaOSS/hyperdrive
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 45/100
AbsaOSS/hyperdrive#269 ·
-
enhancement
Độ khó 5/5 Hơn một tuần Mức phù hợp với người mới 25/100
AbsaOSS/hyperdrive#240 ·
-
enhancement
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 42/100
AbsaOSS/hyperdrive#239 ·
-
bug
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 35/100
AbsaOSS/hyperdrive#230 ·
-
Atum integration Đang mở
Độ khó 5/5 Hơn một tuần Mức phù hợp với người mới 20/100
AbsaOSS/hyperdrive#211 · 1 bình luận · 1 reaction · 1 người được giao ·
Tất cả issue của AbsaOSS/hyperdrive
Issue tương tự
-
RS_PixelAsPoint raises out of grid where RS_PixelAsCentroid and RS_PixelAsPolygon extrapolate Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
-
Area: Excel support
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
orbeon/orbeon-forms#7893 ·
-
x:action/fix x:module/practice-exercise x:size/small
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
lichess-org/lila#21788 · 2 bình luận ·
-
area:Iceberg area:writer documentation requires-triage
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
apache/datafusion-comet#6147 ·