mu-protobuf-0.1.0.0: Protocol Buffers serialization and gRPC schema import for Mu microservices

Safe HaskellNone
LanguageHaskell2010

Mu.Quasi.GRpc

Description

Read .proto files as a Schema and a set of Services. The origin of those .proto files can be local (if using grpc) or come from a Compendium Registry (if using compendium).

Synopsis

Documentation

grpc :: String -> (String -> String) -> FilePath -> Q [Dec] Source #

Reads a .proto file and generates: * A Schema with all the message types, using the name given as first argument. * A Service declaration for each service in the file, where the name is obtained by applying the function given as second argument to the name in the file.

compendium :: String -> (String -> String) -> String -> String -> Q [Dec] Source #

Obtains a schema and service definition from Compendium, and generates the declarations from grpc.