Cfobject cache action="clear" filter="susi" question

40 views
Skip to first unread message

Serge Droganov

unread,
Jul 31, 2011, 2:57:19 PM7/31/11
to Railo
Hi, again.
In Railo wiki is said that:
<cfobjectcache action="clear" filter="susi">

would clear all the caches from the tables with name like %susi%.
If i get it right, this expression would match all of this tables (for
example): susi, susipusi, pusisusi, pusisusimasusi.

In fact it doesn't work at all. I have caches from table 'ad' and I
set:
<cfobjectcache action="clear" filter="ad"> and see the old query (hit
f5 and see it again).

So my questions are:
1. How to write the expression that would match table name exatly
(%like% is no good for me)?
2. How to write the expression that would match any of several given
tables exactly and in the same time?
3. How to make sure 1 and 2 works?
4. Logical question: what if I have several datasources for different
databases, but table names are the same? Would my code flush all
caches when I need only to flush db2.table1? How to manage that?

Thank you,
Serge

Andrea Campolonghi

unread,
Aug 1, 2011, 3:06:23 AM8/1/11
to ra...@googlegroups.com
I think filter apply on the sql body of the cached query.

Andrea

Andrea Campolonghi
and...@getrailo.org

Serge Droganov

unread,
Aug 1, 2011, 4:58:20 AM8/1/11
to Railo
Hello Andrea,
You confuse me :-)
I don't really care what is it actually applies, I would like to know
how to make my staff work.
Wiki examples just don't work.

Andrea Campolonghi

unread,
Aug 1, 2011, 6:22:00 AM8/1/11
to ra...@googlegroups.com
On Jul 31, 2011, at 8:57 PM, Serge Droganov wrote:

1. How to write the expression that would match table name exatly
(%like% is no good for me)?

I think this is the only kind expression you can use but I am not 100% sure about that.

2. How to write the expression that would match any of several given
tables exactly and in the same time?

AFAIK Expression is not runned vs a table name but vs the sql statement that originated the cached query.
So the match depends on the sql statement. 

3. How to make sure 1 and 2 works?

If you dump a query result you will get notified if the query comes form db or was cached.

4. Logical question: what if I have several datasources for different
databases, but table names are the same? Would my code flush all
caches when I need only to flush db2.table1? How to manage that?

Not sure if is created a different pool for differents datasources. 

Andrea Campolonghi



Andrea Campolonghi

unread,
Aug 1, 2011, 6:39:30 AM8/1/11
to ra...@googlegroups.com
Btw if you have a test case post it here or raise a bug in Jira.

Thanks

Andrea

On Jul 31, 2011, at 8:57 PM, Serge Droganov wrote:

<cfobjectcache action="clear" filter="susi">

Andrea Campolonghi



Michael Offner

unread,
Aug 2, 2011, 4:03:57 AM8/2/11
to ra...@googlegroups.com
there was a problem https://issues.jboss.org/browse/RAILO-1385 we have solved.
perhaps you simply have to do a update to the most recent version.
if it still does not work like you think with the most recent version, please reopen this ticket with a testcase and your version number

/micha

2011/7/31 Serge Droganov <design...@gmail.com>
Reply all
Reply to author
Forward
0 new messages