For PUT requests, the library will parse both the x-grpc-route-data and x-grpc-body-data upstream headers and merges them into a single JSON object to be sent to the appropriate gRPC service. For DELETE requests, the parser for GET requests is used (where only x-grpc-route-data is parsed).
To help test these new features, I've added an UpdateProduct method and a DeleteProduct method in the Product gRPC service. The Ocelot configuration and appsettings in the OcelotGateway sample project have also been updated to recognise these new methods. The methods can be accessed by making a PUT or DELETE request to /products/{id}.
For PUT requests, the library will parse both the
x-grpc-route-data
andx-grpc-body-data
upstream headers and merges them into a single JSON object to be sent to the appropriate gRPC service. For DELETE requests, the parser for GET requests is used (where onlyx-grpc-route-data
is parsed).To help test these new features, I've added an
UpdateProduct
method and aDeleteProduct
method in the Product gRPC service. The Ocelot configuration and appsettings in the OcelotGateway sample project have also been updated to recognise these new methods. The methods can be accessed by making aPUT
orDELETE
request to/products/{id}
.Closes #6.