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

View Issue DetailsJump to Notes ] Issue History ] Print ]
ID
0047963
TypeCategorySeverityReproducibilityDate SubmittedLast Update
defect[Openbravo ERP] A. Platformminorhave not tried2021-11-03 13:172021-11-04 10:16
ReportershuehnerView Statuspublic 
Assigned Toalostale 
PrioritynormalResolutionfixedFixed in VersionPR22Q1
StatusclosedFix in branchFixed 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

0047963: HostNameTask should not use System.out.println,System.err.println, printStackTrace for its output

DescriptionThat custom ant task is not using log4j at all but all of:
- System.out.println
- System.err.println
- e.printStackTrace

The comment explaining the reason:

      // using System.out instead of log4j to be able to run this tasks without
      // having compiled defined appenders

is most likely obsolete. As custom compiled appenders from Openbravo where removed with the "MMC Rebuild/Restart removal" project.

Today that code should be able to just use log4j and avoid being a bad example.
Steps To Reproducehttps://gitlab.com/openbravo/product/openbravo/-/commit/893bc475e92232ed0e71aee050848dab458d62e8#320d411275551c3035b76c3ab909e6c86a0b53e7_116_139 [^]
Proposed SolutionEither
a.) Remove the if/else block having the System.out.println in connection cannot be null
b.) if that is not possible change it to proper log4j error usage
TagsNo tags attached.
Attached Files

- Relationships Relation Graph ] Dependency Graph ]
related to feature request 0044269 closedalostale remove GUI rebuild+restart from MMC 
blocks design defect 0036162 acknowledgedTriage Platform Base clean up openbravo.log 

-  Notes
(0132824)
hgbot (developer)
2021-11-04 08:19

Merge Request created: https://gitlab.com/openbravo/product/openbravo/-/merge_requests/449 [^]
(0132829)
hgbot (developer)
2021-11-04 10:16

Merge request merged: https://gitlab.com/openbravo/product/openbravo/-/merge_requests/449 [^]
(0132830)
hgbot (developer)
2021-11-04 10:16

Directly closing issue as related merge request is already approved.

Repository: https://gitlab.com/openbravo/product/openbravo [^]
Changeset: ed2b66b7eed01407428c97e2806a839d742947f8
Author: Asier Lostalé <asier.lostale@openbravo.com>
Date: 2021-11-04T08:14:56+01:00
URL: https://gitlab.com/openbravo/product/openbravo/-/commit/ed2b66b7eed01407428c97e2806a839d742947f8 [^]

fixed ISSUE-47963: HostNameTask logs directly to stdout

Changed to use log4j instead.

---
M src/org/openbravo/base/session/HostNameTask.java
---

- Issue History
Date Modified Username Field Change
2021-11-03 13:17 shuehner New Issue
2021-11-03 13:17 shuehner Assigned To => platform
2021-11-03 13:17 shuehner Modules => Core
2021-11-03 13:17 shuehner Triggers an Emergency Pack => No
2021-11-03 13:17 shuehner Issue generated from 0047962
2021-11-03 13:17 shuehner Relationship added blocks 0036162
2021-11-04 08:07 alostale Relationship added related to 0044269
2021-11-04 08:19 hgbot Note Added: 0132824
2021-11-04 08:32 alostale Status new => scheduled
2021-11-04 08:32 alostale Assigned To platform => alostale
2021-11-04 10:16 hgbot Resolution open => fixed
2021-11-04 10:16 hgbot Status scheduled => closed
2021-11-04 10:16 hgbot Note Added: 0132829
2021-11-04 10:16 hgbot Fixed in Version => PR22Q1
2021-11-04 10:16 hgbot Note Added: 0132830


Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker