Struts 2 - Basic

Print the objectives

Take the exam   Take a beta test

This exam is focused on the struts2 framework which results of the joined forces of the Struts and Webwork comunities to create new version of Struts2 that is simpler to use and closer to what Struts was always meant to be. It covers everything a developer will need to get up and run using struts2 and assumes a working knowledges of some JEE technologies, including:

  • Filters, JSP, and Tag Libraries
  • HTML and HTTP
  • Web Containers (such as Tomcat)
  • XML

The following topics are not part of the Struts2 Basic exam (they are kept for the intermed exam):

  • Annotations
  • Advanced Interceptors
  • Type Conversion
  • Advanced Localization
  • Zero Configuration Pattern
  • Advanced Validation
  • Extension
  Released  Beta  Frozen  

Set up and Configuration

 
 

Setup the Web Application Deployment Descriptor (web.xml)  1 question

The web.xml web application descriptor file represents the core of the Java web application, it is also part of the core of the Struts framework.
  • Write the web.xml for configuring a basic struts2 web application.
  • Register a FilterDispatcher to initialize and enable framework functionality for handling requests.
  • Explain and define the following optional initialization parameters:
    • config
    • actionPackages
4 5 2

Setup the Struts Configuration (struts.xml)  1 question

  • Define a basic struts.xml file which is the core configuration file for the framework.
  • Describe the way to break up a large struts.xml into smaller pieces.
2 10 3

Constants Configuration  1 question

Constants provide a simple way to customize a Struts application by defining key settings that modify framework behavior.

Describe the several ways we can declare constants.
4 4 0

Packages Configuration  1 question

Packages are a way to group actions, results, result types, interceptors, and interceptor-stacks into a logical configuration unit.

Describe package configuration usage.
1 9 2

Includes configuration  1 question

Describe include configuration usage.

All other configurations elements are kept for the strut2 intermed exam.
1 4 0

Interceptors  1 question

Stacking and writing interceptors and the framework interceptors are not covered.

  • Undestand and explain interceptor mechanism
  • Describe interceptors configuration
10 5 1

Actions

 
 

Coding Actions  2 questions

  • Describe basic struts2 action usage.
  • Write actions that perform work with a single result being returned.
  • Write actions that can return different results depending on the outcome of the logic.
10 19 5

Configuring Actions  1 question

Dynamic Method Invocation and Wildcard Method are not covered.
  • Describe action mapping configuration attributes(exception handlers and interceptors attributes are not covered).
  • Describe how to specify multiple results type and a single result type with the action mapping.
  • Explain the way to create more than one entry point to an action with the action mapping "method" attribute.
4 1 2

Results  3 questions

When an Action class method completes, it returns a String whose value is used to select a result element.

  • Describe the way to determine the result for an action (annotation and code behind plugin are not covered).
  • Name the predifined result names defined by the ActionSupport base class.
  • Describe the base result types below semantics:
    • Dispatcher Result
    • Redirect Result
    • Redirect Action Result
All the other result types (Chain, Freemarker, HttpHeader, Stream, Velocity, XSL, PlainText, Tiles)are not covered.
5 1 3

Value Stack/OGNL  3 questions

  • Explain the purpose of the value stack.
  • Describe the OGNL usage in struts2 (only this part of OGNL is covered).
  • List the default variables in the value stack.
  • Enumerate the object that are in the value stack and their usages.
  • Write code that can acces to object placed on the value stack.
  • Describe the several ways you can access the value stack.
12 1 1

Basic validation  1 question

  • Explain the step by step basic vaildation workflow
  • Describe the role of the following elements in the basic validation process:
    • Action
    • Input form
    • validators in the xml file.
3 1 2

Tags

Identify the difference between Generic tags and UI tags.
 
 

Generic tags  2 questions

  • Describe the generic tags semantic.
  • Explain the difference between Control tags and Data Tags.
  • Understand and use the following Control tags:
    • if
    • elseIf
    • else
    • append
    • generator
    • iterator
    • merge
    • sort
    • subset
  • Understand and use the following Data tags:
    • a
    • action
    • bean
    • date
    • debug
    • i18n
    • include
    • param
    • property
    • push
    • set
    • text
    • url
5 6 8

UI tags (Ajax tags are not covered)  2 questions

  • Describe UI tags semantics.
  • Explain the difference between Form tags and non Form tags.
  • Understand and use the following Form tags:
    • checkbox
    • checkboxlist
    • combobox
    • doubleselect
    • head
    • file
    • form
    • hidden
    • label
    • optiontransferselect
    • optgroup
    • password
    • radio
    • reset
    • select
    • submit
    • textarea
    • textfield
    • token
    • updownselect
  • Understand and use the following non Form tags:
    • actionerror
    • actionmessage
    • component
    • div
    • fielderror
6 3 1

Exam information

  • 30 minutes
  • 20 questions (166)
  • 80% required
  • +3 √
  • - 12  points
  • 15 day delay
  • status: released

Exam leader