package
0.10.3
Repository: https://github.com/cloudwego/kitex.git
Documentation: pkg.go.dev

# Packages

Package callopt contains options that control the behavior of client on request level.
Package genericclient ...
No description provided by the author

# Functions

CallOptionInfoFromCtx retrieves the call Options debug information from the given context.
CallOptionsFromCtx retrieves call-Options from the given context.
ClientErrorHandlerWithAddr is ErrorHandler for client, which will add remote addr info into error.
DefaultClientErrorHandler is Default ErrorHandler for client when no ErrorHandler is specified with Option `client.WithErrorHandler`, this ErrorHandler will be injected.
NewClient creates a kitex.Client with the given ServiceInfo, it is from generated code.
NewCtxWithCallOptions returns a new context associated with the given call-Options.
NewServiceInlineClient creates a kitex.Client with the given ServiceInfo, it is from generated code.
WithACLRules adds ACL rules.
WithBackupRequest sets the backup request policy for client, it will take effect for all methods.
WithBoundHandler adds remote.BoundHandler for client.
WithCircuitBreaker adds a circuitbreaker suite for the client.
WithClientBasicInfo provides initial information for client endpoint in RPCInfo.
WithCloseCallbacks adds callback to Close.
WithCodec to set a codec that handle other protocols which not support by kitex.
WithConnectTimeout specifies the connection timeout.
WithConnMetric to enable reporting connection pool stats.
WithConnPool sets the connection pool.
WithConnReporterEnabled to enable reporting connection pool stats.
WithContextBackup enables local-session to retrieve context backuped by server, in case of user don't correctly pass context into next RPC call.
WithContextMiddlewares add middlewares into current ctx Every client receive this ctx will execute the middlewares.
WithDestService specifies the name of target service.
WithDiagnosisService sets the diagnosis service for gathering debug information.
WithDialer sets the Dialer for creating connections.
WithErrorHandler sets the error handler.
WithFailureRetry sets the failure retry policy for client, it will take effect for all methods.
WithFallback is used to set the fallback policy for the client.
WithFirstMetaHandler adds a MetaHandler.
WithFramedTransport to use framed transport Deprecated: Use WithTransportProtocol(transport.Framed) instead.
WithGeneric set Generic type for generic call.
WithGRPCConnPoolSize sets the value for the client connection pool size.
WithGRPCInitialConnWindowSize sets the value for initial window size on a connection of grpc.
WithGRPCInitialWindowSize sets the value for initial window size on a grpc stream.
WithGRPCKeepaliveParams returns a DialOption that specifies keepalive parameters for the client transport.
WithGRPCMaxHeaderListSize returns a DialOption that specifies the maximum (uncompressed) size of header list that the client is prepared to accept.
WithGRPCReadBufferSize lets you set the size of read buffer, this determines how much data can be read at most for each read syscall.
WithGRPCTLSConfig sets the TLS config for gRPC client.
WithGRPCWriteBufferSize determines how much data can be batched before doing a write on the wire.
WithHostPorts specifies the target instance addresses when doing service discovery.
WithHTTPConnection specifies client use RPC over http.
WithHTTPResolver specifies resolver for url (which specified by WithURL).
WithInstanceMW adds middleware for client to handle request after service discovery and loadbalance process.
WithLoadBalancer sets the loadbalancer for client.
WithLogger sets the Logger for kitex client.
WithLongConnection enables long connection with kitex's built-in pooling implementation.
WithMetaHandler adds a MetaHandler.
WithMiddleware adds middleware for client to handle request.
WithMiddlewareBuilder adds middleware that depend on context for client to handle request.
WithMuxConnection specifies the transport type to be mux.
WithPayloadCodec to set a payloadCodec that handle other payload which not support by kitex.
WithProxy sets the forward Proxy for client.
WithResolver provides the Resolver for kitex client.
WithRetryContainer sets Container.
WithRetryMethodPolicies sets the retry policy for method.
WithRPCTimeout specifies the RPC timeout.
WithShortConnection forces kitex to close connection after each call is finished.
WithSpecifiedResultRetry is used with FailureRetry.
WithStatsLevel sets the stats level for client.
WithSuite adds an option suite for client.
WithTag sets the customize tag for service discovery, eg: idc, cluster.
WithTimeoutProvider adds a TimeoutProvider to the client.
WithTracer adds a tracer to client.
WithTransHandlerFactory sets the TransHandlerFactory for client.
WithTransportProtocol sets the transport protocol for client.
WithWarmingUp forces the client to do some warm-ups at the end of the initialization.
WithXDSSuite is used to set the xds suite for the client.

# Interfaces

Client is the core interface abstraction of kitex client.
No description provided by the author
No description provided by the author
Streaming client streaming interface for code generate.
A Suite is a collection of Options.

# Type aliases

Option is the only way to config client.
Options is used to initialize a client.