cube-js / cube

📊 Cube — The Semantic Layer for Building Data Applications
https://cube.dev
Other
17.85k stars 1.77k forks source link

Error while loading DB schema Error: Cannot find module '@cubejs-backend/jdbc/lib/drivermanager' #8790

Open felipemm opened 6 days ago

felipemm commented 6 days ago

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:

  1. create Dockerfile, .env and docker-compose.yml into same dir
  2. run docker-compose build --no-cache
  3. run docker-compose up
  4. 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

image image

Version: 0.36

Additional context Running docker version 27.2.0, build 3ab4256 on macOS Sonoma (x86)

shan63 commented 4 days ago

I am facing the same issue.

tdarnett commented 4 days ago

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.