Win a copy of Head First Android this week in the Android forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Paul Clapham
  • Ron McLeod
  • Tim Cooke
  • Junilu Lacar
Sheriffs:
  • Rob Spoor
  • Devaka Cooray
  • Jeanne Boyarsky
Saloon Keepers:
  • Jesse Silverman
  • Stephan van Hulst
  • Tim Moores
  • Carey Brown
  • Tim Holloway
Bartenders:
  • Jj Roberts
  • Al Hobbs
  • Piet Souris

Modern API Development With Spring and Spring Boot

 
Ranch Hand
Posts: 515
2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi
What is the reactive paradigm and what are the roles of gRPC, and GraphQL ?
Explaining it is probably the reason for the book but do you have a short description of what their roles are in API development?
I don't know anything about those technologies or what they do.
Thank you,
Paul
 
Author
Posts: 16
5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Paul,

In the current environment, all systems are developed by keeping the integration with other services/systems in mind from day zero. Systems communicate with each other using APIs. API is a communication channel. You are using AWS services in your app, you need to consume AWS APIs. You want to use social feeds such as facebook/twitter in your app, you need to use their APIs. Social login solutions is also based on APIs. You are developing an HTML5 app, you need APIs. UI app consumes APIs and renders the data.

APIs developed to serve the request in a non-blocking, async way are part of the reactive paradigm. Reactive programming in Spring is facilitated by WebFlux, which supports fully non-blocking code. However, the programmer has to take special care of maintaining the non-blocking call. Reactive code allows you to use the resources such as CPU in an optimal way and gives you more throughput. Therefore, it is the preferred choice for cloud deployment. It also gives you added cost advantage.

gRPC is mostly used in backend systems, which are based on microservices. gRPC allows these microservices to communicate with each other.

GraphQL is another way to implement the APIs. It was developed by Facebook to increase the Facebook app performance on mobile devices. Later on, it was open-sourced and got popular among many leading tech companies.

Thanks,
Sourabh Sharma

 
paul nisset
Ranch Hand
Posts: 515
2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks Sourabh.
Can I assume that when people are talk about reactive programming in Spring ,it is the same as saying the  code makes asynchronous calls to an API or is there more to it than that?
Ultimately ,microservices communicate via http(s) protocol. So, I don't really understand what gRPC is or what problem it solves .

thanks,
Paul
 
Sourabh Sharma
Author
Posts: 16
5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

paul nisset wrote:Thanks Sourabh.
Can I assume that when people are talk about reactive programming in Spring ,it is the same as saying the  code makes asynchronous calls to an API or is there more to it than that?
Ultimately ,microservices communicate via http(s) protocol. So, I don't really understand what gRPC is or what problem it solves .

thanks,
Paul



Pure Non-blocking call is a key here like javascript. Spring supports it using WebFlux that makes use of Reactive libs.

gRPC has performance advantages over REST. gRPC Protobuf works on top of HTTP 2 and supports duplex (which isn't possible in REST) communication.
 
paul nisset
Ranch Hand
Posts: 515
2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
gRPC sounds interesting.
Thank you Sourabh.
 
reply
    Bookmark Topic Watch Topic
  • New Topic