Redis extension problem 6.0.0.496

Running 6.0.0.496-SNAPSHOT here now, and can’t seem to install the redis extension anymore:

Unable to resolve redis.extension [90](R 90.0): missing requirement [redis.extension [90](R 90.0)] osgi.wiring.bundle; (&(osgi.wiring.bundle=org.lucee.aws-core)(bundle-version>=1.12.348)) [caused by: Unable to resolve org.lucee.aws-core [93](R 93.0): missing requirement [org.lucee.aws-core [93](R 93.0)] osgi.wiring.package; (osgi.wiring.package=com.fasterxml.jackson.annotation)] Unresolved requirements: [[redis.extension [90](R 90.0)] osgi.wiring.bundle; (&(osgi.wiring.bundle=org.lucee.aws-core)(bundle-version>=1.12.348))]

did u try the latest snapshot?

please always mention the relevant versions when asking for help!

Just trying that now, we download and use local extensions. So the 3.0.0.48 version worked with the last RC

as you can see here, there’s been recent work done

https://download.lucee.org/#60772C12-F179-D555-8E2CD2B4F7428718

3.0.0.54-SNAPSHOT installs… and I’m now seeing the same issue that lucee 6 has had with certain redis caching, I’m going to try and get a test case working

1 Like

OK, the issue we’re seeing at the moment is to do with this very simplified bit of code

	sql = "select @@version";
	cachePut("foo", queryExecute(SQL, [], {"datasource": myDSN}), 1);
	dump(cacheGet("foo"));

	cachePut("foo2", [], 1);
	dump(cacheGet("foo2"));

	abort;

Refreshing this multiple times foo2 always comes back as an array, however every random x tries foo returns null.

Our app has this in an if statement, so if it runs and a null is set, we aren’t retrying.

Interestingly (or not)

	sql = "select @@version";
	cachePut("foo", queryExecute(SQL, [], {"datasource": myDSN}), 1);
	dump(cacheGet("foo"));
	dump(cacheGet("foo"));
	dump(isNull(cacheGet("foo")));

Outputs:

Randomly null or query
null
true

this is the same problem [LDEV-4413] - Lucee ?

I don’t think so…

When writing an array and struct it seems to perform as expected. With the query the first cacheGet() is either null or the query, the other cacheGets (and isNull) are always null. I’d expect then to be the same as the first cacheGet

But this stuff is now a little above me :wink:

it’s a race condition, looks similar

same problem if you remove the query execute?? KISS, trying to reduce the test case to the bare minimum here

also if you wacks a few sleeps in there it works as expected?

	sql = "select @@version";
	cachePut("foo", queryExecute(SQL, [], {"datasource": myDSN}), 1);
	sleep(3);
	dump(cacheGet("foo"));
	dump(cacheGet("foo"));
	dump(isNull(cacheGet("foo")));

Now consistently returns

	null
	null
	true

my (limited) mental model of Redis is that it’s not an ACID database and shouldn’t be expected to act like one, however similar it appears to be?

not saying this isn’t a bug

Just ran the page with debug output on and noticed that an application-wide query we run is not caching using the cachedwithin option and adding a small one to the test page doesn’t cache either… Going to retry with the production version of lucee we’re running to make sure I’m not going mad

Reverting to Lucee 5.3.10.120 using the Redis 3.0.0.48 extension, all the caching is back and working as expected.

So the above foo test brings back

	query
	query
	false

each time and a dump of a queryExecute with cachedwithin set has Cached: Yes in it