Micro Services / Micro service architecture

Micro service architecture is a developing method that uses individual independent and deployable service modules to develop complex and large applications. Monolithic architecture can be considered as the opposite of the Micro service architecture. It uses Single unit to develop the whole application. One of the drawback of monolithic architecture is If there’s a requirement to apply changes to some functions, whole application has to built as a new version since the application developed as a single unit. Developing a large applications can be very complex with Monolithic architecture than micro service architecture. Since all the functions are within a single unit it can break the system while further development.

Fig 1 : monolithic vs Micro service

So that many large scale applications like Amazon , Ebay and Netflix use micro service architecture.

There are many frameworks available to write micro services and spring boot and Java Enterprise Edition(EE) are commonly use frameworks.

Fig 2: Popular Micro service frameworks

API (Application Programming interface)?

API (application program interface) uses to communicate between micro services. As a example most of the social media platform have their own APIs that allows external parties to use their features. Many websites allow users to register to the site via google accounts.

Fig 3: Social network API

Google allows developers to extract data using API without directly connecting to google databases or accessing source codes.

Fig 4: API Overall diagram

API Manager

API manage applications can be used to create , analyse and manage APIs.

Components of an API manager

API Gateway : Works as an proxy to intercept API requests and apply security policies.It also can be use to gather user statistics.

: Works as an proxy to intercept API requests and apply security policies.It also can be use to gather user statistics. Key Manager : API manager verify the validity of OAuth tokens and subscriptions.It also generates OAuth tokens.

API manager verify the validity of OAuth tokens and subscriptions.It also generates OAuth tokens. API Publisher : Allows to publish APIs and gather feedback on features, usage and quality.

Allows to publish APIs and gather feedback on features, usage and quality. API Store : API store allows to subscribe to APIs and interact with publishers.

Fig 5 : Wso2 API manager Overview

Type of API keys use in API manager

There are two types of API keys.

Access token that uses to identify and application

Access token that uses to identify the final user of the application and it uses parameters like Username, Grant type and Password.

There are many API manager applications like WSO2 API Manager, Azure API manager , Oracle API manager and Google.

References