Symbian3/PDK/Source/GUID-724BA3CD-7648-51DF-9285-3AA7470987F4.dita
author Dominic Pinkman <Dominic.Pinkman@Nokia.com>
Thu, 11 Mar 2010 18:02:22 +0000
changeset 3 46218c8b8afa
parent 1 25a17d01db0c
child 5 f345bda72bc4
permissions -rw-r--r--
week 10 bug fix submission (SF PDK version): Bug 1892, Bug 1897, Bug 1319. Also 3 or 4 documents were found to contain code blocks with SFL, which has been fixed. Partial fix for broken links, links to Forum Nokia, and the 'Symbian platform' terminology issues.

<?xml version="1.0" encoding="utf-8"?>
<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
<!-- This component and the accompanying materials are made available under the terms of the License 
"Eclipse Public License v1.0" which accompanies this distribution, 
and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
<!-- Initial Contributors:
    Nokia Corporation - initial contribution.
Contributors: 
-->
<!DOCTYPE concept
  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
<concept xml:lang="en" id="GUID-724BA3CD-7648-51DF-9285-3AA7470987F4"><title>Optimising Repository Access</title><shortdesc>This topic describes Central Repository access. The optimisation can improve the performance of the applications using Central Repository. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody><section><title>Caching</title> <p>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. </p> <codeblock id="GUID-889AFB4B-7F70-5909-85D2-45C12F1A1B2F" xml:space="preserve">
[CoarseGrainedCache]
size= 100000
timeout= 500000
</codeblock> <p>The two parameters which can be configured are: </p> <ul><li id="GUID-936A5320-1B6B-58E8-82FD-739AF20FE718"><p> <codeph>size</codeph> (the number of bytes reserved for caching) </p> </li> <li id="GUID-E28F2AE7-7B2B-58F9-99CC-E55674A5027B"><p> <codeph>timeout</codeph> (the time in microseconds to hold repositories in the cache) </p> </li> </ul> <p>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. </p> <p>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. </p> <p><b>Notify-only client optimisations </b> </p> <p>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. </p> <p>A notify-only client optimisation is specified by including the system-wide macro </p> <codeblock id="GUID-9B5DDD2F-D9BE-58A1-91B9-D3E74B1F75A6" xml:space="preserve">#define SYMBIAN_CENTREP_NOC</codeblock> <p><b>Disabling caching </b> </p> <p>You can disable caching altogether by setting a cache size of 0 in centrep.ini </p> <codeblock id="GUID-6E8A8BFF-2A6D-52B7-B833-CDC5261D0983" xml:space="preserve">
[CoarseGrainedCache]
size= 0
timeout= 0
</codeblock> </section> <section><title>Backup</title> <p>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. </p> </section> </conbody><related-links><link href="GUID-1C683226-C142-5C7B-BD20-060058352B08.dita"><linktext>Central Repository Guide</linktext> </link> <link href="GUID-E87018CD-01B4-5886-87FC-CD25EE90587D.dita"><linktext>Central Repository
                Transactions</linktext> </link> <link href="GUID-998DCA78-2488-5D6D-B5B3-D86C52F32823.dita"><linktext>Modifications to
                Keyspaces</linktext> </link> </related-links></concept>