@@ -125,7 +125,7 @@ func sendIndexerMessage(ctx context.Context, subject string, action MessageActio
125125
126126// sendAccessMessage sends a pre-marshalled message to the NATS server.
127127// This is a generic function that can be used for access control updates, put operations, etc.
128- func sendAccessMessage (ctx context. Context , subject string , messageBytes []byte ) error {
128+ func sendAccessMessage (subject string , messageBytes []byte ) error {
129129 // Publish the message to NATS
130130 if err := natsConn .Publish (subject , messageBytes ); err != nil {
131131 return fmt .Errorf ("failed to publish message to subject %s: %w" , subject , err )
@@ -288,7 +288,7 @@ func handleZoomMeetingUpdate(ctx context.Context, key string, v1Data map[string]
288288 return
289289 }
290290
291- if err := sendAccessMessage (ctx , UpdateAccessV1MeetingSubject , accessMsgBytes ); err != nil {
291+ if err := sendAccessMessage (UpdateAccessV1MeetingSubject , accessMsgBytes ); err != nil {
292292 funcLogger .With (errKey , err ).ErrorContext (ctx , "failed to send meeting access message" )
293293 return
294294 }
@@ -303,7 +303,7 @@ func handleZoomMeetingUpdate(ctx context.Context, key string, v1Data map[string]
303303}
304304
305305// convertMapToInputMeeting converts a map[string]any to an InputMeeting struct.
306- func convertMapToInputMeetingMapping (ctx context. Context , v1Data map [string ]any ) (* ZoomMeetingMappingDB , error ) {
306+ func convertMapToInputMeetingMapping (v1Data map [string ]any ) (* ZoomMeetingMappingDB , error ) {
307307 // Convert map to JSON bytes
308308 jsonBytes , err := json .Marshal (v1Data )
309309 if err != nil {
@@ -338,7 +338,7 @@ func handleZoomMeetingMappingUpdate(ctx context.Context, key string, v1Data map[
338338 funcLogger .DebugContext (ctx , "processing zoom meeting mapping update" )
339339
340340 // Convert v1Data map to ZoomMeetingMappingDB struct
341- mapping , err := convertMapToInputMeetingMapping (ctx , v1Data )
341+ mapping , err := convertMapToInputMeetingMapping (v1Data )
342342 if err != nil {
343343 funcLogger .With (errKey , err ).ErrorContext (ctx , "failed to convert v1Data to ZoomMeetingMappingDB" )
344344 return
@@ -430,7 +430,7 @@ func handleZoomMeetingMappingUpdate(ctx context.Context, key string, v1Data map[
430430 return
431431 }
432432
433- if err := sendAccessMessage (ctx , UpdateAccessV1MeetingSubject , accessMsgBytes ); err != nil {
433+ if err := sendAccessMessage (UpdateAccessV1MeetingSubject , accessMsgBytes ); err != nil {
434434 funcLogger .With (errKey , err , "meeting_id" , meetingID ).ErrorContext (ctx , "failed to send meeting access message" )
435435 return
436436 }
@@ -465,7 +465,7 @@ func handleZoomMeetingMappingUpdate(ctx context.Context, key string, v1Data map[
465465}
466466
467467// convertMapToInputRegistrant converts a map[string]any to a RegistrantInput struct.
468- func convertMapToInputRegistrant (ctx context. Context , v1Data map [string ]any ) (* registrantInput , error ) {
468+ func convertMapToInputRegistrant (v1Data map [string ]any ) (* registrantInput , error ) {
469469 // Convert map to JSON bytes
470470 jsonBytes , err := json .Marshal (v1Data )
471471 if err != nil {
@@ -522,7 +522,7 @@ func handleZoomMeetingRegistrantUpdate(ctx context.Context, key string, v1Data m
522522 funcLogger .DebugContext (ctx , "processing zoom meeting registrant update" )
523523
524524 // Convert v1Data map to RegistrantInput struct
525- registrant , err := convertMapToInputRegistrant (ctx , v1Data )
525+ registrant , err := convertMapToInputRegistrant (v1Data )
526526 if err != nil {
527527 funcLogger .With (errKey , err ).ErrorContext (ctx , "failed to convert v1Data to registrantInput" )
528528 return
@@ -589,7 +589,7 @@ func handleZoomMeetingRegistrantUpdate(ctx context.Context, key string, v1Data m
589589 return
590590 }
591591
592- if err := sendAccessMessage (ctx , V1MeetingRegistrantPutSubject , accessMsgBytes ); err != nil {
592+ if err := sendAccessMessage (V1MeetingRegistrantPutSubject , accessMsgBytes ); err != nil {
593593 funcLogger .With (errKey , err ).ErrorContext (ctx , "failed to send registrant put message" )
594594 return
595595 }
@@ -604,7 +604,7 @@ func handleZoomMeetingRegistrantUpdate(ctx context.Context, key string, v1Data m
604604 funcLogger .InfoContext (ctx , "successfully sent registrant indexer and put messages" )
605605}
606606
607- func convertMapToInputInviteResponse (ctx context. Context , v1Data map [string ]any ) (* inviteResponseInput , error ) {
607+ func convertMapToInputInviteResponse (v1Data map [string ]any ) (* inviteResponseInput , error ) {
608608 // Convert map to JSON bytes
609609 jsonBytes , err := json .Marshal (v1Data )
610610 if err != nil {
@@ -670,7 +670,7 @@ func handleZoomMeetingInviteResponseUpdate(ctx context.Context, key string, v1Da
670670 funcLogger .DebugContext (ctx , "processing zoom meeting invite response update" )
671671
672672 // Convert v1Data map to InviteResponseInput struct
673- inviteResponse , err := convertMapToInputInviteResponse (ctx , v1Data )
673+ inviteResponse , err := convertMapToInputInviteResponse (v1Data )
674674 if err != nil {
675675 funcLogger .With (errKey , err ).ErrorContext (ctx , "failed to convert v1Data to inviteResponseInput" )
676676 return
@@ -886,7 +886,7 @@ func handleZoomPastMeetingUpdate(ctx context.Context, key string, v1Data map[str
886886 return
887887 }
888888
889- if err := sendAccessMessage (ctx , V1PastMeetingUpdateAccessSubject , accessMsgBytes ); err != nil {
889+ if err := sendAccessMessage (V1PastMeetingUpdateAccessSubject , accessMsgBytes ); err != nil {
890890 funcLogger .With (errKey , err ).ErrorContext (ctx , "failed to send past meeting access message" )
891891 return
892892 }
@@ -901,7 +901,7 @@ func handleZoomPastMeetingUpdate(ctx context.Context, key string, v1Data map[str
901901}
902902
903903// convertMapToInputPastMeetingMapping converts a map[string]any to a ZoomPastMeetingMappingDB struct.
904- func convertMapToInputPastMeetingMapping (ctx context. Context , v1Data map [string ]any ) (* ZoomPastMeetingMappingDB , error ) {
904+ func convertMapToInputPastMeetingMapping (v1Data map [string ]any ) (* ZoomPastMeetingMappingDB , error ) {
905905 // Convert map to JSON bytes
906906 jsonBytes , err := json .Marshal (v1Data )
907907 if err != nil {
@@ -930,7 +930,7 @@ func handleZoomPastMeetingMappingUpdate(ctx context.Context, key string, v1Data
930930 funcLogger .DebugContext (ctx , "processing zoom past meeting mapping update" )
931931
932932 // Convert v1Data map to ZoomPastMeetingMappingDB struct
933- mapping , err := convertMapToInputPastMeetingMapping (ctx , v1Data )
933+ mapping , err := convertMapToInputPastMeetingMapping (v1Data )
934934 if err != nil {
935935 funcLogger .With (errKey , err ).ErrorContext (ctx , "failed to convert v1Data to ZoomPastMeetingMappingDB" )
936936 return
@@ -1018,7 +1018,7 @@ func handleZoomPastMeetingMappingUpdate(ctx context.Context, key string, v1Data
10181018 return
10191019 }
10201020
1021- if err := sendAccessMessage (ctx , V1PastMeetingUpdateAccessSubject , accessMsgBytes ); err != nil {
1021+ if err := sendAccessMessage (V1PastMeetingUpdateAccessSubject , accessMsgBytes ); err != nil {
10221022 funcLogger .With (errKey , err ).ErrorContext (ctx , "failed to send past meeting access message" )
10231023 return
10241024 }
@@ -1063,7 +1063,7 @@ type PastMeetingParticipantAccessMessage struct {
10631063}
10641064
10651065// convertMapToInputPastMeetingInvitee converts a map[string]any to a ZoomPastMeetingInviteeDatabase struct.
1066- func convertMapToInputPastMeetingInvitee (ctx context. Context , v1Data map [string ]any ) (* ZoomPastMeetingInviteeDatabase , error ) {
1066+ func convertMapToInputPastMeetingInvitee (v1Data map [string ]any ) (* ZoomPastMeetingInviteeDatabase , error ) {
10671067 // Convert map to JSON bytes
10681068 jsonBytes , err := json .Marshal (v1Data )
10691069 if err != nil {
@@ -1111,7 +1111,7 @@ func handleZoomPastMeetingInviteeUpdate(ctx context.Context, key string, v1Data
11111111 funcLogger .DebugContext (ctx , "processing zoom past meeting invitee update" )
11121112
11131113 // Convert v1Data map to PastMeetingInviteeInput struct
1114- invitee , err := convertMapToInputPastMeetingInvitee (ctx , v1Data )
1114+ invitee , err := convertMapToInputPastMeetingInvitee (v1Data )
11151115 if err != nil {
11161116 funcLogger .With (errKey , err ).ErrorContext (ctx , "failed to convert v1Data to PastMeetingInviteeInput" )
11171117 return
@@ -1160,7 +1160,7 @@ func handleZoomPastMeetingInviteeUpdate(ctx context.Context, key string, v1Data
11601160 }
11611161 }
11621162
1163- v2Participant , err := convertInviteeToV2Participant (ctx , invitee , isHost )
1163+ v2Participant , err := convertInviteeToV2Participant (invitee , isHost )
11641164 if err != nil {
11651165 funcLogger .With (errKey , err ).ErrorContext (ctx , "failed to convert invitee to V2 participant" )
11661166 return
@@ -1209,7 +1209,7 @@ func handleZoomPastMeetingInviteeUpdate(ctx context.Context, key string, v1Data
12091209 return
12101210 }
12111211
1212- if err := sendAccessMessage (ctx , V1PastMeetingParticipantPutSubject , accessMsgBytes ); err != nil {
1212+ if err := sendAccessMessage (V1PastMeetingParticipantPutSubject , accessMsgBytes ); err != nil {
12131213 funcLogger .With (errKey , err ).ErrorContext (ctx , "failed to send invitee access message" )
12141214 return
12151215 }
@@ -1224,7 +1224,7 @@ func handleZoomPastMeetingInviteeUpdate(ctx context.Context, key string, v1Data
12241224 funcLogger .InfoContext (ctx , "successfully sent invitee indexer and access messages" )
12251225}
12261226
1227- func convertInviteeToV2Participant (ctx context. Context , invitee * ZoomPastMeetingInviteeDatabase , isHost bool ) (* V2PastMeetingParticipant , error ) {
1227+ func convertInviteeToV2Participant (invitee * ZoomPastMeetingInviteeDatabase , isHost bool ) (* V2PastMeetingParticipant , error ) {
12281228 pastMeetingParticipant := V2PastMeetingParticipant {
12291229 UID : invitee .ID ,
12301230 PastMeetingUID : invitee .MeetingAndOccurrenceID ,
@@ -1249,7 +1249,7 @@ func convertInviteeToV2Participant(ctx context.Context, invitee *ZoomPastMeeting
12491249 "created_at" , invitee .CreatedAt ,
12501250 "invitee_id" , invitee .ID ,
12511251 "meeting_and_occurrence_id" , invitee .MeetingAndOccurrenceID ,
1252- ).WarnContext ( ctx , "failed to parse created_at for invitee %s" , invitee . ID )
1252+ ).Warn ( "failed to parse created_at for invitee" )
12531253 } else {
12541254 pastMeetingParticipant .CreatedAt = & createdAt
12551255 }
@@ -1262,7 +1262,7 @@ func convertInviteeToV2Participant(ctx context.Context, invitee *ZoomPastMeeting
12621262 "modified_at" , invitee .ModifiedAt ,
12631263 "invitee_id" , invitee .ID ,
12641264 "meeting_and_occurrence_id" , invitee .MeetingAndOccurrenceID ,
1265- ).WarnContext ( ctx , "failed to parse modified_at for invitee %s" , invitee . ID )
1265+ ).Warn ( "failed to parse modified_at for invitee" )
12661266 } else {
12671267 pastMeetingParticipant .UpdatedAt = & modifiedAt
12681268 }
@@ -1279,7 +1279,7 @@ func convertInviteeToV2Participant(ctx context.Context, invitee *ZoomPastMeeting
12791279}
12801280
12811281// convertMapToInputPastMeetingAttendee converts a map[string]any to a PastMeetingAttendeeInput struct.
1282- func convertMapToInputPastMeetingAttendee (ctx context. Context , v1Data map [string ]any ) (* PastMeetingAttendeeInput , error ) {
1282+ func convertMapToInputPastMeetingAttendee (v1Data map [string ]any ) (* PastMeetingAttendeeInput , error ) {
12831283 // Convert map to JSON bytes
12841284 jsonBytes , err := json .Marshal (v1Data )
12851285 if err != nil {
@@ -1307,7 +1307,7 @@ func handleZoomPastMeetingAttendeeUpdate(ctx context.Context, key string, v1Data
13071307 funcLogger .DebugContext (ctx , "processing zoom past meeting attendee update" )
13081308
13091309 // Convert v1Data map to PastMeetingAttendeeInput struct
1310- attendee , err := convertMapToInputPastMeetingAttendee (ctx , v1Data )
1310+ attendee , err := convertMapToInputPastMeetingAttendee (v1Data )
13111311 if err != nil {
13121312 funcLogger .With (errKey , err ).ErrorContext (ctx , "failed to convert v1Data to PastMeetingAttendeeInput" )
13131313 return
@@ -1364,7 +1364,7 @@ func handleZoomPastMeetingAttendeeUpdate(ctx context.Context, key string, v1Data
13641364 indexerAction = MessageActionUpdated
13651365 }
13661366
1367- v2Participant , err := convertAttendeeToV2Participant (ctx , attendee , isHost , isRegistrant )
1367+ v2Participant , err := convertAttendeeToV2Participant (attendee , isHost , isRegistrant )
13681368 if err != nil {
13691369 funcLogger .With (errKey , err ).ErrorContext (ctx , "failed to convert attendee to V2 participant" )
13701370 return
@@ -1407,7 +1407,7 @@ func handleZoomPastMeetingAttendeeUpdate(ctx context.Context, key string, v1Data
14071407 return
14081408 }
14091409
1410- if err := sendAccessMessage (ctx , V1PastMeetingParticipantPutSubject , accessMsgBytes ); err != nil {
1410+ if err := sendAccessMessage (V1PastMeetingParticipantPutSubject , accessMsgBytes ); err != nil {
14111411 funcLogger .With (errKey , err ).ErrorContext (ctx , "failed to send attendee access message" )
14121412 return
14131413 }
@@ -1422,7 +1422,7 @@ func handleZoomPastMeetingAttendeeUpdate(ctx context.Context, key string, v1Data
14221422 funcLogger .InfoContext (ctx , "successfully sent attendee indexer and access messages" )
14231423}
14241424
1425- func convertAttendeeToV2Participant (ctx context. Context , attendee * PastMeetingAttendeeInput , isHost bool , isRegistrant bool ) (* V2PastMeetingParticipant , error ) {
1425+ func convertAttendeeToV2Participant (attendee * PastMeetingAttendeeInput , isHost bool , isRegistrant bool ) (* V2PastMeetingParticipant , error ) {
14261426 var firstName , lastName string
14271427 namesSplit := strings .Split (attendee .Name , " " )
14281428 if len (namesSplit ) >= 2 {
@@ -1457,7 +1457,7 @@ func convertAttendeeToV2Participant(ctx context.Context, attendee *PastMeetingAt
14571457 "created_at" , attendee .CreatedAt ,
14581458 "attendee_id" , attendee .ID ,
14591459 "meeting_and_occurrence_id" , attendee .MeetingAndOccurrenceID ,
1460- ).WarnContext ( ctx , "failed to parse created_at for attendee %s" , attendee . ID )
1460+ ).Warn ( "failed to parse created_at for attendee" )
14611461 } else {
14621462 pastMeetingParticipant .CreatedAt = & createdAt
14631463 }
@@ -1470,7 +1470,7 @@ func convertAttendeeToV2Participant(ctx context.Context, attendee *PastMeetingAt
14701470 "modified_at" , attendee .ModifiedAt ,
14711471 "attendee_id" , attendee .ID ,
14721472 "meeting_and_occurrence_id" , attendee .MeetingAndOccurrenceID ,
1473- ).WarnContext ( ctx , "failed to parse modified_at for attendee %s" , attendee . ID )
1473+ ).Warn ( "failed to parse modified_at for attendee" )
14741474 } else {
14751475 pastMeetingParticipant .UpdatedAt = & modifiedAt
14761476 }
@@ -1498,7 +1498,7 @@ func convertAttendeeToV2Participant(ctx context.Context, attendee *PastMeetingAt
14981498 "session_id" , session .ParticipantUUID ,
14991499 "attendee_id" , attendee .ID ,
15001500 "meeting_and_occurrence_id" , attendee .MeetingAndOccurrenceID ,
1501- ).WarnContext ( ctx , "failed to parse join_time for attendee %s" , attendee . ID )
1501+ ).Warn ( "failed to parse join_time for attendee" )
15021502 } else {
15031503 participantSession .JoinTime = & joinTime
15041504 }
@@ -1512,7 +1512,7 @@ func convertAttendeeToV2Participant(ctx context.Context, attendee *PastMeetingAt
15121512 "session_id" , session .ParticipantUUID ,
15131513 "attendee_id" , attendee .ID ,
15141514 "meeting_and_occurrence_id" , attendee .MeetingAndOccurrenceID ,
1515- ).WarnContext ( ctx , "failed to parse leave_time for attendee %s" , attendee . ID )
1515+ ).Warn ( "failed to parse leave_time for attendee" )
15161516 } else {
15171517 participantSession .LeaveTime = & leaveTime
15181518 }
@@ -1541,7 +1541,7 @@ type PastMeetingTranscriptAccessMessage struct {
15411541}
15421542
15431543// convertMapToInputPastMeetingRecording converts a map[string]any to a PastMeetingRecordingInput struct.
1544- func convertMapToInputPastMeetingRecording (ctx context. Context , v1Data map [string ]any ) (* PastMeetingRecordingInput , error ) {
1544+ func convertMapToInputPastMeetingRecording (v1Data map [string ]any ) (* PastMeetingRecordingInput , error ) {
15451545 // Convert map to JSON bytes
15461546 jsonBytes , err := json .Marshal (v1Data )
15471547 if err != nil {
@@ -1630,7 +1630,7 @@ func handleZoomPastMeetingRecordingUpdate(ctx context.Context, key string, v1Dat
16301630 funcLogger .DebugContext (ctx , "processing zoom past meeting recording update" )
16311631
16321632 // Convert the v1Data map to PastMeetingRecordingInput struct
1633- recordingInput , err := convertMapToInputPastMeetingRecording (ctx , v1Data )
1633+ recordingInput , err := convertMapToInputPastMeetingRecording (v1Data )
16341634 if err != nil {
16351635 funcLogger .With (errKey , err ).ErrorContext (ctx , "failed to convert v1Data to PastMeetingRecordingInput" )
16361636 return
@@ -1680,7 +1680,7 @@ func handleZoomPastMeetingRecordingUpdate(ctx context.Context, key string, v1Dat
16801680 }
16811681
16821682 // Send recording access message
1683- if err := sendAccessMessage (ctx , V1PastMeetingRecordingUpdateAccessSubject , recordingAccessMsgBytes ); err != nil {
1683+ if err := sendAccessMessage (V1PastMeetingRecordingUpdateAccessSubject , recordingAccessMsgBytes ); err != nil {
16841684 funcLogger .With (errKey , err ).ErrorContext (ctx , "failed to send recording access message" )
16851685 return
16861686 }
@@ -1707,7 +1707,7 @@ func handleZoomPastMeetingRecordingUpdate(ctx context.Context, key string, v1Dat
17071707 }
17081708
17091709 // Send transcript access message
1710- if err := sendAccessMessage (ctx , V1PastMeetingTranscriptUpdateAccessSubject , transcriptAccessMsgBytes ); err != nil {
1710+ if err := sendAccessMessage (V1PastMeetingTranscriptUpdateAccessSubject , transcriptAccessMsgBytes ); err != nil {
17111711 funcLogger .With (errKey , err ).ErrorContext (ctx , "failed to send transcript access message" )
17121712 return
17131713 }
@@ -1730,7 +1730,7 @@ type PastMeetingSummaryAccessMessage struct {
17301730}
17311731
17321732// convertMapToInputPastMeetingSummary converts a map[string]any to a PastMeetingSummaryInput struct.
1733- func convertMapToInputPastMeetingSummary (ctx context. Context , v1Data map [string ]any ) (* PastMeetingSummaryInput , error ) {
1733+ func convertMapToInputPastMeetingSummary (v1Data map [string ]any ) (* PastMeetingSummaryInput , error ) {
17341734 // Convert map to JSON bytes
17351735 jsonBytes , err := json .Marshal (v1Data )
17361736 if err != nil {
@@ -1771,7 +1771,7 @@ func handleZoomPastMeetingSummaryUpdate(ctx context.Context, key string, v1Data
17711771 funcLogger .DebugContext (ctx , "processing zoom past meeting summary update" )
17721772
17731773 // Convert the v1Data map to PastMeetingSummaryInput struct
1774- summaryInput , err := convertMapToInputPastMeetingSummary (ctx , v1Data )
1774+ summaryInput , err := convertMapToInputPastMeetingSummary (v1Data )
17751775 if err != nil {
17761776 funcLogger .With (errKey , err ).ErrorContext (ctx , "failed to convert v1Data to PastMeetingSummaryInput" )
17771777 return
@@ -1843,7 +1843,7 @@ func handleZoomPastMeetingSummaryUpdate(ctx context.Context, key string, v1Data
18431843 }
18441844
18451845 // Send summary access message
1846- if err := sendAccessMessage (ctx , V1PastMeetingSummaryUpdateAccessSubject , summaryAccessMsgBytes ); err != nil {
1846+ if err := sendAccessMessage (V1PastMeetingSummaryUpdateAccessSubject , summaryAccessMsgBytes ); err != nil {
18471847 funcLogger .With (errKey , err ).ErrorContext (ctx , "failed to send summary access message" )
18481848 return
18491849 }
0 commit comments