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

Add 'expireAt' To Set TTL With Date Object #211

Merged
merged 2 commits into from
Oct 27, 2023

Conversation

garrett-green
Copy link
Contributor

@garrett-green garrett-green commented Sep 16, 2023

Creates expireAt method on Repository, adding option to set TTL of entity/entities using a Date object (as requested in issue #120 ).

@garrett-green garrett-green mentioned this pull request Sep 16, 2023
@garrett-green
Copy link
Contributor Author

@guyroyse Would it be possible for you to please take a look and weigh-in on this PR?

Copy link
Contributor

@guyroyse guyroyse left a comment

Choose a reason for hiding this comment

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

This looks really good. Just one bit of feedback and then I'll merge it an publish a new version. Sorry it's taken so long for me to respond but thanks so much for a solid contribution!

lib/repository/repository.ts Outdated Show resolved Hide resolved
@garrett-green
Copy link
Contributor Author

@guyroyse Thank you for reviewing and leaving feedback!

I just updated the branch/PR to utilize the Redis' EXPIREAT via the client's .expireAt method and simplified the handling logic in the repository.

Please let me know if you think it need any other updates!

Copy link
Contributor

@guyroyse guyroyse left a comment

Choose a reason for hiding this comment

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

LGTM

@guyroyse guyroyse merged commit 9872e6d into redis:main Oct 27, 2023
0 of 3 checks passed
@guyroyse
Copy link
Contributor

Merged and published. https://www.npmjs.com/package/redis-om

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.

2 participants