Anonymous | Login
Project:
RSS
  
News | My View | View Issues | Roadmap | Summary

View Issue DetailsJump to Notes ] Issue History ] Print ]
ID
0020079
TypeCategorySeverityReproducibilityDate SubmittedLast Update
backport[Openbravo ERP] 09. Financial managementmajoralways2012-03-21 16:202015-02-12 14:33
ReporterdalsasuaView Statuspublic 
Assigned Todalsasua 
PriorityurgentResolutionout of dateFixed in Version
StatusclosedFix in branch2.50Fixed in SCM revision
ProjectionnoneETAnoneTarget Version
OSAnyDatabaseAnyJava version
OS VersionDatabase versionAnt version
Product VersionSCM revision 
Review Assigned To
Web browser
ModulesCore
Regression level
Regression date
Regression introduced in release
Regression introduced by commit
Triggers an Emergency PackNo
Summary

0020079: Accounting engine stops in case of lots of organizations, and document types at organization level

DescriptionIn an instance with 97 different organization, each of them with specific API/ARI/APC/ARC document types, accounting stops after processing couple of organizations.
Steps To ReproduceCreate dozens of organizations, each of them with it's own document types.
Create hundreds of invoices for distinct organizations
Run accounting background process
Realize that stops after a while, leaving unposted invoices
Proposed Solutiondiff --git a/src/org/openbravo/erpCommon/ad_forms/AcctServer.java b/src/org/openbravo/erpCommon/ad_forms/AcctServer.java
--- a/src/org/openbravo/erpCommon/ad_forms/AcctServer.java
+++ b/src/org/openbravo/erpCommon/ad_forms/AcctServer.java
@@ -63,6 +63,7 @@
   public String AD_Table_ID = "";
   public String AD_Client_ID = "";
   public String AD_Org_ID = "";
+ public String Caller_AD_Org_ID = "";
   public String Status = "";
   public String C_BPartner_ID = "";
   public String C_BPartner_Location_ID = "";
@@ -281,6 +282,7 @@
   public AcctServer(String m_AD_Client_ID, String m_AD_Org_ID, ConnectionProvider connectionProvider) {
     AD_Client_ID = m_AD_Client_ID;
     AD_Org_ID = m_AD_Org_ID;
+ Caller_AD_Org_ID = m_AD_Org_ID;
     this.connectionProvider = connectionProvider;
     if (log4j.isDebugEnabled())
       log4j.debug("AcctServer - LOADING ARRAY: " + m_AD_Client_ID);
@@ -314,7 +316,7 @@
 
       log4j.debug("AcctServer.run - AD_Client_ID: " + AD_Client_ID);
       AcctServerData[] data = AcctServerData.select(connectionProvider, tableName, AD_Client_ID,
- AD_Org_ID, strDateColumn, 0, Integer.valueOf(batchSize).intValue());
+ Caller_AD_Org_ID, strDateColumn, 0, Integer.valueOf(batchSize).intValue());
 
       if (data != null && data.length > 0) {
         if (log4j.isDebugEnabled()) {
@@ -1729,9 +1731,9 @@
     // log4j.debug("AcctServer - AcctSchema length-" + (this.m_as).length);
     for (int i = 0; i < docTypes.length; i++) {
       AcctServerData data = AcctServerData.selectDocuments(connectionProvider, tableName,
- AD_Client_ID, AD_Org_ID, docTypes[i].name, strDateColumn);
+ AD_Client_ID, Caller_AD_Org_ID, docTypes[i].name, strDateColumn);
 
- if (data != null) {
+ if (data != null && data.id != null) {
         if (data.id != null && !data.id.equals("")) {
           if (log4j.isDebugEnabled()) {
             log4j.debug("AcctServer - not posted - " + docTypes[i].name + " document id: "
TagsNo tags attached.
Attached Files

- Relationships Relation Graph ] Dependency Graph ]
blocks defect 0020078 closededuardo_Argal Accounting engine stops in case of lots of organizations, and document types at organization level 

-  Notes
(0074409)
plujan (manager)
2015-02-12 14:33

Backports to 2.50 branch are no longer supported

- Issue History
Date Modified Username Field Change
2012-03-21 16:20 dalsasua Type defect => backport
2012-03-21 16:20 dalsasua fix_in_branch => 2.50
2015-02-12 14:33 plujan Note Added: 0074409
2015-02-12 14:33 plujan Status scheduled => closed
2015-02-12 14:33 plujan Resolution open => out of date


Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker