Item8096: DBCachePlugin's copy of TWiki:DBCacheContrib calls Foswiki:DBCacheContrib storage modules

pencil
Priority: Normal
Current State: Closed
Released In:
Target Release:
Applies To: Extension
Component: DBCacheContrib, DBCachePlugin
Branches:
Reported By: Foswiki:Main.DamionAlexander
Waiting For:
Last Change By: MichaelDaum
In a fresh install of Foswiki 1.0.4 and the latest DBCachePlugin, the following error will be the only output received when trying to visit any page:

Can't locate object method "store" via package "Foswiki::Contrib::DBCacheContrib::Archivist::BDB" at /www/foswiki/lib/TWiki/Contrib/DBCacheContrib.pm line 336

I found that DBCachePlugin's copy of DBCacheContrib ends up calling the Foswiki::DBCacheContrib whenever it tries to access the storage module. It's because lib/TWiki.pm (I'm assuming) defines *TWiki::cfg = \\%Foswiki::cfg; and DBCacheContrib calls the store function via $TWiki::cfg{DBCacheContrib}{Archivist}....

I worked around this by adding the following after the 'use' statements in lib/TWiki/Contrib/DBCacheContrib.pm:

$TWiki::cfg{DBCacheContrib}{Archivist}='TWiki::Contrib::DBCacheContrib::Archivist::Storable';

Based on the comments in http://foswiki.org/Tasks/Item1346 it appears that this started in 1.0.4. This was my first install of Foswiki so I'm not sure if it was present before.

-- DamionAlexander - 03 Apr 2009

I can confirm, that the suggested workaround works. In my eyes this bug is therefore more related to DBCacheContrib, which caused me to change this in the "Affected Component" formfield below.

To everybody who encountered this bug:
Please also have a look at Item1612, which seems as well be related to

lib/Foswiki/Contrib/DBCacheContrib/Archivist/Storable.pm

Is this related?

-- PhilippLeufke - 13 May 2009

I can imagine that there are problems installing the current DBCachePlugin - which is still in tmwiki namespace and comes with an old internalized DBCacheContrib - with an up-to-date DBCacheContrib. The new DBCacheContrib comes with much advanced storage mechanisms. Alas, the port of DBCachePlugin has not been straight forward. It is one of the plugins that went to the end of my detwikification crusade as it is one of the harder jobs. Once done, this bug reported here will be solved as well. Setting this to waiting for me so that I don't forget to docu upgrades to this bug.

-- MichaelDaum - 13 May 2009

DBCachePlugin has been detwikified finally. So I assume this problem as solved.

-- MichaelDaum - 29 Jun 2009

ItemTemplate edit

Summary DBCachePlugin's copy of TWiki:DBCacheContrib calls Foswiki:DBCacheContrib storage modules
ReportedBy Foswiki:Main.DamionAlexander
Codebase 1.0.4
SVN Range Foswiki-1.0.0, Thu, 08 Jan 2009, build 1878
AppliesTo Extension
Component DBCacheContrib, DBCachePlugin
Priority Normal
CurrentState Closed
WaitingFor
Checkins DBCachePlugin:4ba094f0d783
ReleasedIn
Topic revision: r4 - 29 Jun 2009, MichaelDaum
The copyright of the content on this website is held by the contributing authors, except where stated elsewhere. See Copyright Statement. Creative Commons License    Legal Imprint    Privacy Policy