Calendar Search Indexes

Advanced Configuration of Axigen

The WebMail calendar search feature introduced in version X3 is powered by a calendar index.

Axigen will create one index file for every Calendar folder of each account.

Calendar Index update frequency

A number of dedicated calendar index update jobs are run periodically to re-compute calendar indexes.

Because the number of available jobs depends upon the number of accounts existing on the server and the execution time of a job depends on the volume of calendar changes that are performed on the indexed calendar folders its hard to tell when exactly a change in a calendar event is reflected in an update of the calendar index. In the normal scenario a calendar index update might take anywhere between 1 and 60 seconds; on a loaded system the delay encountered on updating a calendar index can significantly increase.

Calendar Index Location (Local Folders)

Calendar indexes are created asynchronously and in a folder hierarchy as described below:

Calendar index location

/var/opt/axigen/domains/mumu.ro/calendar.idx/0/240/16777243
^ domains file system location
                       ^ domain name
                               ^ calendar index storage
                                            ^ hashing structure
                                              ^ account id (decimal)
                                                  ^ folder id (decimal)

Given a domain, account and folder triplet, the location of the calendar index can be computed via the CLI:

Looking up folder ids

<#> search object a+Birthdays@mumu.ro

* a+Birthdays@mumu.ro (folder):

*     Folder path: Birthdays

*     Folder id: 240_16777243 (0x0100001B)

 

[user ~]$ find /var/opt/axigen/domains/mumu.ro/ -wholename "*/240/16777243"

/var/opt/axigen/domains/mumu.ro/calendar.idx/0/240/16777243

Calendar Index Location (Public Folders)

Public Folders of Calendar type are indexed under a special location, tied to the postmaster account.

Calendar index location

/var/opt/axigen/domains/mumu.ro/calendar.idx/0/40_public/16777243
^ domains file system location
                       ^ domain name
                               ^ calendar index storage
                                            ^ hashing structure
                                              ^ account id (decimal) followed by "_public" suffix
                                                  ^ folder id (decimal)

Indexed content

The following calendar content is indexed (and thus searchable):

  • VCALENDAR DESCRIPTION
    • This is looked up in:
      • VCALENDAR DESCRIPTION
      • If not found, it is looked up in VCALENDAR X-ALT-DESC
      • If not found, it is finally looked up in the RFC822 TEXT/HTML part
  • VCALENDAR SUMMARY
  • VCALENDAR LOCATION
  • ORGANIZER name and email
  • ATTENDEEs name and email
  • ATTACHMENT names (attachments in the RFC822 message containing the VCALENDAR part)

Note on recurring events

Recurring events are indexed as described above; alongside the master instance of the recurring event any exceptions are also indexed.

When an exception to a recurring event is deleted, its participation in the calendar index is deleted whenever the index is updated.

Index size

The size of the calendar index is directly proportional to the size of the indexed content (and the DESCRIPTION field is likely to contain most of the data that is registered as part of the index).

You can therefore expect a calendar index to be anywhere from 60KB (for an index that contains a single calendar item) to 1.5MB for an index over a Calendar folder containing 1000 typical events (5-6 lines of text as part of the DESCRIPTION).

Backing up

The calendar indexes do not require backing up; these are part of the metadata that Axigen can just recompute whenever it needs to.