News Score: Score the News, Sort the News, Rewrite the Headlines

Gateway pattern for external service calls

No matter which language you’re writing your service in, it’s generally a good idea to separate your external dependencies from your business-domain logic. Let’s say your order service needs to make an RPC call to an external payment service like Stripe when a customer places an order.Usually in Go, people make a package called external or http and stash the logic of communicating with external services there. Then the business logic depends on the external package to invoke the RPC call. This i...

Read more at rednafi.com

© News Score  score the news, sort the news, rewrite the headlines · Built by Brad Jasper