java fixes
cache policy TODO
minor