Add session and servlet checks for JBoss7