added timeout so hthe whole server won't hang