I am interested in why we might use one over the other, i.e. the pros and cons of these approaches.
From what I understood both provide fault-handling and Endpoint Resolution. My assumption is to use ReverseProxy for external clients (outside the cluster) and ServicePartitionClient within a cluster.
The reverse proxy works on the service side, as a gateway that routes Http requests to other services running inside the cluster. Reverse proxy users can be inside or outside the cluster.
Pro: Can be accessed by anyone who understands Http.
Con: Restricted to Http. Requires intimate knowledge about service name and partitioning strategy at the caller side.
The partition client runs client side, to call services. Depending on the underlying communication technology implemented by TCommunicationClient
, partition clients can be used inside or outside the cluster. (it's not restricted to Service Remoting)
You could write code that uses the partition client to call the reverse proxy with retry support.
Pro: Can be accessed by anyone who has the TCommunicationClient
.
Con: Requires intimate knowledge about service name and partitioning strategy at the caller side.