diff --git a/package.json b/package.json index f473b7d..a7a670f 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@qlever-llc/target-helper", - "version": "1.6.6", + "version": "2.0.0", "description": "A Trellis microservice to fill in around Target integration", "author": "Andrew Balmos ", "license": "Apache-2.0", @@ -119,4 +119,4 @@ "volta": { "node": "20.13.1" } -} +} \ No newline at end of file diff --git a/src/index.ts b/src/index.ts index e479d8a..9668068 100644 --- a/src/index.ts +++ b/src/index.ts @@ -30,12 +30,16 @@ import { Service } from '@oada/jobs'; jobHandler as asnJobHandler, startJobCreator as asnStartJobCreator, } from './asnJob.js'; - */ +*/ import { jobHandler as pdfJobHandler, startJobCreator as pdfStartJobCreator, } from './pdfJob.js'; +import { + jobHandler as transcriptionOnlyJobHandler, +} from './transcriptionOnly.js'; + const error = debug('target-helper:error'); const info = debug('target-helper:info'); const trace = debug('target-helper:trace'); @@ -83,10 +87,11 @@ await Promise.all( config.get('timeouts.pdf')*jobsConcurrency, pdfJobHandler, ); + service.on( 'transcription-only', config.get('timeouts.pdf')*jobsConcurrency, - pdfJobHandler, + transcriptionOnlyJobHandler, ); // Service.on('asn', config.get('timeouts.asn'), asnJobHandler); diff --git a/src/pdfJob.ts b/src/pdfJob.ts index f324023..2e46a99 100644 --- a/src/pdfJob.ts +++ b/src/pdfJob.ts @@ -237,8 +237,6 @@ export async function composeResult( return job.result; } - - async function handleTargetTimeout({ jobId, oada,