feat: fast live recording

Signed-off-by: Alexander Onnikov <Alexander.Onnikov@xored.com>
This commit is contained in:
Alexander Onnikov
2025-06-26 23:26:26 +07:00
parent 9b74c1bc15
commit 0cb756d440
18 changed files with 1169 additions and 272 deletions
+6
View File
@@ -17,6 +17,7 @@ package queue
import (
"context"
"encoding/json"
"fmt"
"time"
"github.com/hcengineering/stream/internal/pkg/log"
@@ -168,7 +169,12 @@ func NewProducer(ctx context.Context, options ProducerOptions) Producer {
// Send sends a message to the queue topic
func (p *TProducer) Send(ctx context.Context, workspaceID string, data any) error {
if data == nil {
return fmt.Errorf("event data is empty")
}
value, err := json.Marshal(data)
if err != nil {
return err
}