728x90 반응형 SMALL server.compression1 Rest API Response 압축하기 (Response size 줄이기) Response size 가 너무 클 때 압축하는 방법은 무엇이 있을까? Json data 라고 가정하고 생각해 보면 1. 가장 간단한건 serializing 할 때 json name:value 에서 name 을 줄이는 것이다. Gson 을 사용한다고 가정하고 @SerializedName 을 사용하면 쉽게 줄일 수 있다. public class UserDto { @SerializedName(value = "x", alternate = "x") protected int no; @SerializedName(value = "i", alternate = "i") protected String id; @SerializedName(value = "n", alternate = "n") protected String .. 2022. 3. 17. 이전 1 다음 728x90 반응형 LIST