Skip to content
This repository was archived by the owner on Jan 24, 2024. It is now read-only.

Conversation

@eolivelli
Copy link
Contributor

@eolivelli eolivelli commented Feb 13, 2022

Modifications

  • use a shared threadpool
  • lazily start the drainQueuedTransactionMarkers activity only when needed
  • set period to 100ms (instead of 1ms)

Result
If a tenant never uses transactions, then you never start the background activity, also we are able to scale the number for active tenants.

A future improvement may be to shutdown the activity when a tenant is idle for a while

- use a shared threadpool
- lazily start the drainQueuedTransactionMarkers activity only when needed
- set period to 100ms (instead of 1ms)
@eolivelli
Copy link
Contributor Author

CI failed, checking

@eolivelli
Copy link
Contributor Author

Ci passed

@BewareMyPower BewareMyPower merged commit 12cf707 into streamnative:master Feb 24, 2022
@eolivelli eolivelli deleted the fix/transactions-shared-threadpool branch February 24, 2022 10:04
BewareMyPower pushed a commit that referenced this pull request Feb 25, 2022
**Modifications**
- use a shared threadpool
- lazily start the drainQueuedTransactionMarkers activity only when needed
- set period to 100ms (instead of 1ms)

**Result**
If a tenant never uses transactions, then you never start the background activity, also we are able to scale the number for active tenants.

A future improvement may be to shutdown the activity when a tenant is idle for a while

(cherry picked from commit 12cf707)
BewareMyPower pushed a commit that referenced this pull request Feb 25, 2022
**Modifications**
- use a shared threadpool
- lazily start the drainQueuedTransactionMarkers activity only when needed
- set period to 100ms (instead of 1ms)

**Result**
If a tenant never uses transactions, then you never start the background activity, also we are able to scale the number for active tenants.

A future improvement may be to shutdown the activity when a tenant is idle for a while

(cherry picked from commit 12cf707)
BewareMyPower pushed a commit that referenced this pull request Feb 25, 2022
**Modifications**
- use a shared threadpool
- lazily start the drainQueuedTransactionMarkers activity only when needed
- set period to 100ms (instead of 1ms)

**Result**
If a tenant never uses transactions, then you never start the background activity, also we are able to scale the number for active tenants.

A future improvement may be to shutdown the activity when a tenant is idle for a while

(cherry picked from commit 12cf707)
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants