- Sort Score
- Result 10 results
- Languages All
Results 1 - 5 of 5 for NewListener (0.08 sec)
-
cni/pkg/pluginlistener/listener_test.go
"net" "path/filepath" "testing" "google.golang.org/grpc" "google.golang.org/grpc/credentials/insecure" ) func TestCNIListener(t *testing.T) { f := filepath.Join(t.TempDir(), "test") l, err := NewListener(f) if err != nil { t.Fatalf("unexpected error %v", err) } defer l.Close() conn, err := connect(f) if err != nil { t.Fatalf("failed to connect %v", err) } conn.Close() }
Registered: Wed Nov 06 22:53:10 UTC 2024 - Last Modified: Thu Feb 08 21:58:32 UTC 2024 - 1.4K bytes - Viewed (0) -
cni/pkg/pluginlistener/listener.go
// limitations under the License. package pluginlistener import ( "fmt" "net" "os" "path/filepath" "istio.io/istio/pkg/log" ) func NewListener(path string) (net.Listener, error) { // Remove unix socket before use. if err := os.Remove(path); err != nil && !os.IsNotExist(err) { // Anything other than "file not found" is an error.
Registered: Wed Nov 06 22:53:10 UTC 2024 - Last Modified: Fri Jan 26 20:34:28 UTC 2024 - 1.7K bytes - Viewed (0) -
cni/pkg/log/uds.go
func (l *UDSLogger) StartUDSLogServer(sockAddress string, stop <-chan struct{}) error { if sockAddress == "" { return nil } log.Debugf("starting UDS server for CNI plugin logs") unixListener, err := uds.NewListener(sockAddress) if err != nil { return fmt.Errorf("failed to create UDS listener: %v", err) } go func() { if err := l.loggingServer.Serve(unixListener); network.IsUnexpectedListenerError(err) {
Registered: Wed Nov 06 22:53:10 UTC 2024 - Last Modified: Fri Jun 28 19:12:54 UTC 2024 - 4.7K bytes - Viewed (0) -
internal/http/server.go
}) srv.listenerMutex.Lock() srv.Handler = wrappedHandler srv.listener = listener srv.listenerMutex.Unlock() var l net.Listener = listener if tlsConfig != nil { l = tls.NewListener(listener, tlsConfig) } serve = func() error { return srv.Server.Serve(l) } return } // Shutdown - shuts down HTTP server. func (srv *Server) Shutdown() error {
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Wed Jun 19 18:42:47 UTC 2024 - 6.1K bytes - Viewed (0) -
cni/pkg/nodeagent/cni-watcher.go
if s.sockAddress == "" { return fmt.Errorf("no socket address provided") } log.Infof("starting listener for CNI plugin events at %v", s.sockAddress) unixListener, err := pluginlistener.NewListener(s.sockAddress) if err != nil { return fmt.Errorf("failed to create CNI listener: %v", err) } go func() { err := s.cniListenServer.Serve(unixListener) select { case <-s.ctx.Done():
Registered: Wed Nov 06 22:53:10 UTC 2024 - Last Modified: Tue Jul 02 18:48:50 UTC 2024 - 6.7K bytes - Viewed (0)