Movatterモバイル変換


[0]ホーム

URL:


ringhash

package
v1.77.0Latest Latest
Warning

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

Go to latest
Published: Nov 17, 2025 License:Apache-2.0Imports:2Imported by:0

Details

Repository

github.com/grpc/grpc-go

Links

Documentation

Overview

Package ringhash (internal) contains functions and types that need to beshared by the ring hash balancer and other gRPC code (such as xDS)without being exported.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

funcSetXDSRequestHash

func SetXDSRequestHash(ctxcontext.Context, requestHashuint64)context.Context

SetXDSRequestHash adds the request hash to the context for use in Ring HashLoad Balancing using xDS route hash_policy.

funcXDSRequestHash

func XDSRequestHash(ctxcontext.Context) (uint64,bool)

XDSRequestHash returns the request hash in the context and true if it was setfrom the xDS config selector. If the xDS config selector has not set the hash,it returns 0 and false.

Types

typeLBConfig

type LBConfig struct {serviceconfig.LoadBalancingConfig `json:"-"`MinRingSizeuint64 `json:"minRingSize,omitempty"`MaxRingSizeuint64 `json:"maxRingSize,omitempty"`RequestHashHeaderstring `json:"requestHashHeader,omitempty"`}

LBConfig is the balancer config for ring_hash balancer.

Source Files

View all Source files

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f orF : Jump to
y orY : Canonical URL
go.dev uses cookies from Google to deliver and enhance the quality of its services and to analyze traffic.Learn more.

[8]ページ先頭

©2009-2025 Movatter.jp