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

Slow Teardown for Realm #3620

Closed
sync-by-unito bot opened this issue Mar 2, 2021 · 0 comments
Closed

Slow Teardown for Realm #3620

sync-by-unito bot opened this issue Mar 2, 2021 · 0 comments

Comments

@sync-by-unito
Copy link

sync-by-unito bot commented Mar 2, 2021

While testing issues with Jest, I noticed that the teardown for Realm is quite slow. A simple open and close will take about 10 seconds before the process finally closes.
Here is a sample in Jest:

describe('realm', () => {
  it('can open without crashing', async () => {
    const realm = await Realm.open({schema:[TodoList, TodoItem], inMemory:true})
    realm.close()
    expect(1).toEqual(1)
  })
})

Here is an example in Node:

const Realm = require("realm");

let realm = new Realm( { schema: [
    {
        name: "Simple",
        properties: {
            v: "string",
        }
    }
]});
realm.write(() => {
    realm.create("Simple", { v: "Hello" });
});
realm.close();

We should see if it's possible to make the teardown instantaneous.

@sync-by-unito sync-by-unito bot closed this as completed Nov 25, 2021
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Mar 16, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

0 participants