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

Using Reactive variables occurs a memory leak on the SSR #8387

Closed
choijungseon opened this issue Jun 14, 2021 · 5 comments
Closed

Using Reactive variables occurs a memory leak on the SSR #8387

choijungseon opened this issue Jun 14, 2021 · 5 comments

Comments

@choijungseon
Copy link

choijungseon commented Jun 14, 2021

Intended outcome

Using Reactive variables on the SSR shouldn't create a memory leak.

Actual outcome

Using Reactive variables on the SSR creates a memory leak when i follow the example.(https://www.apollographql.com/docs/react/local-state/managing-state-with-field-policies/#example)

  • Note that, we creates new apollo client, reactiveVar instances for every request

But if i try to access Reactive variables with useReactiveVar, the app doesn't create a memory leak.

heapdump output

image

Versions

{
   "next": "^10.1.2",
    "apollo/client": "3.3.19",
    "apollo-server-micro": "^2.14.2",
    ...
}
@ronparkdev
Copy link

I added discussion related this issue

https://github.com/apollographql/apollo-client/discussions/8455
Please check it when you review this issue :)

@sepehrrtl
Copy link

I also have the same issue. I upgraded apollo/client to 3.4.0-rc.20 but the issue still exists.

@phryneas
Copy link
Member

phryneas commented Feb 6, 2024

Hi there!
I'm doing some housekeeping right now and I believe this has been addressed in newer versions of Apollo Client, so I'm going to close this issue now.
If this comes up again in newer versions (>=3.9.0) of Apollo Client, please open a new issue :)

@phryneas phryneas closed this as completed Feb 6, 2024
Copy link
Contributor

github-actions bot commented Feb 6, 2024

Do you have any feedback for the maintainers? Please tell us by taking a one-minute survey. Your responses will help us understand Apollo Client usage and allow us to serve you better.

Copy link
Contributor

github-actions bot commented Mar 9, 2024

This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.
For general questions, we recommend using StackOverflow or our discord server.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Mar 9, 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

5 participants