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

Misleading Cassandra TTL property name #1728

Open
tusharleek opened this issue Nov 12, 2024 · 3 comments
Open

Misleading Cassandra TTL property name #1728

tusharleek opened this issue Nov 12, 2024 · 3 comments

Comments

@tusharleek
Copy link

Can we please change name or its implementation as the value I am assigning this using properties is in milliseconds and field name is time-to-live-seconds and can we add any provision that if I add or update this field value then after application restart changes will reflect as of now it only works if table is not there previously

@jitokim
Copy link
Contributor

jitokim commented Nov 14, 2024

It should be seconds
and this TTL is used when creating the table

createTableWithOptions = createTableWithOptions.withDefaultTimeToLiveSeconds(this.timeToLiveSeconds);

@tusharleek
Copy link
Author

Yes But when in properties I am providing
spring:
ai:
chat:
memory:
cassandra:
keyspace: conversation
time-to-live-seconds: 120000

then my rows are deleting after 120 seconds

if I am using above property in logs you can see that defaultTimetoLive is 120 even after setting 120000 in properties

Screenshot 2024-11-14 at 10 20 30 PM

jitokim added a commit to jitokim/spring-ai that referenced this issue Nov 14, 2024
jitokim added a commit to jitokim/spring-ai that referenced this issue Nov 14, 2024
@jitokim
Copy link
Contributor

jitokim commented Nov 14, 2024

@tusharleek
I have created a PR. Please review it 😃

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

No branches or pull requests

2 participants