I have been doing some research on the Hexagonal/Ports & Adapters architecture. For the most part, it makes a lot of sense. My initial understanding was that "Driver Ports" were to be implemented by the adapters in the implementing application. The more work I do on my application, it's becoming clear that this is not correct.
For a practical example, I have an OAuth2AuthorizationPort which defines a single piece of functionality.
public interface OAuth2AuthorizationPort {
OAuth2Account authorize(AuthorizationToken authorizationToken);
}
Where exactly would the implementation of this port exist? Would I have something like 'GoogleOAuth2AuthorizationAdapter' & 'GithubOAuth2AuthorizationAdapter'?
After doing a little more research it sounds like maybe I would have a single OAuth2AuthorizationPort implementation within the hexagon, and the calling application would use this (the interface) to interact with the application. Is this correct?