Strings consume a lot of memory in any application. Especially the char[] containing the individual UTF-16 characters is contributing to most of the memory consumption of a JVM by each character eating up two bytes. It is not uncommon to find 30% of the memory consumed by Strings, because not only are Strings the best format to interact with humans, but also popular HTTP APIs use lots of Strings.
![String Deduplication - A new feature in Java 8 Update 20](https://cdn-ak-scissors.b.st-hatena.com/image/square/7c57dea6bb137baa37c19a8efa1870ba1d574b65/height=288;version=1;width=512/https%3A%2F%2Fwww.codecentric.de%2Fog-2.png)