News for hackers. Stuff that matters.
Re:Ports and Adapters Architecture by macca321 on Friday September 15, 2017 @06:26AM (#15255966)
OK, an example: a LOT of .NET/Java codebases have these (IMO smelly) constructs:

class FooService : IFooService{} interface IFooService {}

where there is an interface with a single implementation. In this case, the "service interface" isn't a port, because it's not actually decoupled from the domain.

It has the potential to be one, but only if the FooService is extracted, dereferenced from the domain, and the application composes the FooService.

Saying "we need to make this into a port and adapter" gets the point across very quickly.

There are no comments on this comment yet.