Adding more ApplicationContext definition files might require some changes to be made on the servlet and Spring containers. Follow the given steps:
- In the ch02-web-xml project, it is recommended to create another XML definition file for application-related model objects such as Employee and Department. Using STS Eclipse or a template, define beans-context.xml and save the file in the directory where the root context is located:
- Open beans-context.xml, together with the required XSD schemas and metadata including all the Employee- and Department-related bean objects created in the previous recipes:
<?xml version="1.0" encoding="UTF-8"?> ...