modify metadata recording conditions

This commit is contained in:
leo
2026-03-25 11:46:15 +01:00
parent 1b02bfcc63
commit 7c1624cfaa
3 changed files with 3 additions and 11 deletions
+1 -4
View File
@@ -178,10 +178,7 @@ class MetadataCollector:
def save(self):
"""Serialize collected events and upload as JSON to S3."""
scheme = "https" if os.getenv("AWS_S3_SECURE_ACCESS", "False").lower() == "true" else "http"
endpoint = os.getenv("AWS_S3_ENDPOINT_URL", "")
url = f"{scheme}://{endpoint}/{self.bucket_name}/{self.output_filename}"
logger.info("Persisting metadata to %s", url)
logger.info("Persisting metadata...")
participants = []
for k, v in self.participants.items():
+1 -5
View File
@@ -340,11 +340,7 @@ class RoomViewSet(
status=drf_status.HTTP_500_INTERNAL_SERVER_ERROR,
)
if (
settings.METADATA_COLLECTOR_ENABLED
and recording.mode == models.RecordingModeChoices.TRANSCRIPT
):
if settings.METADATA_COLLECTOR_ENABLED and recording.options.transcribe:
try:
MetadataCollectorService().start(recording)
except MetadataCollectorException:
+1 -2
View File
@@ -178,10 +178,9 @@ class LiveKitEventsService:
except utils.MetadataUpdateException as e:
logger.exception("Failed to update room's metadata: %s", e)
if (
settings.METADATA_COLLECTOR_ENABLED
and recording.mode == models.RecordingModeChoices.TRANSCRIPT
and recording.options.get("metadata_collector_dispatch_id")
):
try:
MetadataCollectorService().stop(recording)