UNPKG

@cumulus/ingest

Version:
101 lines 4.93 kB
export type CollectionRecord = import('@cumulus/types/api/collections').CollectionRecord; /** * @typedef { import('@cumulus/types/api/collections').CollectionRecord } CollectionRecord * @param {object | undefined} messageTemplate * @param {CollectionRecord} collection */ export function joinCollectionProviderToTemplateCmrMeta(messageTemplate: object | undefined, collection: CollectionRecord): any; /** * Enqueue a PDR to be parsed * * @param {object} params * @param {object} params.collection - the collection config to be attached to the message * @param {string} params.parentExecutionArn - parent workflow execution arn to add to the message * @param {string} params.parsePdrWorkflow - the S3 URI of template for a PDR parse message * @param {object} params.pdr - the PDR to be enqueued for parsing * @param {object} params.provider - the provider config to be attached to the message * @param {string} params.stack - stack name * @param {string} params.systemBucket - system bucket name * @param {string} params.queueUrl - the SQS queue to add the message to * @param {string} [params.executionNamePrefix] * - the prefix to apply to the name of the enqueued execution * @param {object} [params.additionalCustomMeta] * - additional object to merge into meta object * @returns {Promise<string>} * - resolves when the message has been enqueued */ export function enqueueParsePdrMessage({ collection, parentExecutionArn, parsePdrWorkflow, pdr, provider, stack, systemBucket, queueUrl, executionNamePrefix, additionalCustomMeta, }: { collection: object; parentExecutionArn: string; parsePdrWorkflow: string; pdr: object; provider: object; stack: string; systemBucket: string; queueUrl: string; executionNamePrefix?: string | undefined; additionalCustomMeta?: object | undefined; }): Promise<string>; /** * Enqueue a granule to be ingested * * @param {object} params * @param {object} params.collection - the collection config to be attached to the message * @param {object} params.granules - the granules to be enqueued for ingest * @param {string} params.parentExecutionArn * - parent workflow execution arn to add to the message * @param {object} params.provider - the provider config to be attached to the message * @param {object} params.messageTemplate - Message template for the workflow * @param {object} params.workflow - workflow name & arn object * @param {string} params.queueUrl - the SQS queue to add the message to * @param {object | undefined} [params.pdr] * - an optional PDR to be configured in the message payload * @param {string} [params.executionNamePrefix] * - the prefix to apply to the name of the enqueued execution * @param {object} [params.additionalCustomMeta] * - additional object to merge into meta object * @returns {Promise<string>} * - resolves when the message has been enqueued */ export function enqueueGranuleIngestMessage({ collection, granules, parentExecutionArn, pdr, provider, messageTemplate, workflow, queueUrl, executionNamePrefix, additionalCustomMeta, }: { collection: object; granules: object; parentExecutionArn: string; provider: object; messageTemplate: object; workflow: object; queueUrl: string; pdr?: object | undefined; executionNamePrefix?: string | undefined; additionalCustomMeta?: object | undefined; }): Promise<string>; /** * Enqueue a workflow * * @param {object} params * @param {string} params.parentExecutionArn * - parent workflow execution arn to add to the message * @param {string} params.stack - stack name * @param {string} params.systemBucket - system bucket name * @param {object} params.collection - the collection config to be attached to the message * @param {object} params.provider - the provider config to be attached to the message * @param {object} params.workflow - the workflow to be enqueued * @param {object} params.workflowInput - the input that should be passed to the queued workflow * @param {string} [params.queueUrl] - an optional SQS queue to add the message to * @param {string} [params.executionNamePrefix] * - the prefix to apply to the name of the enqueued execution * @returns {Promise<string>} * - resolves when the message has been enqueued */ export function enqueueWorkflowMessage({ parentExecutionArn, stack, systemBucket, collection, provider, queueUrl, workflow, workflowInput, executionNamePrefix, additionalCustomMeta, }: { parentExecutionArn: string; stack: string; systemBucket: string; collection: object; provider: object; workflow: object; workflowInput: object; queueUrl?: string | undefined; executionNamePrefix?: string | undefined; }): Promise<string>; //# sourceMappingURL=queue.d.ts.map