0

I am testing Azure Spring Cloud with GRPC Server. One of the requirement of GRPC is to communicate using HTTP/2.

Does Azure Spring Cloud works with HTTP2?

I tried the following scenarios:

1.) Shutdown Internal tomcat of Springboot by setting WebApplicationType to None and map server.port to grpc.port. This setup works locally but when I deployed in Azure Spring Cloud the client connects to service endpoint using https. When it reaches the GRPC Server (app) then it downgraded to HTTP/1. The server is having a lot of PROTOCOL_ERROR issues because the connection is http/1 and GRPC Server expecting it to be http/2.

2.) Use Spring Cloud Gateway and redirect the traffic internally to GRPC Server. To use http2 on Spring Cloud Gateway I enabled certificate on GRPC Server and on Gateway. When the client connects to service app (Gateway that has GRPC Server) when it reached the gateway there are some NotSSLRecordException. Locally this works, but when it deploys to Azure Spring Cloud it does not work. Maybe because the Azure Spring Cloud app service endpoint wraps it with its own certificate when it redirects to the app service (gateway instance with GRPC Server) then the connection become non-ssl/tls anymore. And the gateway cannot process the request because of NotSSLRecordException issue.

Erv
  • 1

1 Answers1

0

Azure Spring Apps supports using GRPC now.

Enable gRPC in Azure Spring Apps Portal

You can find more details about Azure Spring App GRPC feature in this doc: https://learn.microsoft.com/en-us/azure/spring-apps/how-to-configure-ingress?tabs=azure-portal#faq

As to HTTP/2 support, Azure Spring Apps only support direct calls from app to app, not supported requests through ingress to app.

For gRPC, once the ingress settings are set, gRPC will be supported from request through ingress to app too.

Jeremy Caney
  • 7,102
  • 69
  • 48
  • 77
hanli
  • 91
  • 2