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

Improve DX with webserver and REPL when neo4j connection is not available #2939

Merged
merged 6 commits into from
Nov 11, 2023

Conversation

CarsonF
Copy link
Member

@CarsonF CarsonF commented Nov 10, 2023

Many of these improvements are just restoring functionality that regressed with recent neo4j upgrades.

I changed REPL to not wait for neo4j indexes or admin setup. This is almost never needed.

I changed the root admin session to be lazily loaded, so REPL can start without it.
This will load the root user ID when the DB connection becomes available.
If trying to access session.userId before DB connection is established / ID is loaded an error is thrown.
await session will wait for the ID to be populated, but FYI you could be waiting for forever.

┆Issue is synchronized with this Monday item by Unito

…versions

I believe the `executeRead` was throwing the error now,
which was previously not correctly converted.
…without DB connection

An error will be thrown if trying to access userId before loaded.
You can wait for the session to be loaded by awaiting it.
`await session`
@CarsonF CarsonF merged commit e84564c into develop Nov 11, 2023
14 checks passed
@CarsonF CarsonF deleted the neo4j/fix-connection-wait branch November 11, 2023 00:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant