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

fix: LRU cache memory leak. #475

Merged
merged 1 commit into from
May 31, 2024
Merged

fix: LRU cache memory leak. #475

merged 1 commit into from
May 31, 2024

Conversation

kinyoklion
Copy link
Member

@kinyoklion kinyoklion commented May 31, 2024

Fixes #474

expect(lruCache.get(`${i + 100}`)).toEqual(i);
}

// Check old keys don't associate with new values.
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Without clearing the key map these would reference the old values.

@kinyoklion kinyoklion requested a review from keelerm84 May 31, 2024 22:48
@kinyoklion kinyoklion merged commit a5fdefc into main May 31, 2024
19 checks passed
@kinyoklion kinyoklion deleted the rlamb/clear-lru-keymap branch May 31, 2024 22:50
@github-actions github-actions bot mentioned this pull request May 24, 2024
kinyoklion pushed a commit that referenced this pull request Jun 3, 2024
🤖 I have created a release *beep* *boop*
---


<details><summary>akamai-edgeworker-sdk-common: 1.1.8</summary>

##
[1.1.8](akamai-edgeworker-sdk-common-v1.1.7...akamai-edgeworker-sdk-common-v1.1.8)
(2024-05-31)


### Dependencies

* The following workspace dependencies were updated
  * dependencies
    * @launchdarkly/js-server-sdk-common bumped from ^2.4.1 to ^2.4.2
</details>

<details><summary>akamai-server-base-sdk: 2.1.8</summary>

##
[2.1.8](akamai-server-base-sdk-v2.1.7...akamai-server-base-sdk-v2.1.8)
(2024-05-31)


### Dependencies

* The following workspace dependencies were updated
  * dependencies
* @launchdarkly/akamai-edgeworker-sdk-common bumped from ^1.1.7 to
^1.1.8
    * @launchdarkly/js-server-sdk-common bumped from ^2.4.1 to ^2.4.2
</details>

<details><summary>akamai-server-edgekv-sdk: 1.1.8</summary>

##
[1.1.8](akamai-server-edgekv-sdk-v1.1.7...akamai-server-edgekv-sdk-v1.1.8)
(2024-05-31)


### Dependencies

* The following workspace dependencies were updated
  * dependencies
* @launchdarkly/akamai-edgeworker-sdk-common bumped from ^1.1.7 to
^1.1.8
    * @launchdarkly/js-server-sdk-common bumped from ^2.4.1 to ^2.4.2
</details>

<details><summary>cloudflare-server-sdk: 2.5.6</summary>

##
[2.5.6](cloudflare-server-sdk-v2.5.5...cloudflare-server-sdk-v2.5.6)
(2024-05-31)


### Dependencies

* The following workspace dependencies were updated
  * devDependencies
    * @launchdarkly/js-server-sdk-common-edge bumped from 2.3.1 to 2.3.2
</details>

<details><summary>js-server-sdk-common: 2.4.2</summary>

##
[2.4.2](js-server-sdk-common-v2.4.1...js-server-sdk-common-v2.4.2)
(2024-05-31)


### Bug Fixes

* LRU cache memory leak.
([#475](#475))
([a5fdefc](a5fdefc)),
closes [#474](#474)
</details>

<details><summary>js-server-sdk-common-edge: 2.3.2</summary>

##
[2.3.2](js-server-sdk-common-edge-v2.3.1...js-server-sdk-common-edge-v2.3.2)
(2024-05-31)


### Dependencies

* The following workspace dependencies were updated
  * dependencies
    * @launchdarkly/js-server-sdk-common bumped from 2.4.1 to 2.4.2
</details>

<details><summary>node-server-sdk: 9.4.4</summary>

##
[9.4.4](node-server-sdk-v9.4.3...node-server-sdk-v9.4.4)
(2024-05-31)


### Dependencies

* The following workspace dependencies were updated
  * dependencies
    * @launchdarkly/js-server-sdk-common bumped from 2.4.1 to 2.4.2
</details>

<details><summary>node-server-sdk-dynamodb: 6.1.13</summary>

##
[6.1.13](node-server-sdk-dynamodb-v6.1.12...node-server-sdk-dynamodb-v6.1.13)
(2024-05-31)


### Dependencies

* The following workspace dependencies were updated
  * devDependencies
    * @launchdarkly/node-server-sdk bumped from 9.4.3 to 9.4.4
  * peerDependencies
    * @launchdarkly/node-server-sdk bumped from >=9.4.3 to >=9.4.4
</details>

<details><summary>node-server-sdk-otel: 1.0.5</summary>

##
[1.0.5](node-server-sdk-otel-v1.0.4...node-server-sdk-otel-v1.0.5)
(2024-05-31)


### Dependencies

* The following workspace dependencies were updated
  * devDependencies
    * @launchdarkly/node-server-sdk bumped from 9.4.3 to 9.4.4
  * peerDependencies
    * @launchdarkly/node-server-sdk bumped from >=9.4.3 to >=9.4.4
</details>

<details><summary>node-server-sdk-redis: 4.1.13</summary>

##
[4.1.13](node-server-sdk-redis-v4.1.12...node-server-sdk-redis-v4.1.13)
(2024-05-31)


### Dependencies

* The following workspace dependencies were updated
  * devDependencies
    * @launchdarkly/node-server-sdk bumped from 9.4.3 to 9.4.4
  * peerDependencies
    * @launchdarkly/node-server-sdk bumped from >=9.4.3 to >=9.4.4
</details>

<details><summary>react-native-client-sdk: 10.1.4</summary>

##
[10.1.4](react-native-client-sdk-v10.1.3...react-native-client-sdk-v10.1.4)
(2024-05-31)


### Bug Fixes

* Added iOS SettingsManager null check.
([#471](#471))
([8ff641b](8ff641b))
</details>

<details><summary>vercel-server-sdk: 1.3.9</summary>

##
[1.3.9](vercel-server-sdk-v1.3.8...vercel-server-sdk-v1.3.9)
(2024-05-31)


### Dependencies

* The following workspace dependencies were updated
  * dependencies
    * @launchdarkly/js-server-sdk-common-edge bumped from 2.3.1 to 2.3.2
</details>

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
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.

Memory Leak Inside LruCache
2 participants