Fixing memory issues. Introducing Gson.