This topic describes Central Repository access. The optimisation can improve the performance of the applications using Central Repository.
The performance of applications which use the Central Repository can be improved by fine tuning the use of cache memory. The Central Repository supports caching by default but you can achieve further improvement by modifying the settings of the cache configuration file. This file is called cenrep.ini and is located either on the system drive or on the Z drive. Its contents look like this.
[CoarseGrainedCache] size= 100000 timeout= 500000
The two parameters which can be configured are:
size (the number of bytes reserved for caching)
timeout (the time in microseconds to hold repositories in the cache)
The timeout parameter controls a countdown during which a repository is held in the cache. The countdown begins when a repository ceases to be in any session of a CRepository object, unless you specify a notify-only client optimisation as discussed below. It ends when the value timeout is reached: the repository is then evicted from the cache.
The purpose of configuring centrep.ini is to improve performance of the Central Repository as a whole, rather than of applications individually. The optimum values of the parameters must be established by trial and error.
Notify-only client optimisations
The behaviour of the timeout can be modified by specifying a notify-only client optimisation. This means that the countdown during which a repository is cached begins after the last access operation of any type on that repository, even if the session is still in progress.
A notify-only client optimisation is specified by including the system-wide macro
#define SYMBIAN_CENTREP_NOC
Disabling caching
You can disable caching altogether by setting a cache size of 0 in centrep.ini
[CoarseGrainedCache] size= 0 timeout= 0
To provide for backup of a repository you must identify an owner application responsible for backup. This must have a suitable backup registration file (as used for all backup). By default, repository data is not backed up: you must also write the repository initialisation file to enable backup. In the initialisation file you specify the owner application by SID in the owner section and use the metadata values to specify the settings to be backed up. A setting is backed up if bit 25 of its metadata value is set. You can set this bit for the whole repository in the defaultMeta section or individually for settings and groups of settings using the metadata fields of the main section.
Copyright ©2010 Nokia Corporation and/or its subsidiary(-ies).
All rights
reserved. Unless otherwise stated, these materials are provided under the terms of the Eclipse Public License
v1.0.