🔧 Bumped dep versions and cleaned up console logs
Signed-off-by: Rishi Ghan <rishi.ghan@gmail.com>
This commit is contained in:
@@ -67,7 +67,7 @@ export default class QueueService extends Service {
|
||||
hooks: {},
|
||||
queues: {
|
||||
"process.import": {
|
||||
concurrency: 20,
|
||||
concurrency: 10,
|
||||
async process(job: SandboxedJob) {
|
||||
console.info("New job received!", job.data);
|
||||
console.info(`Processing queue...`);
|
||||
@@ -98,7 +98,7 @@ export default class QueueService extends Service {
|
||||
if (!isNil(job.data.bundleId)) {
|
||||
bundleId = job.data.bundleId;
|
||||
}
|
||||
|
||||
|
||||
// Orchestrate the payload
|
||||
const payload = {
|
||||
importStatus: {
|
||||
|
||||
@@ -57,7 +57,7 @@ import klaw from "klaw";
|
||||
import path from "path";
|
||||
import { COMICS_DIRECTORY, USERDATA_DIRECTORY } from "../constants/directories";
|
||||
|
||||
console.log(process.env.MONGO_URI);
|
||||
console.log(`MONGO -> ${process.env.MONGO_URI}`);
|
||||
export default class ImportService extends Service {
|
||||
public constructor(public broker: ServiceBroker) {
|
||||
super(broker);
|
||||
@@ -233,7 +233,6 @@ export default class ImportService extends Service {
|
||||
try {
|
||||
let volumeDetails;
|
||||
const comicMetadata = ctx.params.payload;
|
||||
|
||||
// When an issue is added from the search CV feature
|
||||
// we solicit volume information and add that to mongo
|
||||
if (
|
||||
@@ -260,7 +259,6 @@ export default class ImportService extends Service {
|
||||
console.log(
|
||||
`Import type: [${ctx.params.importType}]`
|
||||
);
|
||||
console.log(JSON.stringify(comicMetadata, null, 4));
|
||||
switch (ctx.params.importType) {
|
||||
case "new":
|
||||
return await Comic.create(comicMetadata);
|
||||
@@ -280,6 +278,7 @@ export default class ImportService extends Service {
|
||||
return false;
|
||||
}
|
||||
} catch (error) {
|
||||
console.log(error);
|
||||
throw new Errors.MoleculerError(
|
||||
"Import failed.",
|
||||
500
|
||||
|
||||
Reference in New Issue
Block a user