Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Building APIs as micro-services

Building APIs as micro-services

A talk on micro-services by a friend at the Andela Institute.

Avatar for Ojengwa Bernard

Ojengwa Bernard

January 04, 2016
Tweet

More Decks by Ojengwa Bernard

Other Decks in Programming

Transcript

  1. If we wish to be technical, Micro-services are a software

    architecture style in which complex apps are composed of small independent processes communicating with each other. Micro-services implement the much talked about Single Responsibility Principle (SRP).
  2. Pros of Micro-services • Ease of Development. • Ease of

    Deployment. • Scalability. • Flexibility with Choice of Tools. • Ease of Maintenance.
  3. Cons of Micro-services • Costs more to start up. •

    Increased number of requests. • Takes more memory.
  4. Building APIs in the Micro-Service pattern requires two main layers:

    1. The Service/Resource APIs. 2. The Gateway API.
  5. • Micro-Service APIs can be used when you have a

    large API. • If you envision a large API, it is best to start by building in the Micro-services pattern.
  6. Note-Worthy • Service APIs may or may not be made

    public for consumption. • Cross Origin Resource Sharing (CORS) is a means of limiting access. • It is best practices to limit access to the Gateway API when building APIs in the Micro-service Pattern.