aws-如何通过配置文件将多个postgresql连接器添加到EMR

时间:2018-06-21 03:56:34

标签: postgresql amazon-web-services emr amazon-emr

要在AWS EMR中为Presto添加一个 postgresql连接器,可以使用下面的配置文件来实现。

public ActionResult SpotifyReturn()
{
    System.Diagnostics.Debug.WriteLine("code made it here!");

    return View();
}

但是,当我尝试将一个项目简单地添加到配置文件中时,就像这样:

[
    {
        "Classification": "presto-connector-postgresql",
        "Properties": {
            "connection-url": "jdbc:postgresql://<host>:<port>/<database>",
            "connection-user": "<user>",
            "connection-password": "<password>"
        },
        "Configurations": []
    }
]

Terraform抱怨:[ { "Classification": "presto-connector-postgresql", "Properties": { "connection-url": "jdbc:postgresql://<host>:<port>/<database>", "connection-user": "<user>", "connection-password": "<password>" }, "Configurations": [] }, { "Classification": "presto-connector-postgresql", "Properties": { "connection-url": "jdbc:postgresql://<host>:<port>/<another-database>", "connection-user": "<user>", "connection-password": "<password>" }, "Configurations": [] } ]

这可以通过在/ etc / presto / conf / catalog文件夹下的database.properties文件中手动添加每个数据库来实现。

database.properties

Classification 'presto-connector-postgresql' was specified multiple times.

另一个数据库.properties

connector.name=postgresql
connection-password = <password>
connection-url = jdbc:postgresql://<host>:<port>/<database>
connection-user = <user>

只是想知道是否有一种方法可以通过EMR配置实现相同的目标。

0 个答案:

没有答案