MCPcopy
hub / github.com/redis/go-redis / InitPoolHook

Method InitPoolHook

maintnotifications/manager.go:132–135  ·  view source on GitHub ↗

GetPoolHook creates a pool hook with a custom dialer.

(baseDialer func(context.Context, string, string) (net.Conn, error))

Source from the content-addressed store, hash-verified

130
131// GetPoolHook creates a pool hook with a custom dialer.
132func (hm *Manager) InitPoolHook(baseDialer func(context.Context, string, string) (net.Conn, error)) {
133 poolHook := hm.createPoolHook(baseDialer)
134 hm.pool.AddPoolHook(poolHook)
135}
136
137// setupPushNotifications sets up push notification handling by registering with the client's processor.
138func (hm *Manager) setupPushNotifications() error {

Calls 2

createPoolHookMethod · 0.95
AddPoolHookMethod · 0.65