Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

tools: support the Vendure framework #74796

Closed
vaibhavsanap opened this issue Jan 13, 2022 · 6 comments
Closed

tools: support the Vendure framework #74796

vaibhavsanap opened this issue Jan 13, 2022 · 6 comments
Labels
O-community Originated from the community T-sql-foundations SQL Foundations Team (formerly SQL Schema + SQL Sessions)

Comments

@vaibhavsanap
Copy link

Describe the bug
Unable to connect to cockroachDB from vendure worker

To Reproduce

  1. Deploy cockroachDB using operator(cockroachdb/cockroach:v21.1.11)
  2. Deploy vendure with cockroachDB as database for it

Expected behaviour
Vendure worker and server should run as expected

Environment

  1. cockroachdb/cockroach:v21.1.11
  2. vendure = ^1.0.0

Vendure worker is crashing in loop with following error

(node:29) UnhandledPromiseRejectionWarning: LockNotSupportedOnGivenDriverError: Locking not supported on given driver. at new LockNotSupportedOnGivenDriverError (/usr/src/app/node_modules/typeorm/error/LockNotSupportedOnGivenDriverError.js:10:28) at SelectQueryBuilder.createLockExpression (/usr/src/app/node_modules/typeorm/query-builder/SelectQueryBuilder.js:1254:27) at SelectQueryBuilder.getQuery (/usr/src/app/node_modules/typeorm/query-builder/SelectQueryBuilder.js:54:21) at SelectQueryBuilder.QueryBuilder.getQueryAndParameters (/usr/src/app/node_modules/typeorm/query-builder/QueryBuilder.js:243:26) at SelectQueryBuilder.<anonymous> (/usr/src/app/node_modules/typeorm/query-builder/SelectQueryBuilder.js:1594:50) at step (/usr/src/app/node_modules/typeorm/node_modules/tslib/tslib.js:141:27) at Object.next (/usr/src/app/node_modules/typeorm/node_modules/tslib/tslib.js:122:57) at /usr/src/app/node_modules/typeorm/node_modules/tslib/tslib.js:115:75 at new Promise (<anonymous>) at Object.__awaiter (/usr/src/app/node_modules/typeorm/node_modules/tslib/tslib.js:111:16) (Use node --trace-warnings ... to show where the warning was created)

@blathers-crl
Copy link

blathers-crl bot commented Jan 13, 2022

Hello, I am Blathers. I am here to help you get the issue triaged.

It looks like you have not filled out the issue in the format of any of our templates. To best assist you, we advise you to use one of these templates.

I was unable to automatically find someone to ping.

If we have not gotten back to your issue within a few business days, you can try the following:

  • Join our community slack channel and ask on #cockroachdb.
  • Try find someone from here if you know they worked closely on the area and CC them.

🦉 Hoot! I am a Blathers, a bot for CockroachDB. My owner is otan.

@blathers-crl blathers-crl bot added O-community Originated from the community X-blathers-untriaged blathers was unable to find an owner labels Jan 13, 2022
@msbutler
Copy link
Collaborator

seems like vendure is built on graphql, which currently does not support crdb. hasura/graphql-engine#678

@msbutler msbutler added the T-sql-foundations SQL Foundations Team (formerly SQL Schema + SQL Sessions) label Jan 13, 2022
@rafiss
Copy link
Collaborator

rafiss commented Jan 13, 2022

In this case it looks like the error is coming from TypeORM, specifically here: https://github.com/typeorm/typeorm/blob/90a8deb6383c31686965893cdea96151f40be396/src/query-builder/SelectQueryBuilder.ts#L1699

@vaibhavsanap can you please sure the version of TypeORM you are using?

Most likely the problem is that your app is generating a query using syntax we don't support; see #40476

Consider filing an issue with the vendure project, to see if they can add CockroachDB support. cc @kernfeld-cockroach

@rafiss rafiss changed the title Locking not supported on given driver tools: support the Vendure framework Jan 13, 2022
@rafiss rafiss removed the X-blathers-untriaged blathers was unable to find an owner label Jan 13, 2022
@vaibhavsanap
Copy link
Author

vaibhavsanap commented Jan 14, 2022

@rafiss
Following type orm dependencies are are added as part of vendure core 1.0.0.
typeorm "0.2.31"
"@nestjs/typeorm" "7.1.5"

@vaibhavsanap
Copy link
Author

@rafiss we are able o integrate cockroachDB with vendure.
Above issue disappeared once we started using BullMQPlugin

@rafiss
Copy link
Collaborator

rafiss commented Jan 19, 2022

Glad to hear it!

@rafiss rafiss closed this as completed Jan 19, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
O-community Originated from the community T-sql-foundations SQL Foundations Team (formerly SQL Schema + SQL Sessions)
Projects
None yet
Development

No branches or pull requests

3 participants