Review the search sequence of struts2 action names

Source: Internet
Author: User
1. obtain the URI of the Request Path. For example, the URL is http: // server/struts2/path1/path2/path3/test. action 2. first, find the package whose namespace is/path1/path2/path3. If this package exists, search for the action named test in this package. If this package does not exist, go to step 3; 3. find the package whose namespace is/path1/path2. If this package exists, search for the action named test in this package. If this 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 the package still does not exist, go to the package of the default namaspace and find the package named test. Action (the default namespace is an empty string ""). If it still cannot be found, the page prompts that the action cannot be found. If the package in the path exists, but this action does not exist, it will go to the default namespace to find the default namespace for this action, and namespace is not set, the default Suffix of the Null String in struts2 is action, so you can add action or not at the end of the access path.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.