Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
];
});
} catch (error) {
if (error.message.includes("/upgrade")) {
this.exit(1);
return;
}
throw error;
}
this.log(
formatHumanReadable({
implementingServices: taskOutput.implementingServices,
graphName: taskOutput.config.name,
frontendUrl:
taskOutput.config.engine.frontend || DefaultEngineConfig.frontend
})
);
}
}
})`;
if (
currentGraphInfo.implementingServices &&
"services" in currentGraphInfo.implementingServices
) {
consoleResult += ` is federated with ${chalk.cyan(
`${currentGraphInfo.implementingServices.services.length} implementing services`
)}.\n`;
if (flags.verbose) {
consoleResult += "\nSERVICE LIST\n";
consoleResult += formatServiceListHumanReadable({
implementingServices: currentGraphInfo.implementingServices as any,
graphName: config.name,
frontendUrl:
config.engine.frontend || DefaultEngineConfig.frontend
});
consoleResult += "\n";
}
if (!currentGraphInfo.mostRecentCompositionPublish) {
consoleResult += ` • No managed configuration has been pushed to the graph.\n`;
} else {
const compResult =
currentGraphInfo.mostRecentCompositionPublish;
if (compResult.errors && compResult.errors.length) {
consoleResult +=
" • Current services fail to compose. Composition errors" +
" must be resolved before the gateway can be updated.\n";
const messages = [
...compResult.errors.map(({ message }) => ({
type: chalk.red("Error"),
description: message