buda-base / lds-queries

A repository for BUDA Linked Data Server
Apache License 2.0
0 stars 1 forks source link

jena text query cache mechanism #18

Closed eroux closed 4 years ago

eroux commented 4 years ago

@xristy this is a tricky question for you:

I often use this pattern in the queries: I do a text search several times in different unions (example). It's fast as the result gets cached the first time. I just had the idea "hey, maybe in the calls after the first one I don't need to pass the "highlight:" argument and I don't need to get the score and match... but then I wondered how the cache behave if I:

Would you happen to know that Chris?

xristy commented 4 years ago

@eroux the cache key is computed via:

String cacheKey = subj + " " + limit + " " + match.getProps() + " " + qs + " " + lang + " " + graphURI ;

It doesn't depend on the score or highlight.

eroux commented 4 years ago

ah excellent, thanks! what's in match.getProps()?