remove logs, add es flush on restart in dev mode