grpcserver

package
v0.10.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 11, 2026 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Overview

Package grpcserver integrates ShiftLock ownership with gRPC unary interceptors.

Compiles without google.golang.org/grpc. Adapt Guard.Allow to your interceptor.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Guard

type Guard struct {
	Coordinator *shiftlock.Coordinator
	ClaimName   string
}

Guard checks claim ownership for RPC handlers.

func (Guard) Allow

func (g Guard) Allow(ctx context.Context) error

Allow returns nil when this generation owns the claim.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL