[{
"type": "thumb-down",
"id": "hardToUnderstand",
"label":"Hard to understand"
},{
"type": "thumb-down",
"id": "incorrectInformationOrSampleCode",
"label":"Incorrect information or sample code"
},{
"type": "thumb-down",
"id": "missingTheInformationSamplesINeed",
"label":"Missing the information/samples I need"
},{
"type": "thumb-down",
"id": "translationIssue",
"label":"Translation issue"
},{
"type": "thumb-down",
"id": "otherDown",
"label":"Other"
}]
[{
"type": "thumb-up",
"id": "easyToUnderstand",
"label":"Easy to understand"
},{
"type": "thumb-up",
"id": "solvedMyProblem",
"label":"Solved my problem"
},{
"type": "thumb-up",
"id": "otherUp",
"label":"Other"
}]
外部应用连接方案
本页面介绍了从在 Google Cloud 外部运行的应用(包括 mysql 客户端)连接到 Cloud SQL 实例的各种方案。
下表对各外部应用连接方案进行了比较:
连接方案 |
是否有安全加密? |
了解详情 |
备注 |
使用 SSL 的公共 IP 地址 |
是 |
|
需要 SSL 证书管理服务。 |
不使用 SSL 的公共 IP 地址 |
否 |
|
不适用于生产实例。 |
Cloud SQL 代理 |
是 |
|
|
Cloud SQL 代理 Docker 映像 |
是 |
|
|
JDBC 套接字库 |
是 |
|
仅限 Java 编程语言。
|
Go 代理库 |
是 |
|
仅限 Go 编程语言。
|
Cloud Shell |
否 |
|
使用 Cloud SQL 代理从 Google Cloud Console 建立连接。最适合用于需要 mysql 命令行工具的管理任务。 |
Apps 脚本 |
是 |
|
Apps 脚本可以通过 JDBC 服务(标准 Java 数据库连接技术的一种封装容器)连接到外部数据库。
|
[{
"type": "thumb-down",
"id": "hardToUnderstand",
"label":"Hard to understand"
},{
"type": "thumb-down",
"id": "incorrectInformationOrSampleCode",
"label":"Incorrect information or sample code"
},{
"type": "thumb-down",
"id": "missingTheInformationSamplesINeed",
"label":"Missing the information/samples I need"
},{
"type": "thumb-down",
"id": "translationIssue",
"label":"Translation issue"
},{
"type": "thumb-down",
"id": "otherDown",
"label":"Other"
}]
[{
"type": "thumb-up",
"id": "easyToUnderstand",
"label":"Easy to understand"
},{
"type": "thumb-up",
"id": "solvedMyProblem",
"label":"Solved my problem"
},{
"type": "thumb-up",
"id": "otherUp",
"label":"Other"
}]
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2020-07-31 UTC.