Error while loading DB schema Error: Cannot find module '@cubejs-backend/jdbc/lib/drivermanager'
Describe the bug Trying to create a new cube container and connect to a databricks warehouse. After following documentation and creating the docker-composer and dockerfile accordingly, it gives this error when accessing data model tab. PS: Using dev mode, because I do not have a model yet (just started using cube for testing purposes).
docker-compose.yml
services:
cube:
build: .
ports:
- 4000:4000
- 15432:15432
environment:
- CUBEJS_DEV_MODE=${CUBEJS_DEV_MODE}
- CUBEJS_DB_TYPE=${CUBEJS_DB_TYPE}
- CUBEJS_DB_NAME=${CUBEJS_DB_NAME}
- CUBEJS_DB_DATABRICKS_URL=${CUBEJS_DB_DATABRICKS_URL}
- CUBEJS_DB_DATABRICKS_TOKEN=${CUBEJS_DB_DATABRICKS_TOKEN}
- CUBEJS_DB_DATABRICKS_ACCEPT_POLICY=${CUBEJS_DB_DATABRICKS_ACCEPT_POLICY}
- CUBEJS_DB_DATABRICKS_CATALOG=${CUBEJS_DB_DATABRICKS_CATALOG}
volumes:
- .conf:/cube/conf
Dockerfile
FROM cubejs/cube:jdk
COPY . .
RUN npm install
.env
CUBEJS_DEV_MODE=true
CUBEJS_DB_TYPE=databricks-jdbc
CUBEJS_DB_DATABRICKS_CATALOG=main
CUBEJS_DB_NAME=thoughtspot_server
CUBEJS_DB_DATABRICKS_URL="jdbc:databricks://*******.cloud.databricks.com:443/default;transportMode=http;ssl=1;AuthMech=3;httpPath=/sql/1.0/warehouses/***************;UID=token;"
CUBEJS_DB_DATABRICKS_TOKEN="**********************************"
CUBEJS_DB_DATABRICKS_ACCEPT_POLICY=true
To Reproduce Steps to reproduce the behavior:
- create Dockerfile, .env and docker-compose.yml into same dir
- run
docker-compose build --no-cache - run
docker-compose up - No errors in log, access http://localhost:4000, error is shown in data model page
Expected behavior A clear and concise description of what you expected to happen.
Screenshots
Version: 0.36
Additional context Running docker version 27.2.0, build 3ab4256 on macOS Sonoma (x86)
I am facing the same issue.
I'm facing this same issue. I managed to workaround this by targeting version 0.35.81. Something in the 0.36 release introduced this, and I can't documentation about how to resolve.
Same issue, anyone managed to fix?
Thanks for reporting, everyone. I was able to reproduce this on v1.0.5 as well.
same issue - is there a workaround?
As a temporary workaround we have it working with this Dockerfile. Not a long term solution but solves the issue for the time being.
FROM cubejs/cube:v1.0-jdk
USER root
RUN apt-get update && apt-get upgrade -y \
gcc \
make \
build-essential \
python3-pip \
openjdk-17-jdk \
&& apt-get -qq clean \
&& rm -rf /var/lib/apt/lists/*
COPY . .
WORKDIR /cube/conf
RUN npm install java
USER cube
I feel like this commit might have fixed the issue above. When v1.1.16 is released, it would be great if anyone can check it out.
Hey everyone! v1.1.16 was released. Could you please test it? Looks like the workaround should not be needed anymore.
It is working for me. thanks for this. much appreciated.
Tested and also working for me. Thanks for the fix!