上QQ阅读APP看书,第一时间看更新
The problem
With the use of UTF-8 prior to Java 9, the strings had to be converted to string objects, that is, instances of the java.lang.String class. This conversion took place on-demand, which usually resulted in slower systems and unnecessary memory usage. The processing time was extremely short, but the memory usage was excessive. Every character in an interned string required at least three bytes of memory and potentially more.
A related problem is that the stored strings were not accessible to all JVM processes.