You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently implementation of MapBackData is tightly coupled to concrete types (flow.Identifier and flow.Entity) and does not leverage generics. This limits flexibility and type safety, especially as we move toward a more modular design for our BackData implementations. With the upcoming generics overhaul in BackData detailed in flow-go#7070, it is essential to update MapBackData to use generic type parameters. This change will decouple the implementation from fixed types and ensure consistency with the new BackData interface once flow-go#7070 is finalized.
Proposed Solution
Once the changes in flow-go#7070 are complete, refactor MapBackData to incorporate generic type parameters for both identifiers and entities. This will involve updating the underlying map and refactoring all its associated methods (such as Add, Remove, etc.) to use generics. The refactored implementation should continue to be non-thread-safe, with concurrency management delegated to the higher-level Backend, while fully conforming to the new BackData interface.
Defenition of done
MapBackData is refactored to use generic type parameters instead of the fixed flow.Identifier and flow.Entity.
Context
Currently implementation of MapBackData is tightly coupled to concrete types (
flow.Identifier
andflow.Entity
) and does not leverage generics. This limits flexibility and type safety, especially as we move toward a more modular design for our BackData implementations. With the upcoming generics overhaul in BackData detailed in flow-go#7070, it is essential to update MapBackData to use generic type parameters. This change will decouple the implementation from fixed types and ensure consistency with the new BackData interface once flow-go#7070 is finalized.Proposed Solution
Once the changes in flow-go#7070 are complete, refactor MapBackData to incorporate generic type parameters for both identifiers and entities. This will involve updating the underlying map and refactoring all its associated methods (such as
Add
,Remove
, etc.) to use generics. The refactored implementation should continue to be non-thread-safe, with concurrency management delegated to the higher-level Backend, while fully conforming to the new BackData interface.Defenition of done
flow.Identifier
andflow.Entity
.Related issues
#6703
#7070
The text was updated successfully, but these errors were encountered: