Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
teamProviderInfo[currEnv][categories][category][resourceName][rdsDatabaseName] = answers.databaseName;
fs.writeFileSync(teamProviderInfoFilePath, JSON.stringify(teamProviderInfo, null, 4));
const backendConfigFilePath = amplify.pathManager.getBackendConfigFilePath();
const backendConfig = context.amplify.readJsonFile(backendConfigFilePath);
backendConfig[category][resourceName][rdsInit] = true;
fs.writeFileSync(backendConfigFilePath, JSON.stringify(backendConfig, null, 4));
/**
* Load the MySqlRelationalDBReader
*/
// eslint-disable-next-line max-len
const dbReader = new AuroraServerlessMySQLDatabaseReader(
answers.region,
answers.secretStoreArn,
answers.dbClusterArn,
answers.databaseName,
AWS
);
/**
* Instantiate a new Relational Schema Transformer and perform
* the db instrospection to get the GraphQL Schema and Template Context
*/
const relationalSchemaTransformer = new RelationalDBSchemaTransformer(dbReader, answers.databaseName);
return relationalSchemaTransformer.introspectDatabaseSchema();
})
.then(graphqlSchemaContext => {