Permalink
Browse files

update docs

  • Loading branch information...
stevehu committed Mar 16, 2018
1 parent 24fc4bc commit 9f8d1a1d8ce51513419f40fecda6fe9187b1c3f0
Showing with 16 additions and 16 deletions.
  1. +16 −16 content/architecture/category.md
@@ -16,12 +16,12 @@ draft: false
When an organization pursues microservices, the services/APIs can be grouped
into the following categories. For each category, certain microservice style
is more suitable than others. There are several ways to categorize APIs and
is more suitable than others. There are several ways to categorize APIs, and
here we differentiate APIs by visibility.
## Open Web APIs
This is also called public API. APIs in this category have public routes and
Open Web API is also called public API. APIs in this category have public routes which
can be accessed from anywhere. Companies want to bring their business online
to attract developers to build applications against their public APIs. In this
way, they can extend their business and reach more customers than before.
@@ -33,7 +33,7 @@ by almost every developer and support almost every language. It is the most matu
technology and has support from a lot of commercial infrastructure and tools.
[light-rest-4j][] is designed to build microservices in RESTful style on top of
OpenAPI specification with most cross-cutting concerns addressed and allow developers
OpenAPI specification with most cross-cutting concerns addressed and allowed developers
to focus on the domain business logic only.
The drawback for RESTful interaction style is its complexity in the specification and
@@ -44,15 +44,15 @@ lost. The server has to transform the URI into data model with the help of Swagg
specification. The response reverses the same process. That is the reason Swagger
specification is so complicated and very hard to write compare with other IDLs.
#### Graphql
#### GraphQL
Since Facebook open-sourced Graphql, it is getting popular in the open source community
very fast and some companies start to adopt it to replace RESTful APIs for public
APIs. Github.com is one of the examples as they are moving to Graphql from Restful.
Since Facebook open-sourced GraphQL, it is getting popular in the open source community
very fast, and some companies start to adopt it to replace RESTful APIs for public
APIs. Github.com is one of the examples as they are moving to GraphQL from Restful.
[light-graphql-4j][] is designed to build GraphQL API with GraphQL IDL(Interface
Definition Language). Developers just need to wire in the domain logic into the
generated graphql schema to make the API works. Sometimes, Graphql APIs will be
generated graphql schema class to make the API works. Sometimes, GraphQL APIs can be
used as an aggregate API in front of several RESTful or Hybrid APIs to serve
different consumers like Web Server, Native Mobile and Single Page Application
on Browser.
@@ -70,7 +70,7 @@ to the close relationship.
Rest is very popular with this type of APIs.
#### Graphql
#### GraphQL
GraphQL is gaining traction in certain business scenarios.
@@ -82,15 +82,15 @@ RESTful.
[light-hybrid-4j][] is designed to build RPC based microservices. Also, it allows you
to build modularized monolithic services as well. You can build a monolithic service
in the beginning and then split one or more hot services to another instance easily. In
addition, it is a serverless framework and will be the cornerstone of lightapi.net
addition, it is a serverless framework and the cornerstone of lightapi.net
hosting platform.
## Internal APIs
Internal APIs will only be used within the same organization and service might be shared
Internal APIs should only be used within the same organization and service might be shared
between LOBs. These APIs can only be accessed from servers within our data center or private cloud. We still
follow best practices like load balancing etc, but we don't provide any public routes to
follow best practices like load balancing etc., but we do not provide any public routes to
these APIs.
#### Rest
@@ -120,10 +120,10 @@ data synch between them.
[light-eventuate-4j][] is designed to build microservices based on messaging, Event
Sourcing and CQRS on top of Kafka. The interaction style is asynchronous which is based
on domain events and will ensure data consistency eventually. Combining with [light-saga-4j][],
on domain events and ensures data consistency eventually. Combining with [light-saga-4j][],
it can handle distributed transactions between multiple services.
Basically, light-eventuate-4j is a [service mesh][] that is deployed in an organization
Light-Eventuate-4j is a [service mesh][] that is deployed in an organization
as infrastructure service to support microservices. All services still need to be built
with light-rest-4j, light-graphql-4j or light-hybrid-4j to serve consumers but underline
communication between services is done through light-eventuate-4j and transaction orchestration
@@ -137,7 +137,7 @@ shared.
#### Rest
Rest is very popular with this type of APIs but it is not very efficient.
Rest is very popular with this type of APIs, but it is not very efficient.
#### GraphQL
@@ -152,7 +152,7 @@ recommended.
#### Eventuate
Like Internal APIs, Eventual consistency with messaging, event sourcing and CQRS can
be used to glue all services/APIs together. And light-saga-4j can be used to orchestrate
be used to glue all services/APIs together. Moreover, light-saga-4j can be used to orchestrate
distributed transactions between services.
[light-rest-4j]: /style/light-rest-4j/

0 comments on commit 9f8d1a1

Please sign in to comment.