type ConfigSelector … type RPCInfo … type RPCConfig … type ClientStream … type ClientInterceptor … type ServerInterceptor … type csKeyType … const csKey … // SetConfigSelector sets the config selector in state and returns the new // state. func SetConfigSelector(state resolver.State, cs ConfigSelector) resolver.State { … } // GetConfigSelector retrieves the config selector from state, if present, and // returns it or nil if absent. func GetConfigSelector(state resolver.State) ConfigSelector { … } type SafeConfigSelector … // UpdateConfigSelector swaps to the provided ConfigSelector and blocks until // all uses of the previous ConfigSelector have completed. func (scs *SafeConfigSelector) UpdateConfigSelector(cs ConfigSelector) { … } // SelectConfig defers to the current ConfigSelector in scs. func (scs *SafeConfigSelector) SelectConfig(r RPCInfo) (*RPCConfig, error) { … }