Categorygithub.com/un000/grpc-snappy
modulepackage
1.1.0
Repository: https://github.com/un000/grpc-snappy.git
Documentation: pkg.go.dev

# README

How to use

At the server side, you need to import package to run initializer

import _ "github.com/un000/grpc-snappy"

At the client use DialOptions:

    var dialOpts = []grpc.DialOption{
        grpc.WithInsecure(),
        grpc.WithDefaultCallOptions(grpc.UseCompressor(snappy.Name)),
    }

    conn, err := grpc.Dial(
        "your-grpc-address:port",
        dialOpts...,
    )

For more information, please visit the official docs: https://github.com/grpc/grpc-go/blob/master/Documentation/compression.md

# Constants

Name is the name registered for the snappy compressor.