Added cache & logging