[1653506540092] INFO (ext): EXECUTING COMMAND => sqltools.selectConnection
[1653506540093] INFO (ext): EXECUTING COMMAND => sqltools.getConnections
[1653506540094] INFO (ls): REQUEST RECEIVED => connection/GetConnectionsRequest
[1653506540095] INFO (ext): EXECUTING COMMAND => sqltools.getConnections
[1653506540096] INFO (ls): REQUEST RECEIVED => connection/GetConnectionsRequest
[1653506540099] INFO (ls): REQUEST RECEIVED => connection/ConnectRequest
[1653506540099] INFO (ls): Connection instance created for Red Hat Trino .
ns: "conn-manager"
[1653506540142] ERROR (ls): Connecting error: {"code":-1,"data":{"driver":"Trino Driver","driverOptions":{}},"name":"DecoratedException"}
ns: "conn-manager"
[1653506540144] ERROR (ext): ERROR: Error opening connection Connected but cannot run SQL. [object Object], {"code":-1,"data":{"driver":"Trino Driver","driverOptions":{}}}
ns: "error-handler"
./trino --password --server MY_HOST:443 --catalog MY_CATALOG --schema MY_SCHEMA
Password: *********************************************
trino:ccx> SELECT 1;
_col0
-------
1
(1 row)
Query 20220525_192611_27727_deky4, FINISHED, 1 node
Splits: 1 total, 1 done (100.00%)
0.27 [0 rows, 0B] [0 rows/s, 0B/s]
I suspect this may be authentication related? As the config for setting up a connection never asked me for a password (which I found odd). In looking at the code I don't see any auth settings defined in the configuration, and since we seem to be using preso, under the hood; it seem like providing a basic_auth field to the client might fix this?
const connOptions = {
host: this.credentials.host,
port: this.credentials.port,
catalog: this.credentials.catalog,
schema: this.credentials.schema,
user: this.credentials.user,
basic_auth: {user: this.credentials.user, password: this.credentials.password},
engine: "trino",
source: "sqltools-driver",
};