lucee / extension-redis

Lucee Redis Cache Extension
10 stars 13 forks source link

copy NearCacheEntry values as-if they had been materialized from cache #16

Open davidAtInleague opened 1 year ago

davidAtInleague commented 1 year ago

Goal here being to not share live object refs to the underlying "to-be-cached" objects across NearCacheEntry objects

resolves #13

MordantWastrel commented 1 year ago

@zspitzer any chance we can get some traction on this?

zspitzer commented 1 year ago

I've asked @michaeloffner to review

any chance of adding some tests?

MordantWastrel commented 1 year ago

It looks like a day or two to get the current test suite running and add a test for this. We can find time for that but probably not until later this year.

MordantWastrel commented 11 months ago

@zspitzer We've signed off on a day or so of work to get some tests in. Once that's done we're hopeful this can get merged in as otherwise we will need to fork this and build our own extension or use Ortus'. I think there is at least one other dev in the community who has done that so it might be worth looking to see whether there is interest in recruiting additional community members to help out with this extension (if it is indeed an official Lucee extension) or if it's more 'something the folks at LAS needed and helpfully decided to release but otherwise don't have time to maintain' -- either way is fine but it'd help us to know how you all look at it!

Thanks as always!

davidAtInleague commented 11 months ago

I've asked @michaeloffner to review

any chance of adding some tests?

yes there is a test now; introduced in 0f7d5c5478f32aa55b33d09d96643fad207bc961, where the problem is reproduced and so the test fails. The fix is introduced in the subsequent commit and the test turns green.

davidAtInleague commented 11 months ago

I can't reproduce the failure against 5.4 locally, so maybe some additional as-yet-to-be-addressed race condition? The failing test appears to be testTwoLockedButReleasedOneLater. I've attached the generated test run's xml where that test passes, in case it's useful (had to rename to .txt for github to accept it, ha). I didn't try against 6 because it looks like it has been red for a while.

junit-test-results-5.4.3.2.xml.txt