Open purefountain opened 4 years ago
From the source code. The encoding
parameters is nacos defined for itself. And nacos do transport using UTF-8 always.
So I think it is not a bug. But is an code quality enhancement.
From the source code. The
encoding
parameters is nacos defined for itself. And nacos do transport using UTF-8 always.So I think it is not a bug. But is an code quality enhancement.
I create a pull request for this and travis-cli failed. but build successfully in travis' log, i'm cufuse for it. #
Sorry, I double check the logic for this part codes. And find it may be not a bug.
I think we should discuss it and ask the original author why he code it like this.
com.alibaba.nacos.core.utils.WebUtils
I think there is a potential bug here, because not all of the default encoding is UTF-8 A better way:
value = HttpUtils.decode(new String(value.getBytes(), encoding), encoding);