-
Notifications
You must be signed in to change notification settings - Fork 147
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
Connection attempts time out when connecting using Bun #1140
Comments
Hey @Giant-Jelly, thanks for reporting. This driver has not support for I will register the request in our internally and I will keep this thread issue updated. |
The problem with Bun happens when use SSL ( Driver's Websocket channel implementation works fine in most of the cases, but this still pending more extensive tests. |
Has it not been fixed yet? |
This feature stills depending on Bun implements crypto and TLS. WebSockets is not production ready either, see https://bun.sh/docs/runtime/web-apis. |
You can also import the driver like this: import neo4j from 'neo4j-driver/lib/browser/neo4j-web.esm.js' and use the browser version of the driver. It will might work for most of the cases, but I don't consider this production ready since |
@bigmontz does the browser substitute sockets for fetch calls? The browser version does work well in bun but I would like to know the tradeoffs when it comes to using only the browser version |
The browser version uses WebSockets instead of TCP Sockets. This causes performance losses, especially when creating and closing connections. PS: This usage is not homologated by integration and acceptance tests, also. |
It looks like when running the neo4j driver with bun (
bun index.ts
orbun index.js
) the connection to the database times out. But when running with node (node index.js
) it connects fine.Here is my index.js
Output from
bun index.js
output from
node index.js
Node version v20.3.1
Bun version 1.0.0
Driver version: Latest
Neo4j version: Latest
Same behaviour with neo4j-driver and neo4j-driver-lite
Is this already a known issue? I feel like if it was because the driver is using something in node that is not supported by Bun that there would be an error instead of a timeout.
The text was updated successfully, but these errors were encountered: