Skip to content

Commit

Permalink
get hierarchy worker
Browse files Browse the repository at this point in the history
  • Loading branch information
jgraff2 committed Jun 1, 2017
1 parent 93e0fe6 commit ad013f0
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 5 deletions.
2 changes: 1 addition & 1 deletion jobQueue/jobWrapper.js
Original file line number Diff line number Diff line change
Expand Up @@ -245,7 +245,7 @@ function createJob(jobName, data, req) {
`jobPriority=${jobPriority}`);
}

const job = jobQueue.create(jobName, data)
const job = jobQueue.create(jobName, data);
job.ttl(TIME_TO_LIVE)
.priority(jobPriority)
.save((err) => {
Expand Down
1 change: 1 addition & 0 deletions jobQueue/setup.js
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ if (featureToggles.isFeatureEnabled('instrumentKue')) {
module.exports = {
jobConcurrency: {
BULKUPSERTSAMPLES: conf.bulkUpsertSampleJobConcurrency,
GET_HIERARCHY: 1,
PERSIST_SAMPLE_STORE: 1,
SAMPLE_TIMEOUT: 1,
},
Expand Down
6 changes: 2 additions & 4 deletions worker/jobProcessor.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,13 +26,11 @@ const getHierarchyJob = require('./jobs/getHierarchyJob');
const workerStarted = 'Worker Process Started';
console.log(workerStarted); // eslint-disable-line no-console


jobQueue.process(jobType.BULKUPSERTSAMPLES, jobConcurrency.BULKUPSERTSAMPLES,
bulkUpsertSamplesJob);
jobQueue.process(jobType.GET_HIERARCHY, jobConcurrency.GET_HIERARCHY,
getHierarchyJob);
jobQueue.process(jobType.SAMPLE_TIMEOUT, jobConcurrency.SAMPLE_TIMEOUT,
sampleTimeoutJob);
jobQueue.process(jobType.PERSIST_SAMPLE_STORE,
jobConcurrency.PERSIST_SAMPLE_STORE, persistSampleStoreJob);
jobQueue.process(jobType.GET_HIERARCHY, jobConcurrency.GET_HIERARCHY,
getHierarchyJob);

0 comments on commit ad013f0

Please sign in to comment.