This week's book giveaway is in the Mac OS forum. We're giving away four copies of a choice of "Take Control of Upgrading to Yosemite" or "Take Control of Automating Your Mac" and have Joe Kissell on-line! See this thread for details.
That's an example of the kind of problems which may arrise when you put attribute with the same name in different scopes. The getProperty/setProperty actions look for "person" in one of the scopes, using findAttribute, and finds it in the request scope. So you're actually setting TestUser into the person in request scope.
JSP.5.3 <jsp:getProperty> The value of the name attribute in jsp:setProperty and jsp:getProperty will refer to an object that is obtained from the pageContext object through its findAttribute method.
However, the spec continues :
The object named by the name must have been "introduced" to the JSP processor using either the jsp:useBean action or a custom action with an associated VariableInfo entry for this name. If the object was not introduced in this manner, the container implementation is recommended (but not required) to raise a translation error, since the page implementation is in violation of the specification.
Note : A consequence of the previous paragraph is that objects that are stored in, say, the session by a front component are not automatically visible to jsp:setProperty and jsp:getProperty actions in that page unless a jsp:useBean action, or some other action, makes them visible.
I would expect the container to either skip the person in the request scope, or to raise an error, but as the spec says, the container implementation is recommended (but not required) to raise a translation error. Your container chooses to use the attribute that was set by the servlet, even if it's not been introduced by the jsp:useBean action.