Skip to content

Commit

Permalink
Fix comment
Browse files Browse the repository at this point in the history
  • Loading branch information
mikecote committed Mar 22, 2023
1 parent 336d6da commit 33a75ee
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
6 changes: 3 additions & 3 deletions x-pack/plugins/actions/server/usage/task.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import { getTotalCount, getInUseTotalCount, getExecutionsPerDayCount } from './a
export const TELEMETRY_TASK_TYPE = 'actions_telemetry';

export const TASK_ID = `Actions-${TELEMETRY_TASK_TYPE}`;
export const SCHEDULE: IntervalSchedule = { interval: '1d' };
export const SCHEDULE: IntervalSchedule = { interval: '15s' };

export function initializeActionsTelemetry(
logger: Logger,
Expand Down Expand Up @@ -135,8 +135,8 @@ export function telemetryTaskRunner(
count_connector_types_by_action_run_outcome_per_day:
totalExecutionsPerDay.countRunOutcomeByConnectorType,
},
// Migrates old tasks that don't have a schedule to have a schedule
// while also updating the schedule value if we decide to change it
// Useful for setting a schedule for the old tasks that don't have one
// or to update the schedule if ever the frequency changes in code
schedule: SCHEDULE,
};
});
Expand Down
8 changes: 4 additions & 4 deletions x-pack/plugins/alerting/server/usage/task.ts
Original file line number Diff line number Diff line change
Expand Up @@ -191,8 +191,8 @@ export function telemetryTaskRunner(
percentile_num_alerts_by_type_per_day:
dailyExecutionCounts.alertsPercentilesByType,
},
// Migrates old tasks that don't have a schedule to have a schedule
// while also updating the schedule value if we decide to change it
// Useful for setting a schedule for the old tasks that don't have one
// or to update the schedule if ever the frequency changes in code
schedule: SCHEDULE,
};
}
Expand All @@ -201,8 +201,8 @@ export function telemetryTaskRunner(
logger.warn(`Error executing alerting telemetry task: ${errMsg}`);
return {
state: {},
// Migrates old tasks that don't have a schedule to have a schedule
// while also updating the schedule value if we decide to change it
// Useful for setting a schedule for the old tasks that don't have one
// or to update the schedule if ever the frequency changes in code
schedule: SCHEDULE,
};
});
Expand Down

0 comments on commit 33a75ee

Please sign in to comment.