Openbravo Issue Tracking System - Retail Modules
View Issue Details
0036582Retail ModulesWeb POSpublic2017-08-02 15:402017-08-24 09:12
ioritzCia 
ranjith_qualiantech_com 
normalmajoralways
closedfixed 
5
 
RR17Q4 
marvintm
No
0036582: Bad logging code at exception at MobileCoreLoginHandler
There is bad logging code at MobileCoreLoginHandler.

In https://code.openbravo.com/erp/pmods/org.openbravo.mobile.core/file/e3cb74a79b0d/src/org/openbravo/mobile/core/login/MobileCoreLoginHandler.java [^]

Line 198 should disappear, it is wrong and in production systems it is printing errors in catalina.out

Line 199 should be a debug and should not print the stack trace when the exception is because of wrong password.

Line 204 should be reviewed as well when the exception is because of wrong password.

For lines 199 and 204 the behaviour should only change when it is an identification error, not for the rest of the error.

There are two files uploaded with proposed changes to take out the printStackTraces from posterminal and mobilecore.
Try to login in the POS with a wrong password.
See catalina.out and openbravo.log
No tags attached.
related to defect 0031674 closed alostale Openbravo ERP too verbose log for invalid login attempt 
blocks design defect 0036162 acknowledged Triage Platform Base Openbravo ERP clean up openbravo.log 
diff mobilecore-printStackTrace-removal.diff (555) 2017-08-02 17:20
https://issues.openbravo.com/file_download.php?file_id=10952&type=bug
diff posterminal-printStackTrace-removal.diff (5,522) 2017-08-02 17:20
https://issues.openbravo.com/file_download.php?file_id=10953&type=bug
Issue History
2017-08-02 15:40ioritzCiaNew Issue
2017-08-02 15:40ioritzCiaAssigned To => Retail
2017-08-02 15:40ioritzCiaResolution time => 1502834400
2017-08-02 15:40ioritzCiaTriggers an Emergency Pack => No
2017-08-02 15:40ioritzCiaRelationship addedblocks 0036162
2017-08-02 15:41ioritzCiaRelationship addedrelated to 0031674
2017-08-02 15:41ioritzCiaDescription Updatedbug_revision_view_page.php?rev_id=15569#r15569
2017-08-02 15:42ioritzCiaSummaryBad code at MobileCoreLoginHandler => Bad logging code at exception at MobileCoreLoginHandler
2017-08-02 16:55ioritzCiaDescription Updatedbug_revision_view_page.php?rev_id=15570#r15570
2017-08-02 17:02ioritzCiaDescription Updatedbug_revision_view_page.php?rev_id=15571#r15571
2017-08-02 17:20ioritzCiaFile Added: mobilecore-printStackTrace-removal.diff
2017-08-02 17:20ioritzCiaFile Added: posterminal-printStackTrace-removal.diff
2017-08-02 17:22ioritzCiaDescription Updatedbug_revision_view_page.php?rev_id=15572#r15572
2017-08-03 10:23ioritzCiaDescription Updatedbug_revision_view_page.php?rev_id=15587#r15587
2017-08-05 08:27ranjith_qualiantech_comAssigned ToRetail => ranjith_qualiantech_com
2017-08-05 08:27ranjith_qualiantech_comStatusnew => scheduled
2017-08-07 13:54hgbotCheckin
2017-08-07 13:54hgbotNote Added: 0098406
2017-08-07 13:55hgbotCheckin
2017-08-07 13:55hgbotNote Added: 0098407
2017-08-07 13:55hgbotStatusscheduled => resolved
2017-08-07 13:55hgbotResolutionopen => fixed
2017-08-07 13:55hgbotFixed in SCM revision => http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/5984743bae371bc89d5002e450d9ba2582cbb567 [^]
2017-08-09 14:02SandrahuguetReview Assigned To => Sandrahuguet
2017-08-10 14:31SandrahuguetNote Added: 0098477
2017-08-10 14:31SandrahuguetStatusresolved => new
2017-08-10 14:31SandrahuguetResolutionfixed => open
2017-08-10 14:44SandrahuguetNote Edited: 0098477bug_revision_view_page.php?bugnote_id=0098477#r15645
2017-08-11 08:29ranjith_qualiantech_comStatusnew => scheduled
2017-08-22 08:05hgbotCheckin
2017-08-22 08:05hgbotNote Added: 0098564
2017-08-22 08:05hgbotStatusscheduled => resolved
2017-08-22 08:05hgbotResolutionopen => fixed
2017-08-22 08:05hgbotFixed in SCM revisionhttp://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/5984743bae371bc89d5002e450d9ba2582cbb567 [^] => http://code.openbravo.com/erp/pmods/org.openbravo.mobile.core/rev/b268a450e0377af624e64f79ff4a4648ba29e102 [^]
2017-08-24 09:12marvintmReview Assigned ToSandrahuguet => marvintm
2017-08-24 09:12marvintmStatusresolved => closed
2017-08-24 09:12marvintmFixed in Version => RR17Q4

Notes
(0098406)
hgbot   
2017-08-07 13:54   
Repository: erp/pmods/org.openbravo.mobile.core
Changeset: a117bf6fbc3401d86ed5962ab31458135860c319
Author: Ranjith S R <ranjith <at> qualiantech.com>
Date: Mon Aug 07 17:23:48 2017 +0530
URL: http://code.openbravo.com/erp/pmods/org.openbravo.mobile.core/rev/a117bf6fbc3401d86ed5962ab31458135860c319 [^]

Related to issue 36582 : Replaced printStackTrace with Logger

---
M src-util/modulescript/src/src/org/openbravo/mobile/core/modulescript/UpdateEmptyMobileServerKeyData.java
M src/org/openbravo/mobile/core/login/MobileCoreLoginHandler.java
---
(0098407)
hgbot   
2017-08-07 13:55   
Repository: erp/pmods/org.openbravo.retail.posterminal
Changeset: 5984743bae371bc89d5002e450d9ba2582cbb567
Author: Ranjith S R <ranjith <at> qualiantech.com>
Date: Mon Aug 07 17:23:59 2017 +0530
URL: http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/5984743bae371bc89d5002e450d9ba2582cbb567 [^]

Fixed issue 36582 : Replaced printStackTrace with Logger

---
M src/org/openbravo/retail/posterminal/POSUtils.java
M src/org/openbravo/retail/posterminal/ad_reports/CashUpReport.java
M src/org/openbravo/retail/posterminal/master/CharacteristicValueProperties.java
M src/org/openbravo/retail/posterminal/master/Product.java
M src/org/openbravo/retail/posterminal/term/Labels.java
M src/org/openbravo/retail/posterminal/utility/GenerateProductImages.java
---
(0098477)
Sandrahuguet   
2017-08-10 14:31   
(edited on: 2017-08-10 14:44)
Issue reopened due to the following reasons:

1. .class files related to modulescript[1] should be generated (ant compile.modulescript -Dmodule=org.openbravo... ) and pushed.

2. not fixed completely. See description:
Line 199 should be a debug and should not print the stack trace when the exception is because of wrong password.
Line 204 should be reviewed as well when the exception is because of wrong password.
For lines 199 and 204 the behaviour should only change when it is an identification error, not for the rest of the error.


[1] https://code.openbravo.com/erp/pmods/org.openbravo.mobile.core/diff/a117bf6fbc34/src-util/modulescript/src/src/org/openbravo/mobile/core/modulescript/UpdateEmptyMobileServerKeyData.java [^]

(0098564)
hgbot   
2017-08-22 08:05   
Repository: erp/pmods/org.openbravo.mobile.core
Changeset: b268a450e0377af624e64f79ff4a4648ba29e102
Author: Ranjith S R <ranjith <at> qualiantech.com>
Date: Tue Aug 22 11:34:35 2017 +0530
URL: http://code.openbravo.com/erp/pmods/org.openbravo.mobile.core/rev/b268a450e0377af624e64f79ff4a4648ba29e102 [^]

Fixed issue 36582 : Replaced printStackTrace with Logger

* Updated class files in modulescript

---
M build/classes/org/openbravo/mobile/core/modulescript/UpdateEmptyMobileServerKey.class
M build/classes/org/openbravo/mobile/core/modulescript/UpdateEmptyMobileServerKeyData.class
---