

AWS Data Pipeline 不再向新客户提供。的现有客户 AWS Data Pipeline 可以继续照常使用该服务。[了解详情](https://aws.amazon.com/blogs/big-data/migrate-workloads-from-aws-data-pipeline/)

本文属于机器翻译版本。若本译文内容与英语原文存在差异，则一律以英文原文为准。

# RedshiftDatabase
<a name="dp-object-redshiftdatabase"></a>

定义 Amazon Redshift 数据库。`RedshiftDatabase` 表示由您的管道使用的数据库的属性。

## 示例
<a name="redshiftdatabase-example"></a>

以下是该对象类型的示例。

```
{
  "id" : "MyRedshiftDatabase",
  "type" : "RedshiftDatabase",
  "clusterId" : "myRedshiftClusterId",
  "username" : "user_name",
  "*password" : "my_password",
  "databaseName" : "database_name"
}
```

默认情况下，此对象将使用 Postgres 驱动程序，这将需要 `clusterId` 字段。要使用 Amazon Redshift 驱动程序，请改为在 `connectionString` 字段中指定来自 Amazon Redshift 控制台的 Amazon Redshift 数据库连接字符串（以“jdbc:redshift:”开头）。

## 语法
<a name="redshiftdatabase-syntax"></a>


****  

| 必填字段 | 说明 | 槽位类型 | 
| --- | --- | --- | 
| \$1password | 提供的密码。 | 字符串 | 
| username | 连接到数据库时提供的用户名。 | 字符串 | 

 


****  

| 所需的组 (下列选项之一是必需的) | 说明 | 槽位类型 | 
| --- | --- | --- | 
| clusterId | 创建 Amazon Redshift 集群时用户提供的标识符。例如，如果您的 Amazon Redshift 集群的端点是 mydb.example.us-east-1.redshift.amazonaws.com，正确的标识符是 mydb。在 Amazon Redshift 控制台中，您可以从“Cluster Identifier”或“Cluster Name”获取此值。 | 字符串 | 
| connectionString | 用于连接到由账户拥有的不同于管道的 Amazon Redshift 实例的 JDBC 端点。您不能同时指定 connectionString 和 clusterId。 | 字符串 | 

 


****  

| 可选字段 | 说明 | 槽位类型 | 
| --- | --- | --- | 
| databaseName | 要附加到的逻辑数据库的名称。 | 字符串 | 
| jdbcProperties | 格式为 A=B 的一对值，设置为该数据库的 JDBC 连接上的属性。 | 字符串 | 
| parent | 作为槽继承源的当前对象的父项。 | 参考对象，例如，“父对象”：\$1"ref”:” myBaseObject Id "\$1 | 
| region | 数据库所在区域的代码。例如，us-east-1。 | 枚举 | 

 


****  

| 运行时字段 | 说明 | 槽位类型 | 
| --- | --- | --- | 
| @version | 用于创建对象的管道版本。 | 字符串 | 

 


****  

| 系统字段 | 说明 | 槽位类型 | 
| --- | --- | --- | 
| @error | 用于描述格式不正确的对象的错误消息。 | 字符串 | 
| @pipelineId | 该对象所属的管道的 ID。 | 字符串 | 
| @sphere | 对象的范围指明对象在生命周期中的位置：组件对象产生实例对象，后者执行尝试对象。 | 字符串 | 