FEAT: make Java objects references persistent across JNI calls (for a given thread).