skip to Main Content

remove backslashes from JSON string

I have a object of type: RestConsumerRequest<RewardsAccumulationRequest> which has @JsonProperty annotated fields like: @JsonProperty("product_code") private String productCode; @JsonProperty("sub_product_code") private String subProductCode; when I wrote it as String using: LOG.info("RestConsumerRequest<RewardsAccumulationRequest> is {}", objectMapper.writeValueAsString(restRequest)) I got: ..., "product_code":"CSS","sub_product_code":"SC",... I tried removing the…

VIEW QUESTION
Back To Top
Search