This commit is contained in:
@@ -81,8 +81,8 @@ func (c *Collector) Stream(stream proto.Collector_StreamServer) error {
|
||||
log.Printf("Agent %s connected, streaming logs for service: %s", agentName, service)
|
||||
|
||||
// If no ClickHouse, just consume the stream without storing
|
||||
if c.logRepo == nil {
|
||||
log.Printf("Warning: logRepo is nil, consuming logs without storing for agent %s", agentName)
|
||||
if !c.logRepo.IsConnected() {
|
||||
log.Printf("Warning: ClickHouse not connected yet, consuming logs without storing for agent %s", agentName)
|
||||
for {
|
||||
_, err := stream.Recv()
|
||||
if err == io.EOF {
|
||||
|
||||
Reference in New Issue
Block a user