[messaging] remove v2 feature flag (#4845)
## Context We are now removing Messaging V2 feature flag to use it everywhere. ## Implementation - renaming FetchWorkspaceMessagesCommandsModule to MessagingCommandModule to make it more generic since it it hosts all commands related to the messaging module - creating a crons folder inside commands and jobs crons should be named with xxx.cron.command.ts instead of xxx.command.ts. Same for jobs, jobs should be named with xxx.cron.job.ts. In a future PR we should make sure those CronJobs implement a CronJob interface since it's a bit different (a CronJob does not contain a payload compared to a Job) - Cron commands have been renamed to "cron:$module:command" so `fetch-all-workspaces-messages-from-cache:cron:start` has been renamed to `cron:messaging:gmail-fetch-messages-from-cache`. Also having to create a command to stop the cron is a bit painful to maintain so I removed them for now, this can be easily done manually with pg-boss or bull-mq - Removing full-sync and partial-sync commands as they were there for testing only, we might put them back at some point but we will have to adapt the code anyway. - Feature flag has been removed from the MessageChannel standard object to make sure those new columns are created during the next sync-metadata
This commit is contained in:
@ -1,4 +1,3 @@
|
||||
import { FeatureFlagKeys } from 'src/engine/core-modules/feature-flag/feature-flag.entity';
|
||||
import { FieldMetadataType } from 'src/engine/metadata-modules/field-metadata/field-metadata.entity';
|
||||
import {
|
||||
RelationMetadataType,
|
||||
@ -7,7 +6,6 @@ import {
|
||||
import { messageChannelStandardFieldIds } from 'src/engine/workspace-manager/workspace-sync-metadata/constants/standard-field-ids';
|
||||
import { standardObjectIds } from 'src/engine/workspace-manager/workspace-sync-metadata/constants/standard-object-ids';
|
||||
import { FieldMetadata } from 'src/engine/workspace-manager/workspace-sync-metadata/decorators/field-metadata.decorator';
|
||||
import { Gate } from 'src/engine/workspace-manager/workspace-sync-metadata/decorators/gate.decorator';
|
||||
import { IsNullable } from 'src/engine/workspace-manager/workspace-sync-metadata/decorators/is-nullable.decorator';
|
||||
import { IsSystem } from 'src/engine/workspace-manager/workspace-sync-metadata/decorators/is-system.decorator';
|
||||
import { ObjectMetadata } from 'src/engine/workspace-manager/workspace-sync-metadata/decorators/object-metadata.decorator';
|
||||
@ -119,9 +117,6 @@ export class MessageChannelObjectMetadata extends BaseObjectMetadata {
|
||||
description: 'Last sync cursor',
|
||||
icon: 'IconHistory',
|
||||
})
|
||||
@Gate({
|
||||
featureFlag: FeatureFlagKeys.IsFullSyncV2Enabled,
|
||||
})
|
||||
syncCursor: string;
|
||||
|
||||
@FieldMetadata({
|
||||
@ -131,9 +126,6 @@ export class MessageChannelObjectMetadata extends BaseObjectMetadata {
|
||||
description: 'Last sync date',
|
||||
icon: 'IconHistory',
|
||||
})
|
||||
@Gate({
|
||||
featureFlag: FeatureFlagKeys.IsFullSyncV2Enabled,
|
||||
})
|
||||
@IsNullable()
|
||||
syncedAt: string;
|
||||
|
||||
@ -170,9 +162,6 @@ export class MessageChannelObjectMetadata extends BaseObjectMetadata {
|
||||
},
|
||||
],
|
||||
})
|
||||
@Gate({
|
||||
featureFlag: FeatureFlagKeys.IsFullSyncV2Enabled,
|
||||
})
|
||||
@IsNullable()
|
||||
syncStatus: MessageChannelSyncStatus;
|
||||
|
||||
@ -183,9 +172,6 @@ export class MessageChannelObjectMetadata extends BaseObjectMetadata {
|
||||
description: 'Ongoing sync started at',
|
||||
icon: 'IconHistory',
|
||||
})
|
||||
@Gate({
|
||||
featureFlag: FeatureFlagKeys.IsFullSyncV2Enabled,
|
||||
})
|
||||
@IsNullable()
|
||||
ongoingSyncStartedAt: string;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user