Win a copy of Programmer's Guide to Java SE 8 Oracle Certified Associate (OCA) this week in the OCAJP forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Marcus Green SCWCD Chapter Quizzes

 
Niall Mullan
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi there,

Apologies if this is covered somewhere else, I had a couple of questions in relation to some of the answers on these quizzes (detailed below), anyone know how to contact the man himself so as to feedback ?

I can't seem to post on the forums in the website itself @examulator, and reply email is a black hole so thought I would try here.

Thanks,
Mully

*******************
Questions I had were;

Web Container Model Quiz
Q3 Answer B is listed as correct --
B. A session attribute will, by default be visible to all subsequent requests from the same client
Is this not invalidated though if the session expires ?

Q6 Answer B is listed as correct --
B. Filters are called in the order they appear in the deployment descriptor
I thought that it depended on the order and the matching pattern i.e. a filter using a servlet-name would alway be called after any using a url-pattern regardless of the declaration order in the DD. While the DD order does matter its just that url-pattern matched filters are put before the servlet-name matched ones.

Preview Structure and Deployment Quiz
Q2 Answer E is listed as correct --
E. The deployment descriptor must have the name WEB.XML
I tried this and with the deployment descriptor in uppercase i.e. WEB.XML, none of my servlets were found by Tomcat -- does this file not have to be web.xml ??
*******************
 
Vijitha Kumara
Bartender
Posts: 3914
9
Chrome Fedora Hibernate
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Niall Mullan wrote:
Web Container Model Quiz
Q3 Answer B is listed as correct --
B. A session attribute will, by default be visible to all subsequent requests from the same client
Is this not invalidated though if the session expires ?

Question may look bit unclear but I think it's assuming that session has not expired (by "all subsequent requests from the same client ")

Q6 Answer B is listed as correct --
B. Filters are called in the order they appear in the deployment descriptor
I thought that it depended on the order and the matching pattern i.e. a filter using a servlet-name would alway be called after any using a url-pattern regardless of the declaration order in the DD. While the DD order does matter its just that url-pattern matched filters are put before the servlet-name matched ones.

With the constraint that filters mapped by <url-pattern> are called before <servlet-name> they are called the order they have defined in the DD.

Preview Structure and Deployment Quiz
Q2 Answer E is listed as correct --
E. The deployment descriptor must have the name WEB.XML
I tried this and with the deployment descriptor in uppercase i.e. WEB.XML, none of my servlets were found by Tomcat -- does this file not have to be web.xml ??
*******************

Yes, It should be web.xml.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic