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

Check for expiry only if a record's state is READ_PERMITTED #16067

Merged
merged 2 commits into from Nov 20, 2019

Conversation

@ahmetmircik
Copy link
Member

ahmetmircik commented Nov 20, 2019

otherwise stats calculation can be distorted 

closes hazelcast/hazelcast-enterprise#3273

@ahmetmircik

This comment has been minimized.

Copy link
Member Author

ahmetmircik commented Nov 20, 2019

run-lab-run

Copy link
Contributor

vbekiaris left a comment

looks good, a minor comment

@@ -179,6 +179,12 @@ protected long getTotalStorageMemoryCost(K key, R record) {
}

protected boolean isRecordExpired(R record) {
if (!canUpdateStats(record)) {
// A record can only be checked for expiry if its record state is
// READ_PERMITTED. We can check reserved records for expiry.

This comment has been minimized.

Copy link
@vbekiaris

vbekiaris Nov 20, 2019

Contributor

should read "We can't check reserved records"

This comment has been minimized.

Copy link
@ahmetmircik

ahmetmircik Nov 20, 2019

Author Member

fixed.

@ahmetmircik ahmetmircik force-pushed the ahmetmircik:fix/4.0/nearCacheStats branch 2 times, most recently from 78ea372 to 5ce3811 Nov 20, 2019
@Holmistr

This comment has been minimized.

Copy link
Collaborator

Holmistr commented Nov 20, 2019

run-lab-run

1 similar comment
@Holmistr

This comment has been minimized.

Copy link
Collaborator

Holmistr commented Nov 20, 2019

run-lab-run

otherwise stats calculation can be distorted 
@ahmetmircik ahmetmircik force-pushed the ahmetmircik:fix/4.0/nearCacheStats branch from 5ce3811 to c0a9c6a Nov 20, 2019
@ahmetmircik ahmetmircik force-pushed the ahmetmircik:fix/4.0/nearCacheStats branch from c0a9c6a to e4de450 Nov 20, 2019
@ahmetmircik ahmetmircik changed the title Check for expiry only if a record's state is READ_PERMITTED Check for expiry only if a record's state is READ_PERMITTED Nov 20, 2019
@ahmetmircik ahmetmircik merged commit d695653 into hazelcast:master Nov 20, 2019
1 check passed
1 check passed
default Test PASSed.
Details
@ahmetmircik ahmetmircik deleted the ahmetmircik:fix/4.0/nearCacheStats branch Nov 20, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
4 participants
You can’t perform that action at this time.