storeid

package
v1.20.0 Latest Latest
Warning

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

Go to latest
Published: Sep 8, 2026 License: Apache-2.0 Imports: 8 Imported by: 1 module, 1 package

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package storeid contains middleware to inject and manage the store ID context.

Index

Constants

View Source
const (

	// StoreIDHeader represents the HTTP header name used to
	// specify the OpenFGA store identifier in API requests.
	StoreIDHeader string = "Openfga-Store-Id"
)

Variables

This section is empty.

Functions

func NewStreamingInterceptor

func NewStreamingInterceptor() grpc.StreamServerInterceptor

NewStreamingInterceptor creates a grpc.StreamServerInterceptor which injects store_id metadata into the RPC context if an RPC message is received with a GetStoreId method.

func NewUnaryInterceptor

func NewUnaryInterceptor() grpc.UnaryServerInterceptor

NewUnaryInterceptor creates a grpc.UnaryServerInterceptor which injects store_id metadata into the RPC context if an RPC message is received with a GetStoreId method.

func SetStoreIDInContext

func SetStoreIDInContext(ctx context.Context, req interface{})

SetStoreIDInContext sets the store ID in the provided context based on information from the request.

func StoreIDFromContext

func StoreIDFromContext(ctx context.Context) (string, bool)

StoreIDFromContext retrieves the store ID stored in the provided context.

Types

This section is empty.

Jump to

Keyboard shortcuts

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