package grpc-async

  1. Overview
  2. Docs

Description

Functionality for building gRPC services and rpcs with async.

Tags

network rpc serialisation

Published: 25 Oct 2023

README

OCaml gRPC

Pure OCaml implementation of gRPC over HTTP2.

Supported features:

  • RPCs: unary, server streaming, client streaming, bidirectional streaming

  • Client (Eio, Lwt and Async), server (Eio, Lwt and Async)

Getting Started

To get started, browse the documentation and the examples:

  • examples/greeter-{client,server}-{async,lwt,eio} implements a basic "Hello world" service using ocaml-protoc-plugin for Protobuf serialization

  • examples/greeter-{client-tls-async,server-ssl-lwt} showcases the greeter service over a secure connection

  • examples/etcd interfaces with an external etcd server and shows how to use ocaml-protoc-plugin for Protobuf serialization

  • examples/routeguide implements the "Route Guide" service using Eio and ocaml-protoc-plugin for Protobuf serialisation.

  • examples/routeguide-{client,server}-{async,lwt} showcases the Route Guide service using Async and LWT.

Tutorials

  • The helloworld tutorial provides a basic example of using gRPC with LWT, perfect for first time users!

  • The routeguide tutorial provides a complete example of using gRPC with Eio and all its features.

Acknowledgments

This MVP version of this library was built by @jeffa5. Andrew gratiously passed the baton to our team to develop it into a full fledged production-ready implementation.

Dependencies (6)

  1. stringext
  2. h2-async < "0.13.0"
  3. async >= "v0.16"
  4. grpc = version
  5. ocaml >= "4.11"
  6. dune >= "3.7"

Dev Dependencies (1)

  1. odoc with-doc

Used by (1)

  1. grpc-examples

Conflicts

None

OCaml

Innovation. Community. Security.