How to use the graphql-relational-schema-transformer.RelationalDBSchemaTransformer function in graphql-relational-schema-transformer

To help you get started, we’ve selected a few graphql-relational-schema-transformer examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github aws-amplify / amplify-cli / packages / amplify-category-api / commands / api / add-graphql-datasource.js View on Github external
* 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 => {

graphql-relational-schema-transformer

An AppSync model transform that takes a relational database and turns that into a GraphQL API.

Apache-2.0
Latest version published 6 months ago

Package Health Score

89 / 100
Full package analysis