Schlagwörter » Java EE
Processing Multiple URLs
Up to now, we have just been processing a single URL and not really taking advantage of the batch partition. In the last step, we update the code to take advantage of the partition. noch 163 Wörter
Writing to MongoDB
1) Add the MongoDBJava driver as a library to your project.
2) Create a property file to place connection information.
3) Create properties within the property file that define the server host name, ports, and authentication information to connect to the database. noch 91 Wörter
Create the Entities
Because we are crawling a site to get product data, it makes sense to create a product entity. Multiple products exist on one HTML page (doc) so a product container (products) will also be helpful. noch 76 Wörter
Running the Batch Job
The Java EE batch framework requires a launching mechanism either in the form of a JSP/Servlet or an EJB timer. We will create a JSF page to launch the job. noch 222 Wörter
This section will cover the partition mapper. The partition mapper will implement the functionality to operate the batch frame work in parallel. It is an optional component, but for a site parser it will be helpful to setup for performance. noch 319 Wörter