Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 12 for Subscriber (0.23 sec)

  1. internal/pubsub/pubsub.go

    			default:
    			}
    		}
    	}
    }
    
    // Subscribe - Adds a subscriber to pubsub system
    func (ps *PubSub[T, M]) Subscribe(mask M, subCh chan T, doneCh <-chan struct{}, filter func(entry T) bool) error {
    	totalSubs := atomic.AddInt32(&ps.numSubscribers, 1)
    	if ps.maxSubscribers > 0 && totalSubs > ps.maxSubscribers {
    		atomic.AddInt32(&ps.numSubscribers, -1)
    		return fmt.Errorf("the limit of `%d` subscribers is reached", ps.maxSubscribers)
    	}
    	ps.Lock()
    Go
    - Registered: Sun Apr 21 19:28:08 GMT 2024
    - Last Modified: Tue Feb 06 16:57:30 GMT 2024
    - 5.2K bytes
    - Viewed (0)
  2. internal/pubsub/pubsub_test.go

    		t.Fatalf("want %d subscribers, got %d", want, got)
    	}
    	if want, got := int32(2), ps.NumSubscribers(Mask(2)); got != want {
    		t.Fatalf("want %d subscribers, got %d", want, got)
    	}
    	if want, got := int32(2), ps.NumSubscribers(Mask(1|2)); got != want {
    		t.Fatalf("want %d subscribers, got %d", want, got)
    	}
    	if want, got := int32(2), ps.NumSubscribers(MaskAll); got != want {
    		t.Fatalf("want %d subscribers, got %d", want, got)
    	}
    Go
    - Registered: Sun Apr 21 19:28:08 GMT 2024
    - Last Modified: Thu Jan 18 07:03:17 GMT 2024
    - 5.8K bytes
    - Viewed (0)
  3. cmd/consolelogger.go

    // for this node or peers
    func (sys *HTTPConsoleLoggerSys) HasLogListeners() bool {
    	return sys != nil && sys.pubsub.Subscribers() > 0
    }
    
    // Subscribe starts console logging for this node.
    func (sys *HTTPConsoleLoggerSys) Subscribe(subCh chan log.Info, doneCh <-chan struct{}, node string, last int, logKind madmin.LogMask, filter func(entry log.Info) bool) error {
    	// Enable console logging for remote client.
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Fri Feb 02 00:13:57 GMT 2024
    - 5.4K bytes
    - Viewed (0)
  4. docs/bucket/notifications/README.md

          if c.NatsConn() != nil {
           c.NatsConn().Close()
          }
          _ = c.Close()
         }))
         if stanConnection != nil {
          subscribe()
         }
    
        }
       }
    
      }()
     }))
    
     // Subscribe to subject
     subscribe()
    
     // Keep the connection alive
     runtime.Goexit()
    }
    
    ```
    
    ```
    go run nats.go
    2017/07/07 11:47:40 Connected
    Plain Text
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Thu Jan 18 07:03:17 GMT 2024
    - 84K bytes
    - Viewed (2)
  5. cmd/peer-rest-server.go

    	// Listen Publisher uses nonblocking publish and hence does not wait for slow subscribers.
    	// Use buffered channel to take care of burst sends or slow w.Write()
    	ch := make(chan event.Event, globalAPIConfig.getRequestsPoolCapacity())
    	err := globalHTTPListen.Subscribe(mask, ch, ctx.Done(), func(ev event.Event) bool {
    		if ev.S3.Bucket.Name != "" && values.Get(peerRESTListenBucket) != "" {
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Thu Apr 04 12:04:40 GMT 2024
    - 51.8K bytes
    - Viewed (0)
  6. cmd/http-tracer.go

    		reqStartTime := time.Now().UTC()
    		h.ServeHTTP(respRecorder, r)
    		reqEndTime := time.Now().UTC()
    
    		if globalTrace.NumSubscribers(madmin.TraceS3|madmin.TraceInternal) == 0 {
    			// no subscribers nothing to trace.
    			return
    		}
    
    		tt := madmin.TraceInternal
    		if strings.HasPrefix(tc.FuncName, "s3.") {
    			tt = madmin.TraceS3
    		}
    
    		// Calculate input body size with headers
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Tue Nov 21 01:09:35 GMT 2023
    - 5.9K bytes
    - Viewed (0)
  7. cmd/background-heal-ops.go

    }
    
    func activeListeners() int {
    	// Bucket notification and http trace are not costly, it is okay to ignore them
    	// while counting the number of concurrent connections
    	return int(globalHTTPListen.Subscribers()) + int(globalTrace.Subscribers())
    }
    
    func waitForLowIO(maxIO int, maxWait time.Duration, currentIO func() int) {
    	// No need to wait run at full speed.
    	if maxIO <= 0 {
    		return
    	}
    
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Thu Apr 04 12:04:40 GMT 2024
    - 4.6K bytes
    - Viewed (0)
  8. cmd/admin-handlers.go

    	}, nil)
    	if err != nil {
    		writeErrorResponseJSON(ctx, w, toAdminAPIErr(ctx, err), r.URL)
    		return
    	}
    
    	// Publish bootstrap events that have already occurred before client could subscribe.
    	if traceOpts.TraceTypes().Contains(madmin.TraceBootstrap) {
    		go globalBootstrapTracer.Publish(ctx, globalTrace)
    	}
    
    	for _, peer := range peers {
    		if peer == nil {
    			continue
    		}
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Sun Apr 21 11:43:18 GMT 2024
    - 97.3K bytes
    - Viewed (2)
  9. internal/event/target/testdata/contrib/nats_tls_client_cert.conf

        key_file:   "./testdata/contrib/certs/nats_server_key.pem"
        ca_file:   "./testdata/contrib/certs/root_ca_cert.pem"
        verify_and_map: true
    }
    authorization {
        ADMIN = {
            publish = ">"
            subscribe = ">"
        }
        users = [
            {user: "CN=localhost,OU=Client,O=MinIO,C=CA", permissions: $ADMIN}
        ]
    Plain Text
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Tue Jun 01 21:59:40 GMT 2021
    - 426 bytes
    - Viewed (0)
  10. .github/ISSUE_TEMPLATE.md

    For urgent issues (e.g. production down, etc.), subscribe to [SUBNET](https://min.io/pricing?jmp=github) for direct to engineering support.
     
    <!--- Provide a general summary of the issue in the Title above -->
    
    ## Expected Behavior
    Plain Text
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Sat Jan 29 00:04:16 GMT 2022
    - 2K bytes
    - Viewed (0)
Back to top