Anonymous | Login
News | My View | View Issues | Roadmap | Summary

View Issue DetailsJump to Notes ] Issue History ] Print ]
TypeCategorySeverityReproducibilityDate SubmittedLast Update
design defect[Openbravo ERP] A. Platformminorhave not tried2017-10-24 10:442017-10-24 10:53
ReporteralostaleView Statuspublic 
Assigned Toplatform 
PrioritynormalResolutionopenFixed in Version
StatusacknowledgedFix in branchFixed in SCM revision
ProjectionnoneETAnoneTarget Version
OSAnyDatabaseAnyJava version
OS VersionDatabase versionAnt version
Product VersionSCM revision 
Review Assigned To
Web browser
Regression level
Regression date
Regression introduced in release
Regression introduced by commit
Triggers an Emergency PackNo

0037151: upgrade/replace JSON library

DescriptionJettison library is used to handle JSON <-> String transformations in Java.

Current version is 1.3 (2011), with some patches to solve some critical issues.

This is a very old version that should be upgraded.

Steps To Reproduce-
Proposed SolutionThis library is consumed not only by Openbravo platform but also any code manipulating JSON in Java.

Reviewing changes since then to latest version, it turns out there are some that might cause changes in behavior [1].

One of this changes fixes the following issue, given a JSON like:


the following code:



 "null" (java.lang.String)

In newer versions, it returns a null pointer.

Currently, there is code like:

1. if (josonObject.getString("a").equals("null")) {...}
2. if ("null".equals(josonObject.getString("a"))) {...}

In first case new behavior would throw NPE, whereas in 2nd case it would silently misbehave.

Therefore, this change must be carefully handled.

Ideally, there should be an Openbravo Platform layer between functional code and JSON library, so that these API changes would be managed by it or even it would be possible to replace this library by any other one (note jettison project currently is not very active).

[1] [^]

TagsNo tags attached.
Attached Files

- Relationships Relation Graph ] Dependency Graph ]
related to defect 0037135 closedalostale OOM parsing corrupted JSON 

-  Notes
There are no notes attached to this issue.

- Issue History
Date Modified Username Field Change
2017-10-24 10:44 alostale New Issue
2017-10-24 10:44 alostale Assigned To => platform
2017-10-24 10:44 alostale Modules => Core
2017-10-24 10:44 alostale Triggers an Emergency Pack => No
2017-10-24 10:44 alostale Type defect => design defect
2017-10-24 10:44 alostale Status new => acknowledged
2017-10-24 10:45 alostale Relationship added related to 0037135
2017-10-24 10:53 alostale Summary upgrade JSON library => upgrade/replace JSON library

Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker