Skip to content

huangjunwen/nproto

Repository files navigation

NProto

Go Report Card Build Status codecov

Easy to use communication (e.g. rpc/msg/...) components.

This is the second major version (v2). Compare to v1, v2 has re-designed high level interfaces: Though it's still mainly focus on nats + protobuf, but it's not force to. It's totally ok for implementations to use other encoding schemas (e.g. json, msgpack ...) or use other transports (e.g. http).

Packages

  • rpc: High level types/interfaces for rpc server/client implementations.
  • msg: High level types/interfaces for msg publisher/subscriber implementations.
  • md: Meta data types.
  • enc: Data encoding/decoding type.
  • natsrpc: Rpc server/client implementation using nats as transport.
  • stanmsg: Auto reconnection/resubscription client for nats-streaming and msg publisher/subscriber implementation.
  • binlogmsg: 'Publish' (store) messages to MySQL8 tables then flush to downstream publisher using binlog notification.
  • tracing: Opentracing middlewares.
  • protoc-gen-nproto2: Stub code generator for protobuf.

Examples

See examples directory.