Get most of the task worker code into place

Signed-off-by: Fredrik Adelöw <freben@gmail.com>
This commit is contained in:
Fredrik Adelöw
2021-09-30 09:35:49 +02:00
parent d088c7f0a3
commit d4f412fcd3
15 changed files with 996 additions and 179 deletions
+2 -2
View File
@@ -57,7 +57,7 @@ import techInsights from './plugins/techInsights';
import todo from './plugins/todo';
import { PluginEnvironment } from './types';
async function makeCreateEnv(config: Config) {
function makeCreateEnv(config: Config) {
const root = getRootLogger();
const reader = UrlReaders.default({ logger: root, config });
const discovery = SingleHostDiscovery.fromConfig(config);
@@ -90,7 +90,7 @@ async function main() {
argv: process.argv,
logger,
});
const createEnv = await makeCreateEnv(config);
const createEnv = makeCreateEnv(config);
const healthcheckEnv = useHotMemoize(module, () => createEnv('healthcheck'));
const catalogEnv = useHotMemoize(module, () => createEnv('catalog'));