cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Lionel Barth <lba...@hachette-livre.fr>
Subject Re: [SOLVED] Cron job dies - process incomplete pipeline
Date Tue, 23 Jan 2007 14:37:04 GMT
Hi,

I have been able to suppress the error message using :
function alerteOTLB() {
  requete=newCatal().alerteOT();
  cocoon.log.warn("alerteOTLB");
  cocoon.sendStatus(204);
  cocoon.redirectTo("crfab/nothing.html");
}

this way I have the following info in the cron.log file :
INFO    (2007-01-23) 15:15.00:015   [cron] 
Unknown-thread/QuartzJobExecutor: Executing cron job named 'alerteOT'
INFO    (2007-01-23) 15:15.00:430   [cron.pipeline] 
Unknown-thread/CocoonPipelineCronJob: CocoonPipelineCronJob: alerteOT, 
called pipeline: crfab/alerteOTLB.html, and received following content:
<html><head/></html>

Best regards,
Lionel

Lionel Barth a ecrit le 23/01/07 13:36:
> Jasha,
>
> It comes in the flow function, I add a message in the flow log file 
> with cocoon.log.warn("alerteOT") and the message is really in the log 
> file :
> WARN    (2007-01-23) 13:30.00:520   [flow] (Unknown-URI) 
> Unknown-thread/NativeJavaMethod: alerteOT
> WARN    (2007-01-23) 13:35.00:477   [flow] (Unknown-URI) 
> Unknown-thread/NativeJavaMethod: alerteOT
>
> Lionel
>
> Jasha Joachimsthal a ecrit le 23/01/07 13:16:
>> Hi Lionel,
>>
>> Does it come into the flow function if the cron job is executed (you can
>> test it with a print statement in flow)?
>> Maybe it matches in another sitemap than you'd expect. E.g. if the
>> expected pipeline is in a sitemap that depends on the domain you use and
>> the cron uses localhost as domain.
>>
>> Jasha
>>  
>>> -----Original Message-----
>>> From: Lionel Barth [mailto:lbarth@hachette-livre.fr] Sent: dinsdag 
>>> 23 januari 2007 11:47
>>> To: users@cocoon.apache.org
>>> Subject: Re: Cron job dies - process incomplete pipeline
>>>
>>> Jasha,
>>>
>>> Yes it works. In fact everything works, but I have an error message 
>>> in the log file.
>>>
>>> Lionel
>>>
>>> Jasha Joachimsthal a ecrit le 23/01/07 11:36:
>>>    
>>>> Hi Lionel,
>>>>
>>>> What happens if you call the URI directly from your       
>>> browser? Does it    
>>>> function then?
>>>>
>>>> Regards,
>>>>
>>>> Jasha Joachimsthal
>>>>
>>>> Hippo
>>>> Oosteinde 11
>>>> 1017 WT Amsterdam
>>>> The Netherlands
>>>> +31 (0)20 5224466
>>>>
>>>> www.hippo.nl
>>>>
>>>>        
>>>>> -----Original Message-----
>>>>> From: Lionel Barth [mailto:lbarth@hachette-livre.fr]
>>>>> Sent: dinsdag 23 januari 2007 11:04
>>>>> To: users@cocoon.apache.org
>>>>> Subject: Cron job dies - process incomplete pipeline
>>>>>
>>>>> Hello,
>>>>>
>>>>> I am trying to use the cron component to perform some checks on a 
>>>>> database and send emails if needed.
>>>>>
>>>>> The cron job works, makes the checks, send the emails as         
>>> needed but I    
>>>>> have an error in the cron log file :
>>>>> INFO    (2007-01-23) 10:55.00:019   [cron] 
>>>>> Unknown-thread/QuartzJobExecutor: Executing cron job named         
>>> 'alerteOT'
>>>    
>>>>> ERROR   (2007-01-23) 10:55.06:396   [cron] 
>>>>> Unknown-thread/QuartzJobExecutor: Cron job name 'alerteOT' died.
>>>>> org.apache.avalon.framework.CascadingRuntimeException: 
>>>>> CocoonPipelineCronJob: alerteOT, raised an exception:
>>>>> ..
>>>>> Caused by: org.apache.excalibur.source.SourceException: Exception 
>>>>> during processing of cocoon://crfab/alerteOTLB.html
>>>>>         ... 10 more
>>>>> Caused by: org.apache.cocoon.ProcessingException: Attempted to 
>>>>> process incomplete pipeline.
>>>>>
>>>>> In the cocoon.xconf I declare a trigger :
>>>>>         <trigger name="alerteOT"
>>>>>                  
>>>>> target="org.apache.cocoon.components.cron.CronJob/alerteOT"
>>>>>                  concurrent-runs="true">
>>>>>           <minutes>*/5</minutes>
>>>>>           <hours>9-18</hours>
>>>>>           <days>?</days>
>>>>>           <months>*</months>
>>>>>           <weekdays>MON-FRI</weekdays>
>>>>>         </trigger>
>>>>>
>>>>> and a component :
>>>>>   <component         
>>> role="org.apache.cocoon.components.cron.CronJob/alerteOT"
>>>    
>>>>>              
>>>>> class="org.apache.cocoon.components.cron.CocoonPipelineCronJob"
>>>>>              logger="cron.pipeline">
>>>>>       <pipeline>crfab/alerteOTLB.html</pipeline>
>>>>>   </component>
>>>>>
>>>>> In the sitemap :
>>>>>           <map:match pattern="alerteOTLB.html">
>>>>>                <map:call function="alerteOTLB"/>
>>>>>           </map:match>
>>>>>
>>>>> In the flowscript :
>>>>>     function alerteOTLB() {
>>>>>       requete=newCatal().alerteOT();
>>>>>       cocoon.sendStatus(204);
>>>>>     //  FOM_Cocoon.suicide();
>>>>>     }
>>>>>
>>>>> How should I close the pipeline ?
>>>>>
>>>>> Thanks,
>>>>> Lionel Barth
>>>>>
>>>>>
>>>>>
>>>>>         
>>> ---------------------------------------------------------------------
>>>    
>>>>> To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
>>>>> For additional commands, e-mail: users-help@cocoon.apache.org
>>>>>
>>>>>
>>>>>             
>>>>       
>>> ---------------------------------------------------------------------
>>>    
>>>> To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
>>>> For additional commands, e-mail: users-help@cocoon.apache.org
>>>>
>>>>         
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
>>> For additional commands, e-mail: users-help@cocoon.apache.org
>>>
>>>
>>>     
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
>> For additional commands, e-mail: users-help@cocoon.apache.org
>>
>>   
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
> For additional commands, e-mail: users-help@cocoon.apache.org
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


Mime
View raw message