In Lotus Notes/domino 7 application performance, part 1th, we explored how to improve the performance of the Lotus Notes/domino 7 application by effectively using Database properties and collection of documents. In the 2nd part, we'll explain how to build a high-performance view. As in part 1th, this article also provides a lot of code snippets that you can reuse and modify to meet your needs.
Through many years of analysis of application performance issues, we find that problems and solutions often involve views. Usually, the view index is the problem. This article explains how this can happen, and what you can do to diagnose and resolve this type of problem. But more frequently in the past few years is another type of view performance problem. This involves displaying a view of the reader accessing the managed document (Reader access controlled document). The performance problems that occur in these views are usually not related to indexes, so we need to take a moment to discuss them separately.
This article assumes that you are an experienced Notes/domino application developer.
Understanding the View index (Update Task)
Before diagnosing a performance problem involving a view index, the first thing you need to know is how the indexing process works. The index is typically completed by the Update task, which runs once on the Domino server every 15 minutes. Technically, this interval can be adjusted, but this involves renaming the file, so it's rarely done in practice.
When the update task runs, it looks for each database on the server that has been modified since the update task was last run. It then refreshes the views in those databases. Based on our experience, it is reasonable to assume that it takes about 100 milliseconds to refresh a normal view in a production database in a production environment.
The logical question to ask is, "what marks a view that needs to be updated?" "The view needs to be updated whenever any of the following conditions are present:
The copy sends a document to modify to the database.
The user saves or deletes a document (and exits the database).
The router passes a document.