plainblack.com
Username Password
search
Bookmark and Share

    
Goto page «Previous Page   1 2    Next Page»

Database Cache gives an error

User bartjol
Date 12/22/2008 10:07 am
Views 13790
Rating 1    Rate [
|
]
Previous · Next
User Message
bartjol

We have an shared WebGUI 7.5.36 stable instance on wre 0.8.5.

In all webgui confs the cacheType is set to Database

Now in modperl we get the error:

DBD::mysql::st execute failed: Column 'cachekey' cannot be null at /data/WebGUI/lib/WebGUI/Cache/Database.pm line 184.

this refers to the next sub method:

=head2 set ( content [, ttl ] )

Save content to the filesystem cache.

=head3 content

A scalar variable containing the content to be set.

=head3 ttl

The time to live for this content. This is the amount of time (in seconds) that the content will remain in the cache. Defaults to "60".

=cut

sub set {
        my $self = shift;
        # Storable doesn't like non-reference arguments, so we wrap it in a scalar ref.
        my $content = freeze(\(scalar shift));
        my $ttl = shift || 60;
        my $size = length($content);
        # getting better performance using native dbi than webgui sql
        my $dbh = $self->session->db->dbh;
        my $sth = $dbh->prepare("replace into cache (namespace,cachekey,expires,size,content) values (?,?,?,?,?)");
        $sth->execute($self->{_namespace}, $self->{_key}, time()+$ttl, $size, $content);
        $sth->finish;

Where the bold line is line 184

Also a lot of workflows are stacked up, mostly completed, but are not removed from the list in the workflow overview. Whether these are related is unclear.

webgui.log is empty

Here are a few fields cachekey from the cache table:

| wE401EXjGiFZwb-riCuiEg/zZHDzxSlyk2+k6cbyeaMIg/5BvM3EVCud-1zoxAm0Hawg |
| wE401EXjGiFZwb-riCuiEg/ZZmPcyHEMaVmCvo6i+kN2w/dAJYJkkRCdK+TCmxI5PTlg |
| WG78+OY-q44HDtVDDexG4A                                               |
| wgrU12-pd1mqJ6DJm-9nEA                                               |
| wiTCYbpbyRHy7qV1MKAn-Q

I see that not all fields have the same composition, but whether this causes trouble is unclear. Does anyone see in what direction I should search?

--- (Edited on 22-December-2008 17:07 [GMT+0100] by bartjol) ---



Back to Top
Rate [
|
]
 
 
bartjol

In the meanwhile, I set one of the sites to FileCaching. I'll post the result, but it can take a while before the workflows of that site are processed.

Running them manually seemed to give the same result (a workflow in the overview with title: "No title")

This should give some information on whether and if, how the two phenomena are related.

Oh and it doesn't seem to be reproducable on my 7.6.7 single-site test environment

--- (Edited on 24-December-2008 10:40 [GMT+0100] by bartjol) ---



Back to Top
Rate [
|
]
 
 
bartjol

The change to FileCache doesn't seem to have any influence. The amount of running workflows (with status complete) has increased.

--- (Edited on 29-December-2008 15:05 [GMT+0100] by bartjol) ---



Back to Top
Rate [
|
]
 
 
bartjol

after setting the log level to debug, I got two types of entries with cachekey:

2008/12/30 16:47:16 - DEBUG - www.mydomain.nl.conf - WebGUI::Cache::Database::delete[52] - query 92:
  delete from cache where namespace=? and cachekey=?
  with placeholders:  ["www.mydomain.nl.conf","t8ol8kXijrhRwiCOam0Llg"]

and

2008/12/30 16:47:16 - DEBUG - www.mydomain.nl.conf - WebGUI::Cache::Database::deleteChunk[70] - query 97:
  delete from cache where namespace=? and cachekey like ?
  with placeholders:  ["www.mydomain.nl.conf","wE401EXjGiFZwb-riCuiEg/EGuokyvgsIfhOVxmqxilXw%"]

Both entries appear more often than once

--- (Edited on 30-December-2008 17:05 [GMT+0100] by bartjol) ---



Back to Top
Rate [
|
]
 
 
bartjol

We also have a lot of these

 

2009/01/06 00:00:18 - WARN - www.mydomai.nl.conf - WebGUI::Operation::Cron::www_runCronJob[295] - Could not create workflow instance for workflowId 'pbworkflow000000000007': It is a singleton workflow and is still running from the last invocation.

this is the workflow for sending queud email messages. Maybe there's something wrong with our e-mail settings. I'll dive into that. I don't see the advantage of setting the mode of this workflow to something else than singleton

 

--- (Edited on 6-January-2009 10:02 [GMT+0100] by bartjol) ---



Back to Top
Rate [
|
]
 
 
bartjol

oh, there seems to be a set of queries:

2009/01/06 09:44:14 - DEBUG - www.mydomain.com.conf - WebGUI::Session::Var::new[180] - query 1:
  select * from userSession where sessionId=?
  with placeholders:  ["CTQngnPxirnOgoLMgZ3-IA"]
2009/01/06 09:44:14 - DEBUG - www.mydomain.com.conf - WebGUI::Session::Setting::new[118] - query 2:
  select * from settings
2009/01/06 09:44:14 - DEBUG - www.mydomain.com.conf - WebGUI::Session::Var::new[196] - query 3:
  update userSession set adminOn=?, userId=?, lastIP=?, lastPageView=?, expires=? where sessionId=?
  with placeholders:  ["0","1","87.253.131.238",1231231454,1231235054,"CTQngnPxirnOgoLMgZ3-IA"]
2009/01/06 09:44:14 - DEBUG - www.mydomain.com.conf - WebGUI::Workflow::Instance::new[287] - query 4:
  select * from WorkflowInstance where instanceId=?
  with placeholders:  ["qjHOGGdOUU56GNmJAYaPDQ"]
2009/01/06 09:44:14 - DEBUG - www.mydomain.com.conf - WebGUI::Workflow::new[419] - query 5:
  select * from Workflow where workflowId=?
  with placeholders:  ["pbworkflow000000000007"]
2009/01/06 09:44:14 - DEBUG - www.mydomain.com.conf - WebGUI::Workflow::getNextActivity[336] - query 6:
  select sequenceNumber from WorkflowActivity where activityId=?
  with placeholders:  ["pbwfactivity0000000021"]
2009/01/06 09:44:14 - DEBUG - www.mydomain.com.conf - WebGUI::Workflow::getNextActivity[338] - query 7:
  select activityId from WorkflowActivity where workflowId=?
                and sequenceNumber>=? order by sequenceNumber
  with placeholders:  ["pbworkflow000000000007","2"]
2009/01/06 09:44:14 - DEBUG - www.mydomain.com.conf - WebGUI::Workflow::Activity::new[284] - query 8:
  select * from WorkflowActivity where activityId=?
  with placeholders:  [null]
2009/01/06 09:44:14 - DEBUG - www.mydomain.com.conf - WebGUI::Workflow::Instance::delete[105] - query 9:
  delete from WorkflowInstanceScratch where instanceId=?
  with placeholders:  ["qjHOGGdOUU56GNmJAYaPDQ"]
2009/01/06 09:44:14 - DEBUG - www.mydomain.com.conf - WebGUI::Workflow::Instance::delete[106] - query 10:
  delete from WorkflowInstance where instanceId=?
  with placeholders:  ["qjHOGGdOUU56GNmJAYaPDQ"]

--- (Edited on 6-January-2009 11:27 [GMT+0100] by bartjol) ---



Back to Top
Rate [
|
]
 
 
bartjol

Same sort set of queries for the get syndiicated content workflow:

2009/01/06 09:44:32 - DEBUG - www.mydomain.nl.conf - WebGUI::Session::Var::new[180] - query 1:
  select * from userSession where sessionId=?
  with placeholders:  ["xC2Ludn-O5rVPM6MlzMhfw"]
2009/01/06 09:44:32 - DEBUG - www.mydomain.nl.conf - WebGUI::Session::Setting::new[118] - query 2:
  select * from settings
2009/01/06 09:44:32 - DEBUG - www.mydomain.nl.conf - WebGUI::Session::Var::new[196] - query 3:
  update userSession set adminOn=?, userId=?, lastIP=?, lastPageView=?, expires=? where sessionId=?
  with placeholders:  ["0","1","87.253.131.238",1231231472,1231235072,"xC2Ludn-O5rVPM6MlzMhfw"]
2009/01/06 09:44:32 - DEBUG - www.mydomain.nl.conf - WebGUI::Workflow::Instance::new[287] - query 4:
  select * from WorkflowInstance where instanceId=?
  with placeholders:  ["ViGvxAlv67RtV9lVayj18w"]
2009/01/06 09:44:32 - DEBUG - www.mydomain.nl.conf - WebGUI::Workflow::new[419] - query 5:
  select * from Workflow where workflowId=?
  with placeholders:  ["pbworkflow000000000004"]
2009/01/06 09:44:32 - DEBUG - www.mydomain.nl.conf - WebGUI::Workflow::getNextActivity[336] - query 6:
  select sequenceNumber from WorkflowActivity where activityId=?
  with placeholders:  ["pbwfactivity0000000009"]
2009/01/06 09:44:32 - DEBUG - www.mydomain.nl.conf - WebGUI::Workflow::getNextActivity[338] - query 7:
  select activityId from WorkflowActivity where workflowId=?
                and sequenceNumber>=? order by sequenceNumber
  with placeholders:  ["pbworkflow000000000004","2"]
2009/01/06 09:44:32 - DEBUG - www.mydomain.nl.conf - WebGUI::Workflow::Activity::new[284] - query 8:
  select * from WorkflowActivity where activityId=?
  with placeholders:  ["pbwfactivity0000000012"]
2009/01/06 09:44:32 - DEBUG - www.mydomain.nl.conf - WebGUI::Workflow::Activity::new[292] - query 9:
  select name,value from WorkflowActivityData where activityId=?
  with placeholders:  ["pbwfactivity0000000012"]
2009/01/06 09:44:32 - INFO - www.mydomain.nl.conf - WebGUI::Workflow::Instance::run[340] - Running workflow activity pbwfactivity0000000012, which is a WebGUI::Workflow::Activity::GetSyndicatedContent, for instance ViGvxAlv67RtV9lVayj18w.
2009/01/06 09:44:32 - DEBUG - www.mydomain.nl.conf - WebGUI::Workflow::Instance::getScratch[238] - query 10:
  select name,value from WorkflowInstanceScratch where instanceId=?
  with placeholders:  ["ViGvxAlv67RtV9lVayj18w"]
2009/01/06 09:44:32 - DEBUG - www.mydomain.nl.conf - WebGUI::Asset::new[1656] - query 11:
  select className from asset where assetId=?
  with placeholders:  ["PBasset000000000000001"]
2009/01/06 09:44:32 - DEBUG - www.mydomain.nl.conf - WebGUI::Session::Scratch::new[179] - query 12:
  select name,value from userSessionScratch where sessionId=?
  with placeholders:  ["xC2Ludn-O5rVPM6MlzMhfw"]
2009/01/06 09:44:32 - DEBUG - www.mydomain.nl.conf - WebGUI::Asset::getCurrentRevisionDate[229] - query 13:
  select max(revisionDate) from assetData where assetId=? and
                        (status='approved' or status='archived' or tagId=?) order by assetData.revisionDate
  with placeholders:  ["PBasset000000000000001",null]
2009/01/06 09:44:32 - DEBUG - www.mydomain.nl.conf - WebGUI::Asset::getLineage[472] - query 14:
  select asset.assetId, asset.className, asset.parentId, assetData.revisionDate from asset left join assetData on asset.assetId=assetData.assetId  where asset.state='published' and (assetData.status='approved' or assetData.tagId=NULL) and (asset.className in ('WebGUI::Asset::Wobject::SyndicatedContent')) and ((asset.lineage like '000001%' and asset.lineage<>'000001')) and assetData.revisionDate=(SELECT max(revisionDate) from assetData where assetData.assetId=asset.assetId and (assetData.status='approved' or assetData.tagId=NULL))  group by assetData.assetId order by asset.lineage asc
2009/01/06 09:44:32 - DEBUG - www.mydomain.nl.conf - WebGUI::Workflow::Instance::setScratch[487] - query 15:
  replace into WorkflowInstanceScratch (instanceId, name, value) values (?,?,?)
  with placeholders:  ["ViGvxAlv67RtV9lVayj18w","syndicatedUrls","[]"]
2009/01/06 09:44:32 - DEBUG - www.mydomain.nl.conf - WebGUI::Workflow::Instance::deleteScratch[127] - query 16:
  delete from WorkflowInstanceScratch where instanceId=? and name=?
  with placeholders:  ["ViGvxAlv67RtV9lVayj18w","syndicatedUrls"]
2009/01/06 09:44:32 - DEBUG - www.mydomain.nl.conf - WebGUI::Workflow::Instance::set[458] - query 17:
  update WorkflowInstance set priority=?, workflowId=?, runningSince=?, className=?, parameters=?, lastStatus=?, methodName=?, lastUpdate=?, currentActivityId=? where instanceId=?
  with placeholders:  ["3","pbworkflow000000000004","1231230435",null,"{\"parameters\":{}}","complete",null,1231231472,"pbwfactivity0000000012","ViGvxAlv67RtV9lVayj18w"]

--- (Edited on 6-January-2009 11:32 [GMT+0100] by bartjol) ---



Back to Top
Rate [
|
]
 
 
bartjol

I also have such a query list with the cachekey mentioned, but that's 112 queries long, so posting it here might not be a good plan. If someone wants to have a look, ask me for the file

--- (Edited on 6-January-2009 12:03 [GMT+0100] by bartjol) ---



Back to Top
Rate [
|
]
 
 
bartjol

By the way: I have the feeling that I'm getting away from the first error message (or at least, not getting closer). Whether these problems are related is getting more uncertain with every post I make. I just try to give more information, which gives me some more understanding

After talking with doug on irc, I looked at the spectre settings and decreased the time beween workflows, now I'm waiting to see whether that help

--- (Edited on 6-January-2009 14:27 [GMT+0100] by bartjol) ---



Back to Top
Rate [
|
]
 
 
bartjol

I'm very sorry. The increasing amount of workflows has nothing to do with the cachekey error. It was due to a badly configured spectre.conf.

But the other error does remain. I only gave too much information, so it has become confusing

--- (Edited on 7-January-2009 09:48 [GMT+0100] by bartjol) ---



Back to Top
Rate [
|
]
 
 
     Goto page «Previous Page   1 2    Next Page»



© 2019 Plain Black Corporation | All Rights Reserved