Deep Dive into Google Cloud SQL Connector for Node.js

This page summarizes the projects mentioned and recommended in the original post on dev.to

Our great sponsors
  • SurveyJS - Open-Source JSON Form Builder to Create Dynamic Forms Right in Your App
  • InfluxDB - Power Real-Time Data Analytics at Scale
  • WorkOS - The modern identity platform for B2B SaaS
  • cloud-sql-nodejs-connector

    A JavaScript library for connecting securely to your Cloud SQL instances

  • Source: https://github.com/GoogleCloudPlatform/cloud-sql-nodejs-connector

  • tedious

    Node TDS module for connecting to SQL Server databases.

  • SQL Server does not support IAM database authentication, so we can only use built-in password authentication. Notice that we also have to pass a dummy server property when creating a connection pool. This is due to a bug in the tedious driver, which always requires the server property, even though it is not used when a custom connection builder is provided.

  • SurveyJS

    Open-Source JSON Form Builder to Create Dynamic Forms Right in Your App. With SurveyJS form UI libraries, you can build and style forms in a fully-integrated drag & drop form builder, render them in your JS app, and store form submission data in any backend, inc. PHP, ASP.NET Core, and Node.js.

    SurveyJS logo
  • google-cloud-sql-nodejs-connector-example

    Example of using Google Cloud SQL connector for Node.js.

  • I also investigated the support for the connector in the most popular high-level database libraries. The connector is mostly supported in the latest versions of these libraries, with some caveats. You can find examples of using the connector with all these libraries in my GitHub repository.

  • TypeORM

    ORM for TypeScript and JavaScript. Supports MySQL, PostgreSQL, MariaDB, SQLite, MS SQL Server, Oracle, SAP Hana, WebSQL databases. Works in NodeJS, Browser, Ionic, Cordova and Electron platforms.

  • typeorm officially supports mssql@v9, but the support for the custom stream builder was added in mssql@v10. Since mssql is a peer dependency of typeorm, you can force override it and use the Cloud SQL Connector with typeorm. There is an open PR to add support for mssql@v10 in typeorm.

NOTE: The number of mentions on this list indicates mentions on common posts plus user suggested alternatives. Hence, a higher number means a more popular project.

Suggest a related project

Related posts