-
Task
-
Resolution: Done
-
High
-
None
Following from [Spike CPS-631|https://wiki.onap.org/display/DW/CPS-631+Spike%3A+Which+ObjectMapper+to+use+and+how+best+to+use+it+for+performance], decision was made to use the Jackson parser instead of GSON parser in all repos.
So remove any use of GSON like
import com.google.gson.GsonBuilder Gson GSON = new GsonBuilder().create() GSON.fromJSON() GSON.toJSON()
Replace with
import com.fasterxml.jackson.databind.ObjectMapper ObjectMapper objectMapper = new ObjectMapper() objectMapper.readValue() objectMapper.writeValueAsString()
Scope, all relevant Repos (create subtasks if needed to track and split workload)
- CPS
- DMI-Plugin
- CPS-Temporal (might not be used here)
A/C
- GSON fis no longer present in any (CPS) POM files
- ensure the relevant version property is removed too
- (code review phase) Only one ObjectMapper should be instantiated per class to save memory. Possible use @autowire annotation to ensure 'singleton' pattern. (this might affect testware!)