Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create rfc-03.md #262

Open
wants to merge 2 commits into
base: version-3.0.0
Choose a base branch
from
Open

Create rfc-03.md #262

wants to merge 2 commits into from

Conversation

miere
Copy link

@miere miere commented Mar 20, 2019

Provide a simple, but versatile, way to map Rest endpoints in a RPC fashion.

RFC Draft

https://github.com/Skullabs/kikaha/blob/rfc-3-RPC-like-Rest-API/docs/rfc/rfc-03.md

Motivation

There's a lot of discussion about using RPC or Rest endpoint to expose microservice APIs. If we decide to pick one or another, this decision should be done wisely by considering the pros and cons from both approaches. By observing the most common Java web frameworks, it's clear that Rest APIs has been the prefered approach - probably because Rest has been seen as good replacement for SOAP and many people think about RPC as a modern SOAP.

Below are some points that draw my attention in my quick research about this topic. It reforces my previous experience on this regard by high lighting why RPC is a better approach. It worth notice though that not taking REST into account would would be seen as an irresponsible approach, once it also have some positive points.

REST Pros (and RPC cons)

  • Semantics are well-known. So you don’t have to teach much things.
  • Schema is explicit. Easier to understand.

RPC Pros (and REST cons)

  • Dealing with irregular data and exceptional situations.
  • Dealing with operation without data.
  • Quickstart. You don’t have to design full schema from first.
  • Fine gained control. You can represent whatever level of operation you need.
  • Gradual improvement. It’s easier to deprecate single function.

Source: https://qr.ae/TW8y5n

@miere miere self-assigned this Mar 20, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant