Skip to content

make read txn timeout configurable and set default to 1min#304

Open
ldt1996 wants to merge 4 commits intomainfrom
read_txn_expiration
Open

make read txn timeout configurable and set default to 1min#304
ldt1996 wants to merge 4 commits intomainfrom
read_txn_expiration

Conversation

@ldt1996
Copy link
Copy Markdown
Contributor

@ldt1996 ldt1996 commented Mar 31, 2026

Is 1min as default ideal, or should we set another timeout?

@ldt1996 ldt1996 requested a review from a team as a code owner March 31, 2026 11:40
Copy link
Copy Markdown
Member

@kriszyp kriszyp left a comment

Choose a reason for hiding this comment

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

Thank for getting this configuration in!

Comment thread resources/RecordEncoder.ts Outdated
const trackedTxns: WeakRef<any>[] = [];
setInterval(() => {
const configValue = envMngr.get(CONFIG_PARAMS.STORAGE_MAXREADTRANSACTIONOPENTIME) ?? 60000;
let READ_TXN_TIMEOUT_TICKS = Math.round(Math.min(Math.max(configValue, 15000), 300000) / 15000); // clamp between 15s and 5min
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I don't think we actually need to clamp this. I know I had mentioned concerns about excessively long timeouts here, but that was more of a consideration for those setting the value, but I trust that we can set the value properly. And I think that a default of one minute is too short. I believe the previous setting was 15 minutes, right? Maybe the default should be 5 minutes?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

here it is finally 93cafaa

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.

4 participants