finished porting lib_java, problem on the db persist