# `GRPC.Service`
[🔗](https://github.com/elixir-grpc/grpc_core/blob/v1.0.1/lib/grpc/service.ex#L1)

Define gRPC service used by Stub and Server. You should use `Protobuf` to
to generate code instead of using this module directly.

It imports DSL functions like `rpc/4` and `stream/1` for defining the RPC
functions easily:

    defmodule Greeter.Service do
      use GRPC.Service, name: "helloworld.Greeter"

      rpc :SayHello, HelloRequest, stream(HelloReply)
    end

`option (google.api.http)` annotations are supported for gRPC http/json transcoding. Once generated the 4th argument to `rpc/4` contains
the `Google.Api.HttpRule` option.

    defmodule Greeter.Service do
      use GRPC.Service, name: "helloworld.Greeter"

      rpc(:SayHello, Helloworld.HelloRequest, Helloworld.HelloReply, %{
        http: %{
          type: Google.Api.PbExtension,
          value: %Google.Api.HttpRule{
            __unknown_fields__: [],
            additional_bindings: [],
            body: "",
            pattern: {:get, "/v1/greeter/{name}"},
            response_body: "",
            selector: ""
          }
        }
      })
    end

# `format_function_name`

Format the function name for display/logging purposes.

If there's a name collision, returns "call(:Name, ...)" format to reflect actual usage.
Otherwise, returns the underscored name.

Handles both full 4-element RPC tuples and partial tuples (for testing).

# `grpc_type`

# `rpc`
*macro* 

# `rpc_options`

# `rpc_options`

# `stream`

Specify if the request/reply is streaming.

---

*Consult [api-reference.md](api-reference.md) for complete listing*
