trying to use an SQL query API endpoint to query some data via SQL connection. The endpoint works fine in development mode, because the SQL connection imp is configured in Administration -> Settings -> API Designer & Deployer in section "Connection for bundled data"
But: I cant make it working on API node(s), the API node is complaining that it cant find this connection.
"in service:provide_data: in gen:v1: Connection 'imp' does not exist".
According to the documentation the API Deployer pools and handles the connection(s) and in this case my DSS design the the API Deployer where the connection exists.
Am I missing something from the API Deployer setup? Thanks
The API deployer does not automatically setup connections on static API nodes. It can help doing it for K8S API nodes only.
For static API nodes, you need to edit the config/server.json file to add the connection details, as per https://doc.dataiku.com/dss/latest/apinode/enrich-prediction-queries.html#api-node-configuration
For K8S-controlled API nodes, you need to fill the settings in Infrastructure > Settings > Connections
Great, problem sovled!
Just for others having this kind of issue:
If you are using SQL query endpoint, the connection must be inserted into a remapped connections, like this:
"imp": <- NAME OF THE CONNECTION coming from DSS Design
And also dont forget to put the correct JDBC drivers into API node's lib/jdbc path.