90poe enterprise software requires us to apply specific design principles. In short, these are DDD, Solid, and clean code.
To practically implement those ideas, we follow hexagonal architecture.
I believe this file https://github.com/sergripenko/port_service/blob/main/internal/service/port/repository/mem/port.go, should not be part of the port package. Could you please try to extract it into a repository package? Which would allow us to implement, in the future, a second repository implementation which follows the port package interface for the repository?
Implementing this change would deliver a stronger separation of concerns.
90poe enterprise software requires us to apply specific design principles. In short, these are DDD, Solid, and clean code. To practically implement those ideas, we follow hexagonal architecture. I believe this file https://github.com/sergripenko/port_service/blob/main/internal/service/port/repository/mem/port.go, should not be part of the port package. Could you please try to extract it into a repository package? Which would allow us to implement, in the future, a second repository implementation which follows the port package interface for the repository? Implementing this change would deliver a stronger separation of concerns.