SystemCacheClear() throws error "Reduced views don't contain document ids"

I have declared that all my caches go to couchbase in application.cfc

THIS.cache.object = “cbluceestore”;
THIS.cache.template = “cbluceestore”;
THIS.cache.query = “cbluceestore”;
THIS.cache.resource = “cbluceestore”;
THIS.cache.function = “cbluceestore”;
THIS.cache.include = “cbluceestore”;

I then proceed to cache a query which I can see in couchbase as the only document in that bucket.

I then attempt to use


I would assume that that would clear the cached query. Instead I get:

Lucee Error (java.lang.UnsupportedOperationException)
Message Reduced views don’t contain document ids
Cause java.lang.UnsupportedOperationException
Stacktrace The Error Occurred in
C:\Sites\www\breakdown-services-full_wwwroot\test.cfm: line 13

13: SystemCacheClear();

Java Stacktrace Reduced views don’t contain document ids
at com.couchbase.client.protocol.views.ViewRowReduced.getId(
at ortus.extension.cache.couchbase.CouchbaseCache.remove(Unknown Source):-1
at lucee.runtime.cache.tag.timespan.TimespanCacheHandler.clear(
at lucee.runtime.cache.tag.CacheHandlerFactory.clear(
at lucee.runtime.functions.system.SystemCacheClear.queryCache(
at test_cfm$\Sites\www\breakdown-services-full_wwwroot\test.cfm:13):13
at lucee.runtime.PageContextImpl.doInclude(
at lucee.runtime.PageContextImpl.doInclude(
at lucee.runtime.listener.ModernAppListener._onRequest(
at lucee.runtime.listener.ModernAppListener.onRequest(
at lucee.runtime.PageContextImpl.execute(
at lucee.runtime.PageContextImpl.execute(
at lucee.runtime.engine.CFMLEngineImpl.serviceCFML(
at lucee.loader.servlet.CFMLServlet.service(Unknown Source):-1
at javax.servlet.http.HttpServlet.service(
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(
at org.apache.catalina.core.ApplicationFilterChain.doFilter(
at org.apache.tomcat.websocket.server.WsFilter.doFilter(
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(
at org.apache.catalina.core.ApplicationFilterChain.doFilter(
at org.apache.catalina.core.StandardWrapperValve.invoke(
at org.apache.catalina.core.StandardContextValve.invoke(
at org.apache.catalina.authenticator.AuthenticatorBase.invoke(
at org.apache.catalina.core.StandardHostValve.invoke(
at org.apache.catalina.valves.ErrorReportValve.invoke(
at org.apache.catalina.valves.AbstractAccessLogValve.invoke(
at org.apache.catalina.core.StandardEngineValve.invoke(
at org.apache.catalina.connector.CoyoteAdapter.service(
at org.apache.coyote.ajp.AbstractAjpProcessor.process(
at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(
at java.util.concurrent.ThreadPoolExecutor.runWorker(
at java.util.concurrent.ThreadPoolExecutor$
at org.apache.tomcat.util.threads.TaskThread$

It seems that all of the lucee cache functions are throwing that same error. The first view in couchbase for the cache bucket has a reduce function. If I remove _reduce from the view then cache functions begin to work properly.

ie CacheGetAllIds("",“cbluceestore”)

How can I define which view the extension is to use when connecting to CB?

I also noticed this error in tomcat when the app starts:

2016-08-09 10:10:11.552 INFO com.couchbase.client.CouchbaseClient: viewmode property isn’t defined. Setting viewmode to production mode

It seems to me that there are additional settings that are not in the lucee admin / couchbase extension.

Hi Marc,

I believe we have a screenshare with you on Thursday. We will address these issues. Please note that the SystemCacheClear() requires the name of the cache as an argument. Did you pass it?

*> **How can I define which view the extension is to use when connecting to

You can't, the extension creates the view it needs automatically. Can you
confirm if there is a view named "*LuceeCouchbase_allKeys*"? That is the
name of the view that is used and it should not have a reduce function.
Did you by chance manually edit this view and add a reduce function?

I also noticed this error in tomcat when the app starts:

That is not an error. You can see from the log entry, it is marked "INFO"
which means it's informational. It doesn't not represent anything



*Developer Advocate*
*Ortus Solutions, Corp *

ColdBox Platform: