removing aws library memory problem allocation