1. Obtain the URL of the Request Path. For example, the URL is:
Http: // 127.0.0.1: 8080/struts2/test/path1/path2/path3/test. Action
2. First, find the package whose namespace is/path1/path2/path3,
If the package exists, search for the action named test in the package,
If this action is found, access this action,
If this action is not found, the system immediately redirects to the default tablespace [namespase = ""] To find the action.
If this action is found in the default tablespace, the action is executed.
If this action is not found in the default tablespace, the default action defined in the tablespace is executed.
If the default action is defined in the default tablespace, the action is executed.
If no default action is defined in the default tablespace, Error 404 cannot be found
If this package does not exist, go to step 3;
3. Find the package whose namespace is/path1/path2,
If the package exists, search for the action named test in the package,
If this action is found, access this action,
If this action is not found, the system immediately redirects to the default tablespace [namespase = ""] To find the action.
If this action is found in the default tablespace, the action is executed.
If this action is not found in the default tablespace, the default action defined in the tablespace is executed.
If the default action is defined in the default tablespace, the action is executed.
If no default action is defined in the default tablespace, Error 404 cannot be found
If the package does not exist, go to step 4;
4. Find the package whose namespace is/path1,
If the package exists, search for the action named test in the package,
If this action is found, access this action,
If this action is not found, the system immediately redirects to the default tablespace [namespase = ""] To find the action.
If this action is found in the default tablespace, the action is executed.
If this action is not found in the default tablespace, the default action defined in the tablespace is executed.
If the default action is defined in the default tablespace, the action is executed.
If no default action is defined in the default tablespace, Error 404 cannot be found
If the package still does not exist, find the action named test under the package of the default namaspace (the default namespace is an empty string ""),
If you still cannot find the action, the page prompts that the action cannot be found, and the Error 404 cannot find the content
In addition, if the default tablespace is not defined, access the location of the default tablespace [namespase = "] is interrupted. The system prompts that action cannot be found in step 404.