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

View Issue DetailsJump to Notes ] Issue History ] Print ]
ID
0030054
TypeCategorySeverityReproducibilityDate SubmittedLast Update
defect[Openbravo ERP] A. Platformminorhave not tried2015-05-30 21:452015-11-14 13:02
ReportershuehnerView Statuspublic 
Assigned Toshuehner 
PrioritynormalResolutionfixedFixed in Version3.0PR15Q3
StatusclosedFix in branchFixed in SCM revisionada6ae238e94
ProjectionnoneETAnoneTarget Version
OSAnyDatabaseAnyJava version
OS VersionDatabase versionAnt version
Product VersionSCM revision 
Review Assigned Toalostale
Web browser
ModulesCore
Regression level
Regression date
Regression introduced in release
Regression introduced by commit
Triggers an Emergency PackNo
Summary

0030054: Cleanup warnings in wad generated code (srcAD)

DescriptionAny warnings in wad-generated code are per se not really interesting and that code is in do not touch mode.

However there are a few which can be very easily fixed and help to reduce the huge amount of open warnings in eclipse.
Steps To ReproduceCheck amount of eclipse warnings filtering for srcAD folder
Proposed SolutionCheck each type for simple fix.
simple in:
- easy + fast to fix
- easy + fast to review
- obviously safe/correct
TagsNo tags attached.
Attached Files

- Relationships Relation Graph ] Dependency Graph ]
related to defect 0030055 closedshuehner Cleanup all eclipse warnings in src-trl 
blocks feature request 0031477 newshuehner Tracking issue to reduce the huge number of eclipse warnings in pi 

-  Notes
(0077935)
hgbot (developer)
2015-06-01 13:09

Repository: erp/devel/pi
Changeset: ada6ae238e948125c092eb34c046f385d978c01b
Author: Stefan Hühner <stefan.huehner <at> openbravo.com>
Date: Sun May 31 13:33:21 2015 +0200
URL: http://code.openbravo.com/erp/devel/pi/rev/ada6ae238e948125c092eb34c046f385d978c01b [^]

Fixed 30054: Cleanup warnings in wad-generated code

Goal is not to make wad-generated code nicer (as it should go away).
But instead to reduce the big number of eclipse warnings in it.
So they get out of the way when looking at warning in other code

Changes:
- remove java.util.Arrays & java.util.List imports and covered by existing
  java.util.* import
- The other 'unused' code warnings are not so easy to fix so in context of wad
  supress all 'unused' warnings in the srcAD files on class level.
  As secondary change remove to existing more specific unused annotation
  as they triggered warnings themselves (and are covered by the new one anyway)
- Remove private log4j Logger declaration. It shadows a similar one coming
  inherited from HttpBaseServer. That one is defined as non-static via
  this.getClass so is already of the instance we want (the concrete window-
  servlet). That means logger functionally works as before (you can still
  set i.e. debug level logging for individual servlet as before).
- in printPageEdit function a parameter was being assigned to in the function
  quite often. Apparently those cannot be surpressed. After checking easy to fix
  - All caller use just simple constant on every call.
  - So add local variable on top of function and copy param value.
  - Keep existing param name as variable name to reduce diff of generated code.

Together those reduce number of warnings in srcAD from hundreds down to just 14.

---
M src-wad/src/org/openbravo/wad/javasource.javaxml
---
(0078059)
alostale (manager)
2015-06-04 12:53

code reviewed

checked wad output before vs after change

- Issue History
Date Modified Username Field Change
2015-05-30 21:45 shuehner New Issue
2015-05-30 21:45 shuehner Assigned To => shuehner
2015-05-30 21:45 shuehner Modules => Core
2015-05-30 21:45 shuehner Triggers an Emergency Pack => No
2015-06-01 13:09 hgbot Checkin
2015-06-01 13:09 hgbot Note Added: 0077935
2015-06-01 13:09 hgbot Status new => resolved
2015-06-01 13:09 hgbot Resolution open => fixed
2015-06-01 13:09 hgbot Fixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/ada6ae238e948125c092eb34c046f385d978c01b [^]
2015-06-01 13:11 shuehner Review Assigned To => alostale
2015-06-04 12:24 alostale Relationship added related to 0030055
2015-06-04 12:53 alostale Note Added: 0078059
2015-06-04 12:53 alostale Status resolved => closed
2015-06-04 12:53 alostale Fixed in Version => 3.0PR15Q3
2015-11-14 13:02 shuehner Relationship added blocks 0031477


Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker