📄 config_8h-source.html
字号:
00108 <span class="comment">// in a separate thread. In this case commit will not be blocked until all changes will be actually written to the disk,</span>
00109 <span class="comment">// write requests will be just linked into the queue from which them will be taken by writting thread and proceeded</span>
00110 <span class="comment">// in the same order as in commit. This apporach provides daatbase consistency in case of fault, but results</span>
00111 <span class="comment">// of several recently committed transaction can be lost in this case.</span>
00112 <span class="comment">// Fuzzy checkpointing works only in conjunction with NO_MMAP option, it means that data sharing is not allowed</span>
00113 <span class="comment">// in this case - database can be accessed only by one application.</span>
00114 <span class="comment">//#define FUZZY_CHECKPOINT 1</span>
00115
00116
00117 <span class="comment">//USE_MFC - use MFC (include "afx.h" instead of "windows.h")</span>
00118 <span class="comment">//#define USE_MFC 1</span>
00119
00120 <span class="comment">//USE_ATL - use Microsoft ATL </span>
00121 <span class="comment">//#define USE_ATL 1</span>
00122
00123 <span class="comment">// Do not use member templates</span>
00124 <span class="preprocessor">#if defined(__SUNPRO_CC_COMPAT) && __SUNPRO_CC_COMPAT == 4</span>
00125 <span class="preprocessor"></span><span class="preprocessor">#define NO_MEMBER_TEMPLATES</span>
00126 <span class="preprocessor"></span><span class="preprocessor">#endif</span>
00127 <span class="preprocessor"></span>
00128 <span class="comment">// Automatically detect and recover crash of one or more database clients.</span>
00129 <span class="comment">// FastDB will start separate watchdog threads which will check if other processes working with database are </span>
00130 <span class="comment">// alive.</span>
00131 <span class="comment">// It is not recommended to use this mode because there are many cases whern it works incorrectly.</span>
00132 <span class="comment">// Preferable way of handling process failure is using of RECOVERABLE_CRITICAL_SECTION.</span>
00133 <span class="comment">//#define AUTO_DETECT_PROCESS_CRASH 1</span>
00134
00135 <span class="comment">// Use recoverable critical section (operating system is able to release </span>
00136 <span class="comment">// critical section in case of crash of the process entered this critical section)</span>
00137 <span class="comment">//#define RECOVERABLE_CRITICAL_SECTION 1</span>
00138
00139 <span class="comment">// Do not flush chafges to the disk during transaction commit. This option will greatly increase performance</span>
00140 <span class="comment">// but can cause database corruption in case of crash</span>
00141 <span class="comment">//#define NO_FLUSH_ON_COMMIT 1</span>
00142
00143 <span class="comment">// dbDatabaseOidBits number of bits used to represent object identifier. </span>
00144 <span class="comment">// So the number of objects in database is limited by 2**dbDatabaseOidBits.</span>
00145 <span class="comment">// Default value of this parameter is 32, so maximal number of objects is limited by 2**32.</span>
00146 <span class="comment">// Support of larger number of objects is possible only at 64-bit OS</span>
00147 <span class="comment">// The value of this parameter is used to estimate size of bitmap, so do not assign unnecessarily </span>
00148 <span class="comment">// large values (for example 64)</span>
00149 <span class="comment">//#define dbDatabaseOidBits 33</span>
00150
00151 <span class="comment">// dbDatabaseOffsetBits number of bits used to represent object offset in the storage</span>
00152 <span class="comment">// So the maximal database size is limited by 2**dbDatabaseOidBits.</span>
00153 <span class="comment">// Default value of this parameter is 32, so maximal number of objects is limited by 2**32.</span>
00154 <span class="comment">// Support of larger database size only at 64-bit OS</span>
00155 <span class="comment">// The value of this parameter is used to estimate size of bitmap, so do not assign unnecessarily </span>
00156 <span class="comment">// large values (for example 64)</span>
00157 <span class="comment">//#define dbDatabaseOffsetBits 38</span>
00158
00159 <span class="comment">// USE_REGEX - use regex library. When this macro is defined GigaBASE provides</span>
00160 <span class="comment">// MATCH command. GNU regex or compatible library and headers should be available.</span>
00161 <span class="comment">//#define USE_REGEX true</span>
00162
00163 <span class="comment">// Calling convention used for CLI callback functions</span>
00164 <span class="comment">// You should use stdcall convention if you want to use CSharp CLI API</span>
00165 <span class="comment">//#define CLI_CALLBACK_CC __stdcall</span>
00166
00167 <span class="comment">// SOCK_LINGER - set SO_LINGER option. Value of SO_LINGER is specified using LINGER_TIME</span>
00168 <span class="comment">// #define SOCK_LINGER 1</span>
00169
00170
00171 <span class="comment">// Use reentrant version of localtime</span>
00172 <span class="preprocessor">#if !defined(__APPLE__) && !defined(_WIN32)</span>
00173 <span class="preprocessor"></span><span class="preprocessor">#define HAVE_LOCALTIME_R</span>
00174 <span class="preprocessor"></span><span class="preprocessor">#endif</span>
00175 <span class="preprocessor"></span>
00176 <span class="comment">// Use reentrant version of localtime</span>
00177 <span class="preprocessor">#if !defined(__APPLE__) && !defined(_WIN32) && !defined(_AIX)</span>
00178 <span class="preprocessor"></span><span class="preprocessor">#define HAVE_GETHOSTBYNAME_R</span>
00179 <span class="preprocessor"></span><span class="preprocessor">#endif</span>
00180 <span class="preprocessor"></span>
00181 <span class="comment">// Protect replica from unintended access (data corruption)</span>
00182 <span class="comment">//#define PROTECT_DATABASE 1</span>
00183
00184 <span class="comment">// Wait acknowledgment that transaction is delivered to all slave nodes</span>
00185 <span class="comment">//#define SYNCHRONOUS_REPLICATION true</span>
00186
00187 <span class="comment">// PAD_HEADER - add pad field to the database header to make it possible to transfer </span>
00188 <span class="comment">// file between systems with different alignment rules</span>
00189 <span class="comment">// This pad field was unconditionally inserted in database header in 3.17 version</span>
00190 <span class="comment">// of Perst which breaks backward compatibility. Because of the customers concerns</span>
00191 <span class="comment">// in 3.39 version of Perst the "pad" field was wrapped with the following condition</span>
00192 <span class="comment">// #if dbDatabaseOffsetBits > 32 && defined(ALIGN_HEADER)</span>
00193 <span class="comment">// which in turn breaks compatibility with database created with 3.17-3.38 versions.</span>
00194 <span class="comment">// Finally in 3.44 the condition was repalced with </span>
00195 <span class="comment">// #if (dbDatabaseOffsetBits > 32 && defined(ALIGN_HEADER)) || defined(PAD_HEADER)</span>
00196 <span class="comment">// So you should uncomment definition of PAD_HEADER to preserve compatibility with databases </span>
00197 <span class="comment">// created by FastDB versions 3.17-3.38.</span>
00198 <span class="comment">//#define PAD_HEADER</span>
00199
00200 <span class="comment">// ALIGN_HEADER - align each field of dbHeader class on its page boudary</span>
00201 <span class="comment">// to make it possible to transfer file between systems with different alignment rules</span>
00202 <span class="comment">//#define ALIGN_HEADER true</span>
00203
00204 <span class="comment">// DO_NOT_REUSE_OID_WITHIN_SESSION - do not reuse OID of deallocated objects in the current session</span>
00205 <span class="comment">//#define DO_NOT_REUSE_OID_WITHIN_SESSION true</span>
00206
00207
00208 <span class="comment">// Use Doug Lea version of malloc instead of standard malloc</span>
00209 <span class="comment">//#define USE_DLMALLOC true</span>
00210
00211 <span class="comment">// Invoke dbDatabase::handleError instead of assert for internal errors.</span>
00212 <span class="comment">// #define HANDLE_ASSERTION_FAILURES</span>
00213
00214 <span class="preprocessor">#endif</span>
00215 <span class="preprocessor"></span>
</pre></div><hr><address style="align: right;"><small>Generated on Thu Feb 14 12:42:30 2008 for FastDB by
<a href="http://www.doxygen.org/index.html">
<img src="doxygen.png" alt="doxygen" align="middle" border=0
width=110 height=53></a>1.2.18 </small></address>
</body>
</html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -