Quantcast

Foswiki Caching & %SEARCH% within %INCLUDE%

classic Classic list List threaded Threaded
7 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Foswiki Caching & %SEARCH% within %INCLUDE%

Paul L. Merchant Jr.
Hi everyone, I think I've run into a bug due to an interaction between the DBCachePlugin, %INCLUDE% and %SEARCH%, and it's not really clear on the Foswiki.org site how to report problems, so I'm throwing this at the mailing list in hopes that either someone knows a solution or is willing to point me at the proper place to report bugs.  (Is it the Foswiki Support page?)

I have a search with a regular expression to match on a configurable topic prefix:

%STARTSECTION{MyTopics}%
%SEARCH{"^%NAME_PREFIX%\d{4}$" web="%BASEWEB%" scope="topic" type="regex" sort="topic" reverse="on" nonoise="on" format="$percntINCLUDE{\"$web.$topic\" headingoffset=\"2\"}$percnt" }%
%ENDSECTION{MyTopics}%


The section containing the search is included on various pages with different values given for %NAME_PREFIX%.  This works as I expect.  Of course, when I turn page caching on (using an SQLLite cache for testing), the search isn't updated if a new page is created that matches the search.  So I tried putting the search within a <dirtyarea> tag:

%STARTSECTION{MyTopics}%
<dirtyarea>
%SEARCH{"^%NAME_PREFIX%\d{4}$" web="%BASEWEB%" scope="topic" type="regex" sort="topic" reverse="on" nonoise="on" format="$percntINCLUDE{\"$web.$topic\" headingoffset=\"2\"}$percnt" }%
</dirtyarea>
%ENDSECTION{MyTopics}%

This breaks the search entirely.  It no longer matches anything.  Some experimenting suggests that the regular expression searching is broken by the <dirtyarea> tag in combination with the cache and the include.  If instead of using %INCLUDE% to include this section in a page I place the search directly in the page and enclose it in <dirtyarea> tags, it works exactly as expected, whether or not caching is turned on.  If I turn off caching, the page also works as expected whether or not the <dirtyarea> tag is present.

I suspect this might ultimately be a bug in the DBCachePlugin, but I'm not yet certain where the problem lies.  Does this look familiar to anyone, and do you have any advice both for working around the problem and for reporting it officially?

Thanks!

Paul Merchant, Jr.
Senior Programmer/Analyst
Digital Library Technology Group
Dartmouth College



------------------------------------------------------------------------------
_______________________________________________
Foswiki-discuss mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/foswiki-discuss
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Foswiki Caching & %SEARCH% within %INCLUDE%

Lynnwood Brown
Hi Paul,
First of all, your questions does not appear to involve DBCachePlugin at all but rather the “Page Caching” feature that is part of Foswiki core (see http://foswiki.org/System/PageCaching). DBCachePlugin serves a different purpose altogether and is not involved in the general caching feature or the code you describe.

I would recommend posting this as a support question at http://foswiki.org/Support/WebHome. It may end up as a bug report but the page caching feature has a number of options to fine-tune how it works and someone may see a way around your difficulty. My first thought would be to play with the CACHEEXPIRE preference.

Cheers,
Lynnwood Brown

> On Nov 3, 2015, at 12:17 PM, Paul L. Merchant Jr. <[hidden email]> wrote:
>
> Hi everyone, I think I've run into a bug due to an interaction between the DBCachePlugin, %INCLUDE% and %SEARCH%, and it's not really clear on the Foswiki.org site how to report problems, so I'm throwing this at the mailing list in hopes that either someone knows a solution or is willing to point me at the proper place to report bugs.  (Is it the Foswiki Support page?)
>
> I have a search with a regular expression to match on a configurable topic prefix:
>
> %STARTSECTION{MyTopics}%
> %SEARCH{"^%NAME_PREFIX%\d{4}$" web="%BASEWEB%" scope="topic" type="regex" sort="topic" reverse="on" nonoise="on" format="$percntINCLUDE{\"$web.$topic\" headingoffset=\"2\"}$percnt" }%
> %ENDSECTION{MyTopics}%
>
>
> The section containing the search is included on various pages with different values given for %NAME_PREFIX%.  This works as I expect.  Of course, when I turn page caching on (using an SQLLite cache for testing), the search isn't updated if a new page is created that matches the search.  So I tried putting the search within a <dirtyarea> tag:
>
> %STARTSECTION{MyTopics}%
> <dirtyarea>
> %SEARCH{"^%NAME_PREFIX%\d{4}$" web="%BASEWEB%" scope="topic" type="regex" sort="topic" reverse="on" nonoise="on" format="$percntINCLUDE{\"$web.$topic\" headingoffset=\"2\"}$percnt" }%
> </dirtyarea>
> %ENDSECTION{MyTopics}%
>
> This breaks the search entirely.  It no longer matches anything.  Some experimenting suggests that the regular expression searching is broken by the <dirtyarea> tag in combination with the cache and the include.  If instead of using %INCLUDE% to include this section in a page I place the search directly in the page and enclose it in <dirtyarea> tags, it works exactly as expected, whether or not caching is turned on.  If I turn off caching, the page also works as expected whether or not the <dirtyarea> tag is present.
>
> I suspect this might ultimately be a bug in the DBCachePlugin, but I'm not yet certain where the problem lies.  Does this look familiar to anyone, and do you have any advice both for working around the problem and for reporting it officially?
>
> Thanks!
>
> Paul Merchant, Jr.
> Senior Programmer/Analyst
> Digital Library Technology Group
> Dartmouth College
>
>
>
> ------------------------------------------------------------------------------
> _______________________________________________
> Foswiki-discuss mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/foswiki-discuss


------------------------------------------------------------------------------
_______________________________________________
Foswiki-discuss mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/foswiki-discuss
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Foswiki Caching & %SEARCH% within %INCLUDE%

Chris Hoefler
In reply to this post by Paul L. Merchant Jr.
When you say "turn page caching on" do you mean the page caching under Tuning in /bin/configure? I would try to avoid that unless you have a very static site. As you noticed with the <dirtyarea>'s there is quite a bit of hackery needed to make it work with dynamic searches. Maybe try using %DBQUERY% instead? That is a %SEARCH% that is designed to work with DBCacheContrib, so the performance is quite good. Alternatively, you can try processing your %INCLUDE%s with RenderPlugin. This will make the rendering asynchronous, which will make the page views seem faster and more responsive...I'm guessing that is what you are trying to achieve with the page caching.


On Tue, Nov 3, 2015 at 11:17 AM, Paul L. Merchant Jr. <[hidden email]> wrote:
Hi everyone, I think I've run into a bug due to an interaction between the DBCachePlugin, %INCLUDE% and %SEARCH%, and it's not really clear on the Foswiki.org site how to report problems, so I'm throwing this at the mailing list in hopes that either someone knows a solution or is willing to point me at the proper place to report bugs.  (Is it the Foswiki Support page?)

I have a search with a regular expression to match on a configurable topic prefix:

%STARTSECTION{MyTopics}%
%SEARCH{"^%NAME_PREFIX%\d{4}$" web="%BASEWEB%" scope="topic" type="regex" sort="topic" reverse="on" nonoise="on" format="$percntINCLUDE{\"$web.$topic\" headingoffset=\"2\"}$percnt" }%
%ENDSECTION{MyTopics}%


The section containing the search is included on various pages with different values given for %NAME_PREFIX%.  This works as I expect.  Of course, when I turn page caching on (using an SQLLite cache for testing), the search isn't updated if a new page is created that matches the search.  So I tried putting the search within a <dirtyarea> tag:

%STARTSECTION{MyTopics}%
<dirtyarea>
%SEARCH{"^%NAME_PREFIX%\d{4}$" web="%BASEWEB%" scope="topic" type="regex" sort="topic" reverse="on" nonoise="on" format="$percntINCLUDE{\"$web.$topic\" headingoffset=\"2\"}$percnt" }%
</dirtyarea>
%ENDSECTION{MyTopics}%

This breaks the search entirely.  It no longer matches anything.  Some experimenting suggests that the regular expression searching is broken by the <dirtyarea> tag in combination with the cache and the include.  If instead of using %INCLUDE% to include this section in a page I place the search directly in the page and enclose it in <dirtyarea> tags, it works exactly as expected, whether or not caching is turned on.  If I turn off caching, the page also works as expected whether or not the <dirtyarea> tag is present.

I suspect this might ultimately be a bug in the DBCachePlugin, but I'm not yet certain where the problem lies.  Does this look familiar to anyone, and do you have any advice both for working around the problem and for reporting it officially?

Thanks!

Paul Merchant, Jr.
Senior Programmer/Analyst
Digital Library Technology Group
Dartmouth College



------------------------------------------------------------------------------
_______________________________________________
Foswiki-discuss mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/foswiki-discuss



------------------------------------------------------------------------------

_______________________________________________
Foswiki-discuss mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/foswiki-discuss
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Foswiki Caching & %SEARCH% within %INCLUDE%

Paul L. Merchant Jr.
Hi Chris, yes, I am referring to the Cache setting under tuning.  Aside from the complications of managing dependencies (and the consequences for dynamic elements), is there a good reason to avoid page caching?  I'm seeing a performance improvement of 85% using caching with Foswiki running under mod_fcgid on the simplest of pages so I'd need a strong case to give that up.

%DBQUERY% seems to solve my immediate problem, thanks!

— Paul

> On Nov 3, 2015, at 1:28 PM, Chris Hoefler <[hidden email]> wrote:
>
> When you say "turn page caching on" do you mean the page caching under Tuning in /bin/configure? I would try to avoid that unless you have a very static site. As you noticed with the <dirtyarea>'s there is quite a bit of hackery needed to make it work with dynamic searches. Maybe try using %DBQUERY% instead? That is a %SEARCH% that is designed to work with DBCacheContrib, so the performance is quite good. Alternatively, you can try processing your %INCLUDE%s with RenderPlugin. This will make the rendering asynchronous, which will make the page views seem faster and more responsive...I'm guessing that is what you are trying to achieve with the page caching.
>
>
> On Tue, Nov 3, 2015 at 11:17 AM, Paul L. Merchant Jr. <[hidden email]> wrote:
> Hi everyone, I think I've run into a bug due to an interaction between the DBCachePlugin, %INCLUDE% and %SEARCH%, and it's not really clear on the Foswiki.org site how to report problems, so I'm throwing this at the mailing list in hopes that either someone knows a solution or is willing to point me at the proper place to report bugs.  (Is it the Foswiki Support page?)
>
> I have a search with a regular expression to match on a configurable topic prefix:
>
> %STARTSECTION{MyTopics}%
> %SEARCH{"^%NAME_PREFIX%\d{4}$" web="%BASEWEB%" scope="topic" type="regex" sort="topic" reverse="on" nonoise="on" format="$percntINCLUDE{\"$web.$topic\" headingoffset=\"2\"}$percnt" }%
> %ENDSECTION{MyTopics}%
>
>
> The section containing the search is included on various pages with different values given for %NAME_PREFIX%.  This works as I expect.  Of course, when I turn page caching on (using an SQLLite cache for testing), the search isn't updated if a new page is created that matches the search.  So I tried putting the search within a <dirtyarea> tag:
>
> %STARTSECTION{MyTopics}%
> <dirtyarea>
> %SEARCH{"^%NAME_PREFIX%\d{4}$" web="%BASEWEB%" scope="topic" type="regex" sort="topic" reverse="on" nonoise="on" format="$percntINCLUDE{\"$web.$topic\" headingoffset=\"2\"}$percnt" }%
> </dirtyarea>
> %ENDSECTION{MyTopics}%
>
> This breaks the search entirely.  It no longer matches anything.  Some experimenting suggests that the regular expression searching is broken by the <dirtyarea> tag in combination with the cache and the include.  If instead of using %INCLUDE% to include this section in a page I place the search directly in the page and enclose it in <dirtyarea> tags, it works exactly as expected, whether or not caching is turned on.  If I turn off caching, the page also works as expected whether or not the <dirtyarea> tag is present.
>
> I suspect this might ultimately be a bug in the DBCachePlugin, but I'm not yet certain where the problem lies.  Does this look familiar to anyone, and do you have any advice both for working around the problem and for reporting it officially?
>
> Thanks!
>
> Paul Merchant, Jr.
> Senior Programmer/Analyst
> Digital Library Technology Group
> Dartmouth College
>
>
>
> ------------------------------------------------------------------------------
> _______________________________________________
> Foswiki-discuss mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/foswiki-discuss
>
>
> ------------------------------------------------------------------------------
> _______________________________________________
> Foswiki-discuss mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/foswiki-discuss

------------------------------------------------------------------------------
_______________________________________________
Foswiki-discuss mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/foswiki-discuss
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Foswiki Caching & %SEARCH% within %INCLUDE%

Chris Hoefler
Aside from the complications of managing dependencies (and the consequences for dynamic elements), is there a good reason to avoid page caching?

Well, those are the disadvantages. Page caching in Foswiki works by bypassing the TML->HTML rendering (which includes %MACRO% expansion), storing the pre-computed HTML as if it were a static page. If you have a largely static site (either static images and content, or dynamic content that does not change much), page caching is an effective way of improving performance. But if you have a fairly dynamic site, populated by %SEARCH%s, for example, page caching is a headache as you basically have to disable it for every use of a dynamic element, or constantly refresh the cache. If you have a dynamic site, a wikiapplication perhaps, there are other ways to achieve the performance gains you are looking for, asynchronous loading being one of the more popular options. Also, Foswiki page caching and DBCacheContrib are two completely different things, so you can use one without the other.

On Tue, Nov 3, 2015 at 1:51 PM, Paul L. Merchant Jr. <[hidden email]> wrote:
Hi Chris, yes, I am referring to the Cache setting under tuning.  Aside from the complications of managing dependencies (and the consequences for dynamic elements), is there a good reason to avoid page caching?  I'm seeing a performance improvement of 85% using caching with Foswiki running under mod_fcgid on the simplest of pages so I'd need a strong case to give that up.

%DBQUERY% seems to solve my immediate problem, thanks!

— Paul

> On Nov 3, 2015, at 1:28 PM, Chris Hoefler <[hidden email]> wrote:
>
> When you say "turn page caching on" do you mean the page caching under Tuning in /bin/configure? I would try to avoid that unless you have a very static site. As you noticed with the <dirtyarea>'s there is quite a bit of hackery needed to make it work with dynamic searches. Maybe try using %DBQUERY% instead? That is a %SEARCH% that is designed to work with DBCacheContrib, so the performance is quite good. Alternatively, you can try processing your %INCLUDE%s with RenderPlugin. This will make the rendering asynchronous, which will make the page views seem faster and more responsive...I'm guessing that is what you are trying to achieve with the page caching.
>
>
> On Tue, Nov 3, 2015 at 11:17 AM, Paul L. Merchant Jr. <[hidden email]> wrote:
> Hi everyone, I think I've run into a bug due to an interaction between the DBCachePlugin, %INCLUDE% and %SEARCH%, and it's not really clear on the Foswiki.org site how to report problems, so I'm throwing this at the mailing list in hopes that either someone knows a solution or is willing to point me at the proper place to report bugs.  (Is it the Foswiki Support page?)
>
> I have a search with a regular expression to match on a configurable topic prefix:
>
> %STARTSECTION{MyTopics}%
> %SEARCH{"^%NAME_PREFIX%\d{4}$" web="%BASEWEB%" scope="topic" type="regex" sort="topic" reverse="on" nonoise="on" format="$percntINCLUDE{\"$web.$topic\" headingoffset=\"2\"}$percnt" }%
> %ENDSECTION{MyTopics}%
>
>
> The section containing the search is included on various pages with different values given for %NAME_PREFIX%.  This works as I expect.  Of course, when I turn page caching on (using an SQLLite cache for testing), the search isn't updated if a new page is created that matches the search.  So I tried putting the search within a <dirtyarea> tag:
>
> %STARTSECTION{MyTopics}%
> <dirtyarea>
> %SEARCH{"^%NAME_PREFIX%\d{4}$" web="%BASEWEB%" scope="topic" type="regex" sort="topic" reverse="on" nonoise="on" format="$percntINCLUDE{\"$web.$topic\" headingoffset=\"2\"}$percnt" }%
> </dirtyarea>
> %ENDSECTION{MyTopics}%
>
> This breaks the search entirely.  It no longer matches anything.  Some experimenting suggests that the regular expression searching is broken by the <dirtyarea> tag in combination with the cache and the include.  If instead of using %INCLUDE% to include this section in a page I place the search directly in the page and enclose it in <dirtyarea> tags, it works exactly as expected, whether or not caching is turned on.  If I turn off caching, the page also works as expected whether or not the <dirtyarea> tag is present.
>
> I suspect this might ultimately be a bug in the DBCachePlugin, but I'm not yet certain where the problem lies.  Does this look familiar to anyone, and do you have any advice both for working around the problem and for reporting it officially?
>
> Thanks!
>
> Paul Merchant, Jr.
> Senior Programmer/Analyst
> Digital Library Technology Group
> Dartmouth College
>
>
>
> ------------------------------------------------------------------------------
> _______________________________________________
> Foswiki-discuss mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/foswiki-discuss
>
>
> ------------------------------------------------------------------------------
> _______________________________________________
> Foswiki-discuss mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/foswiki-discuss

------------------------------------------------------------------------------
_______________________________________________
Foswiki-discuss mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/foswiki-discuss



--
Chris Hoefler, PhD
Postdoctoral Research Associate
Straight Lab
Texas A&M University
2128 TAMU
College Station, TX 77843-2128

------------------------------------------------------------------------------

_______________________________________________
Foswiki-discuss mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/foswiki-discuss
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Foswiki Caching & %SEARCH% within %INCLUDE%

Paul L. Merchant Jr.
In reply to this post by Lynnwood Brown
I honestly don't know why I was thinking about DBCachePlugin at the time I wrote this, but thank you for clearing this up.  I'll create a complete dysfunctional example and drop it on the support page.

Thanks!

— Paul


> On Nov 3, 2015, at 1:21 PM, Lynnwood Brown <[hidden email]> wrote:
>
> Hi Paul,
> First of all, your questions does not appear to involve DBCachePlugin at all but rather the “Page Caching” feature that is part of Foswiki core (see http://foswiki.org/System/PageCaching). DBCachePlugin serves a different purpose altogether and is not involved in the general caching feature or the code you describe.
>
> I would recommend posting this as a support question at http://foswiki.org/Support/WebHome. It may end up as a bug report but the page caching feature has a number of options to fine-tune how it works and someone may see a way around your difficulty. My first thought would be to play with the CACHEEXPIRE preference.
>
> Cheers,
> Lynnwood Brown
>
>> On Nov 3, 2015, at 12:17 PM, Paul L. Merchant Jr. <[hidden email]> wrote:
>>
>> Hi everyone, I think I've run into a bug due to an interaction between the DBCachePlugin, %INCLUDE% and %SEARCH%, and it's not really clear on the Foswiki.org site how to report problems, so I'm throwing this at the mailing list in hopes that either someone knows a solution or is willing to point me at the proper place to report bugs.  (Is it the Foswiki Support page?)
>>
>> I have a search with a regular expression to match on a configurable topic prefix:
>>
>> %STARTSECTION{MyTopics}%
>> %SEARCH{"^%NAME_PREFIX%\d{4}$" web="%BASEWEB%" scope="topic" type="regex" sort="topic" reverse="on" nonoise="on" format="$percntINCLUDE{\"$web.$topic\" headingoffset=\"2\"}$percnt" }%
>> %ENDSECTION{MyTopics}%
>>
>>
>> The section containing the search is included on various pages with different values given for %NAME_PREFIX%.  This works as I expect.  Of course, when I turn page caching on (using an SQLLite cache for testing), the search isn't updated if a new page is created that matches the search.  So I tried putting the search within a <dirtyarea> tag:
>>
>> %STARTSECTION{MyTopics}%
>> <dirtyarea>
>> %SEARCH{"^%NAME_PREFIX%\d{4}$" web="%BASEWEB%" scope="topic" type="regex" sort="topic" reverse="on" nonoise="on" format="$percntINCLUDE{\"$web.$topic\" headingoffset=\"2\"}$percnt" }%
>> </dirtyarea>
>> %ENDSECTION{MyTopics}%
>>
>> This breaks the search entirely.  It no longer matches anything.  Some experimenting suggests that the regular expression searching is broken by the <dirtyarea> tag in combination with the cache and the include.  If instead of using %INCLUDE% to include this section in a page I place the search directly in the page and enclose it in <dirtyarea> tags, it works exactly as expected, whether or not caching is turned on.  If I turn off caching, the page also works as expected whether or not the <dirtyarea> tag is present.
>>
>> I suspect this might ultimately be a bug in the DBCachePlugin, but I'm not yet certain where the problem lies.  Does this look familiar to anyone, and do you have any advice both for working around the problem and for reporting it officially?
>>
>> Thanks!
>>
>> Paul Merchant, Jr.
>> Senior Programmer/Analyst
>> Digital Library Technology Group
>> Dartmouth College
>>
>>
>>
>> ------------------------------------------------------------------------------
>> _______________________________________________
>> Foswiki-discuss mailing list
>> [hidden email]
>> https://lists.sourceforge.net/lists/listinfo/foswiki-discuss
>
>
> ------------------------------------------------------------------------------
> _______________________________________________
> Foswiki-discuss mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/foswiki-discuss

------------------------------------------------------------------------------
_______________________________________________
Foswiki-discuss mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/foswiki-discuss
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Foswiki Caching & %SEARCH% within %INCLUDE%

George Clark-2
Note that foswiki.org is running with the PageCache enabled.  It's
disabled globally, and enabled per topic.  On http://trunk.foswik.org
it's enabled globally,  so you might be able to create a functional
example on trunk.foswiki.org.

Regarding your other questions
 - You can report bugs at http://foswiki.org/Tasks/PageCache
 - Support requests can be made at
http://foswiki.org/Support/SupportQuestions

The PageCache was completely rewritten for Foswiki 2.0, and should be
much more reliable than the Foswiki 1.x cache.

George

On 11/04/2015 01:17 PM, Paul L. Merchant Jr. wrote:

> I honestly don't know why I was thinking about DBCachePlugin at the time I wrote this, but thank you for clearing this up.  I'll create a complete dysfunctional example and drop it on the support page.
>
> Thanks!
>
> — Paul
>
>
>> On Nov 3, 2015, at 1:21 PM, Lynnwood Brown <[hidden email]> wrote:
>>
>> Hi Paul,
>> First of all, your questions does not appear to involve DBCachePlugin at all but rather the “Page Caching” feature that is part of Foswiki core (see http://foswiki.org/System/PageCaching). DBCachePlugin serves a different purpose altogether and is not involved in the general caching feature or the code you describe.
>>
>> I would recommend posting this as a support question at http://foswiki.org/Support/WebHome. It may end up as a bug report but the page caching feature has a number of options to fine-tune how it works and someone may see a way around your difficulty. My first thought would be to play with the CACHEEXPIRE preference.
>>
>> Cheers,
>> Lynnwood Brown
>>
>>> On Nov 3, 2015, at 12:17 PM, Paul L. Merchant Jr. <[hidden email]> wrote:
>>>
>>> Hi everyone, I think I've run into a bug due to an interaction between the DBCachePlugin, %INCLUDE% and %SEARCH%, and it's not really clear on the Foswiki.org site how to report problems, so I'm throwing this at the mailing list in hopes that either someone knows a solution or is willing to point me at the proper place to report bugs.  (Is it the Foswiki Support page?)
>>>
>>> I have a search with a regular expression to match on a configurable topic prefix:
>>>
>>> %STARTSECTION{MyTopics}%
>>> %SEARCH{"^%NAME_PREFIX%\d{4}$" web="%BASEWEB%" scope="topic" type="regex" sort="topic" reverse="on" nonoise="on" format="$percntINCLUDE{\"$web.$topic\" headingoffset=\"2\"}$percnt" }%
>>> %ENDSECTION{MyTopics}%
>>>
>>>
>>> The section containing the search is included on various pages with different values given for %NAME_PREFIX%.  This works as I expect.  Of course, when I turn page caching on (using an SQLLite cache for testing), the search isn't updated if a new page is created that matches the search.  So I tried putting the search within a <dirtyarea> tag:
>>>
>>> %STARTSECTION{MyTopics}%
>>> <dirtyarea>
>>> %SEARCH{"^%NAME_PREFIX%\d{4}$" web="%BASEWEB%" scope="topic" type="regex" sort="topic" reverse="on" nonoise="on" format="$percntINCLUDE{\"$web.$topic\" headingoffset=\"2\"}$percnt" }%
>>> </dirtyarea>
>>> %ENDSECTION{MyTopics}%
>>>
>>> This breaks the search entirely.  It no longer matches anything.  Some experimenting suggests that the regular expression searching is broken by the <dirtyarea> tag in combination with the cache and the include.  If instead of using %INCLUDE% to include this section in a page I place the search directly in the page and enclose it in <dirtyarea> tags, it works exactly as expected, whether or not caching is turned on.  If I turn off caching, the page also works as expected whether or not the <dirtyarea> tag is present.
>>>
>>> I suspect this might ultimately be a bug in the DBCachePlugin, but I'm not yet certain where the problem lies.  Does this look familiar to anyone, and do you have any advice both for working around the problem and for reporting it officially?
>>>
>>> Thanks!
>>>
>>> Paul Merchant, Jr.
>>> Senior Programmer/Analyst
>>> Digital Library Technology Group
>>> Dartmouth College
>>>
>>>
>>>
>>> ------------------------------------------------------------------------------
>>> _______________________________________________
>>> Foswiki-discuss mailing list
>>> [hidden email]
>>> https://lists.sourceforge.net/lists/listinfo/foswiki-discuss
>>
>> ------------------------------------------------------------------------------
>> _______________________________________________
>> Foswiki-discuss mailing list
>> [hidden email]
>> https://lists.sourceforge.net/lists/listinfo/foswiki-discuss
> ------------------------------------------------------------------------------
> _______________________________________________
> Foswiki-discuss mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/foswiki-discuss



------------------------------------------------------------------------------
_______________________________________________
Foswiki-discuss mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/foswiki-discuss
Loading...