ReviewIn the previous section, we have implemented the Java classes and organized them in various layers. In this section, we will write the configuration files, which are mainly XML documents.
Table of ContentsPart 1: Introduction and Functional Specs
Part 2: MongoDB setup
Part 3: Java classes
Part 4: XML configuration
Part 5: HTML Files (with AJAX)
Part 6: Running the Application
ConfigurationTo enable MongoDB repository, including template support, we have to declare the following beans:
- a Mongo repository
- a Mongo host
- a Mongo template
- Optionally, we declared an InitMongoService to automatically populate our database with sample data
For MongoDB connection, we've extracted the database properties in a separate file.
Finally, here's our applicationContext.xml file
Share the joy:
Subscribe by reader Subscribe by email Share