Skip to content

Commit cf3cabf

Browse files
authored
Merge pull request #65 from linuxfoundation/andrest50/remove-handlers
[LFXV2-1251][LFXV2-1252] chore: remove voting and survey handlers from lfx-v1-sync-helper
2 parents cee52ac + 19734f6 commit cf3cabf

5 files changed

Lines changed: 14 additions & 2374 deletions

File tree

cmd/lfx-v1-sync-helper/handlers.go

Lines changed: 14 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -103,16 +103,14 @@ func handleKVPut(ctx context.Context, entry jetstream.KeyValueEntry) bool {
103103
case "platform-community__c":
104104
handleCommitteeMemberUpdate(ctx, key, v1Data)
105105
return false
106-
case "itx-poll":
107-
handleVoteUpdate(ctx, key, v1Data)
106+
case "itx-poll", "itx-poll-vote":
107+
// Voting records are handled by lfx-v2-voting-service.
108+
logger.With("key", key).DebugContext(ctx, "voting record, handled by lfx-v2-voting-service")
108109
return false
109-
case "itx-poll-vote":
110-
return handleVoteResponseUpdate(ctx, key, v1Data)
111-
case "itx-surveys":
112-
handleSurveyUpdate(ctx, key, v1Data)
110+
case "itx-surveys", "itx-survey-responses":
111+
// Survey records are handled by lfx-v2-survey-service.
112+
logger.With("key", key).DebugContext(ctx, "survey record, handled by lfx-v2-survey-service")
113113
return false
114-
case "itx-survey-responses":
115-
return handleSurveyResponseUpdate(ctx, key, v1Data)
116114
case "itx-zoom-meetings-v2":
117115
handleZoomMeetingUpdate(ctx, key, v1Data)
118116
return false
@@ -252,6 +250,14 @@ func handleResourceDelete(ctx context.Context, key string, v1Principal string, v
252250
return handleMeetingAttachmentDelete(ctx, key, sfid)
253251
case "itx-zoom-past-meetings-attachments":
254252
return handlePastMeetingAttachmentDelete(ctx, key, sfid)
253+
case "itx-poll", "itx-poll-vote":
254+
// Voting records are handled by lfx-v2-voting-service.
255+
logger.With("key", key).DebugContext(ctx, "voting record deleted, handled by lfx-v2-voting-service")
256+
return false
257+
case "itx-surveys", "itx-survey-responses":
258+
// Survey records are handled by lfx-v2-survey-service.
259+
logger.With("key", key).DebugContext(ctx, "survey record deleted, handled by lfx-v2-survey-service")
260+
return false
255261
case "salesforce_b2b-Account",
256262
"salesforce_b2b-Asset",
257263
"salesforce_b2b-Product2",

0 commit comments

Comments
 (0)