@golemio/pid
Version:
Golemio PID Module
31 lines • 2.27 kB
JavaScript
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.TimetableWorker = void 0;
const Di_1 = require("../../ioc/Di");
const RopidGtfsContainerToken_1 = require("../../ioc/RopidGtfsContainerToken");
const workers_1 = require("@golemio/core/dist/integration-engine/workers");
const constants_1 = require("./constants");
class TimetableWorker extends workers_1.AbstractWorker {
constructor() {
super();
this.name = constants_1.TIMETABLE_WORKER_NAME;
this.registerTask = (task) => {
super.registerTask(task);
task.queuePrefix = this.getQueuePrefix();
};
// Register tasks
this.registerTask(Di_1.RopidGtfsContainer.resolve(RopidGtfsContainerToken_1.RopidGtfsContainerToken.RefreshGtfsStopsCacheTask));
this.registerTask(Di_1.RopidGtfsContainer.resolve(RopidGtfsContainerToken_1.RopidGtfsContainerToken.RefreshPublicGtfsDepartureCacheTask));
this.registerTask(Di_1.RopidGtfsContainer.resolve(RopidGtfsContainerToken_1.RopidGtfsContainerToken.RefreshGtfsTripStopsCacheTask));
this.registerTask(Di_1.RopidGtfsContainer.resolve(RopidGtfsContainerToken_1.RopidGtfsContainerToken.CheckForNewDataTask));
this.registerTask(Di_1.RopidGtfsContainer.resolve(RopidGtfsContainerToken_1.RopidGtfsContainerToken.CheckSavedRowsAndReplaceTablesTask));
this.registerTask(Di_1.RopidGtfsContainer.resolve(RopidGtfsContainerToken_1.RopidGtfsContainerToken.DownloadDatasetsTask));
this.registerTask(Di_1.RopidGtfsContainer.resolve(RopidGtfsContainerToken_1.RopidGtfsContainerToken.RefreshPrecomputedTablesTask));
this.registerTask(Di_1.RopidGtfsContainer.resolve(RopidGtfsContainerToken_1.RopidGtfsContainerToken.TransformAndSaveDataTask));
this.registerTask(Di_1.RopidGtfsContainer.resolve(RopidGtfsContainerToken_1.RopidGtfsContainerToken.SaveStaticDataTask));
this.registerTask(Di_1.RopidGtfsContainer.resolve(RopidGtfsContainerToken_1.RopidGtfsContainerToken.EnsureCacheTask));
this.registerTask(Di_1.RopidGtfsContainer.resolve(RopidGtfsContainerToken_1.RopidGtfsContainerToken.RemapPresetsToGtfsStopsTask));
}
}
exports.TimetableWorker = TimetableWorker;
//# sourceMappingURL=TimetableWorker.js.map