Increase channel capacity
This commit is contained in:
		
							parent
							
								
									d06206bb24
								
							
						
					
					
						commit
						b6dcf61995
					
				
					 1 changed files with 1 additions and 1 deletions
				
			
		|  | @ -112,7 +112,7 @@ impl PubSub { | |||
|     } | ||||
| 
 | ||||
|     pub async fn subscribe(&self, topic: &str) -> broadcast::Receiver<Message> { | ||||
|         let (tx, _rx) = broadcast::channel(256); // 256 is the channel capacity
 | ||||
|         let (tx, _rx) = broadcast::channel(20_000); // 20000 is the channel capacity
 | ||||
|         let mut subscribers = self.subscribers.lock().await; | ||||
|         subscribers | ||||
|             .entry(topic.to_string()) | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue