February 26, 2018
Application Specific Error Handling
Go’s standard error is extremely simple to use which is a feature I like. It lets you add context by implementing its interface only when your application needs to. This can make cross boundary design simple and flexible.
An API/RPC web service might be a good illustration.
Some assumptions about this example are that your clients are mostly HTTP and care about the HTTP Status Code returned from the server. Also, that you are trying to separate your business logic from your web logic.
...
Read more