Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0024780Openbravo ERP01. General setuppublic2013-09-16 13:422013-09-17 19:03
adrianromero 
shankarb 
urgentmajorhave not tried
closedfixed 
5
 
3.0MP28 
shankarb
Core
Production - Confirmed Stable
2009-02-02
https://code.openbravo.com/erp/devel/pi/rev/353de8982dab [^]
No
0024780: Process type PL/SQL Procedure cannot be executed as scheduled
A process defined as a PL/SQL Procedure and scheduled throws the following exception when the scheduler tries to execute the process:


674357 [DefaultQuartzScheduler_Worker-9] ERROR org.openbravo.scheduling.DefaultJob - Error executing process org.openbravo.scheduling.ProcessBundle@1cdce2d
java.lang.InstantiationException
    at sun.reflect.InstantiationExceptionConstructorAccessorImpl.newInstance(InstantiationExceptionConstructorAccessorImpl.java:30)
    at java.lang.reflect.Constructor.newInstance(Constructor.java:513)
    at java.lang.Class.newInstance0(Class.java:355)
    at java.lang.Class.newInstance(Class.java:308)
    at org.openbravo.scheduling.DefaultJob.execute(DefaultJob.java:47)
    at org.quartz.core.JobRunShell.run(JobRunShell.java:202)
    at org.quartz.simpl.SimpleThreadPool$WorkerThread.run(SimpleThreadPool.java:525)
* Create a sample PL/SQL Procedure and register it in the window 'Report and Proceses'. Mark it as 'background process' (http://wiki.openbravo.com/wiki/Processes [^])
* Go to the window 'Process request' and create a new request that executes the previous process inmediatelly
* Schedule the process
* Verify that the process has not been executed and that in the openbravo.log is logged the exception described in the previous field
It seems that the problem is because the scheduler tries to instantiate the abstract class org.openbravo.erpCommon.ad_process.ProcedureProcess. The solution is replace the code and instantiate instead the class org.openbravo.erpCommon.ad_process.PinstanceProcedure

The attached patch fixes this issue
Regression
patch scheduleprocess.patch (949) 2013-09-16 13:42
https://issues.openbravo.com/file_download.php?file_id=6412&type=bug
Issue History
2013-09-16 13:42adrianromeroNew Issue
2013-09-16 13:42adrianromeroAssigned To => dmiguelez
2013-09-16 13:42adrianromeroFile Added: scheduleprocess.patch
2013-09-16 13:42adrianromeroModules => Core
2013-09-16 13:42adrianromeroTriggers an Emergency Pack => No
2013-09-16 13:42adrianromeroTag Attached: Regression
2013-09-16 15:56adrianromeroReview Assigned To => shankarb
2013-09-17 08:27shankarbRegression level => Production - Confirmed Stable
2013-09-17 08:27shankarbRegression date => 2009-02-02
2013-09-17 08:27shankarbRegression introduced by commit => https://code.openbravo.com/erp/devel/pi/rev/353de8982dab [^]
2013-09-17 08:27shankarbReview Assigned Toshankarb => AugustoMauch
2013-09-17 08:27shankarbAssigned Todmiguelez => shankarb
2013-09-17 08:32shankarbReview Assigned ToAugustoMauch => shankarb
2013-09-17 08:33hgbotCheckin
2013-09-17 08:33hgbotNote Added: 0061184
2013-09-17 08:33hgbotStatusnew => resolved
2013-09-17 08:33hgbotResolutionopen => fixed
2013-09-17 08:33hgbotFixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/a549285cc9f06226f1fd5567340749d3dd325312 [^]
2013-09-17 08:34shankarbNote Added: 0061185
2013-09-17 08:34shankarbStatusresolved => closed
2013-09-17 08:34shankarbFixed in Version => 3.0MP28
2013-09-17 19:03hudsonbotCheckin
2013-09-17 19:03hudsonbotNote Added: 0061262

Notes
(0061184)
hgbot   
2013-09-17 08:33   
Repository: erp/devel/pi
Changeset: a549285cc9f06226f1fd5567340749d3dd325312
Author: Adrián Romero <adrianromero <at> openbravo.com>
Date: Tue Sep 17 12:00:46 2013 +0530
URL: http://code.openbravo.com/erp/devel/pi/rev/a549285cc9f06226f1fd5567340749d3dd325312 [^]

Fixes Issue 0024780: Process type PL/SQL Procedure cannot be executed as scheduled

The scheduler tries to instantiate the abstract class org.openbravo.erpCommon.ad_process.ProcedureProcess.
Instead of tha instantiating the class org.openbravo.erpCommon.ad_process.PinstanceProcedure.

---
M src/org/openbravo/scheduling/ProcessBundle.java
---
(0061185)
shankarb   
2013-09-17 08:34   
Code reviewed and verified in pi changeset a549285cc9f0.
(0061262)
hudsonbot   
2013-09-17 19:03   
A changeset related to this issue has been promoted main and to the
Central Repository, after passing a series of tests.

Promotion changeset: https://code.openbravo.com/erp/devel/main/rev/1c53d622fc50 [^]

Maturity status: Test