Completed
Push — master ( 2472c5...a814e8 )
by mw
35:03
created

DefaultSettings.php (28 issues)

Upgrade to new PHP Analysis Engine

These results are based on our legacy PHP analysis, consider migrating to our new PHP analysis engine instead. Learn more

1
<?php
2
3
/**
4
 * DO NOT EDIT!
5
 *
6
 * The following default settings are to be used by the extension itself,
7
 * please modify settings in the LocalSettings file.
8
 *
9
 * Most settings should be make  between including this file and the call
10
 * to enableSemantics(). Exceptions that need to be set before are
11
 * documented below.
12
 *
13
 * @codeCoverageIgnore
14
 */
15
if ( !defined( 'MEDIAWIKI' ) ) {
16
  die( "This file is part of the Semantic MediaWiki extension. It is not a valid entry point.\n" );
17
}
18
19
return array(
20
21
	###
22
	# This is the path to your installation of Semantic MediaWiki as seen on your
23
	# local filesystem. Used against some PHP file path issues.
24
	# If needed, you can also change this path in LocalSettings.php after including
25
	# this file.
26
	##
27
	'smwgIP' => dirname( __FILE__ ) . '/',
28
	'smwgExtraneousLanguageFileDir' => __DIR__ . '/i18n/extra',
29
	##
30
31
	###
32
	# Semantic MediaWiki's operational state
33
	#
34
	# It is expected that enableSemantics() is used to enable SMW otherwise it is
35
	# disabled by default. disableSemantics() will also set the state to disabled.
36
	#
37
	# @since 2.4
38
	##
39
	'smwgSemanticsEnabled' => false,
40
	##
41
42
	###
43
	# Use another storage backend for Semantic MediaWiki. The default is suitable
44
	# for most uses of SMW.
45
	##
46
	'smwgDefaultStore' => "SMWSQLStore3",
47
	##
48
49
	###
50
	# Configure SPARQL database connection for Semantic MediaWiki. This is used
51
	# when SPARQL-based features are enabled, e.g. when using SMWSparqlStore as
52
	# the $smwgDefaultStore.
53
	#
54
	# The default class SMWSparqlDatabase works with many databases that support
55
	# SPARQL and SPARQL Update. Three different endpoints (service URLs) are given
56
	# for query (reading queries like SELECT), update (SPARQL Update queries), and
57
	# data (SPARQL HTTP Protocol for Graph Management). The query endpoint is
58
	# necessary, but the update and data endpoints can be omitted if not supported.
59
	# This will lead to reduced functionality (e.g. the SMWSparqlStore will not
60
	# work if Update is not available). The data endpoint is always optional, but
61
	# in some SPARQL databases this method is more efficient than update.
62
	#
63
	# The default graph is similar to a database name in relational databases. It
64
	# can be set to any URI (e.g. the main page uri of your wiki with
65
	# "	#graph" appended). Leaving the default graph URI empty only works if the
66
	# store is configure to use some default default graph or if it generally
67
	# supports this. Different wikis should normally use different default graphs
68
	# unless there is a good reason to share one graph.
69
	##
70
	'smwgSparqlDatabase' => 'SMWSparqlDatabase',
71
	'smwgSparqlQueryEndpoint' => 'http://localhost:8080/sparql/',
72
	'smwgSparqlUpdateEndpoint' => 'http://localhost:8080/update/',
73
	'smwgSparqlDataEndpoint' => 'http://localhost:8080/data/',
74
	'smwgSparqlDefaultGraph' => '',
75
	##
76
77
	##
78
	# SparqlDBConnectionProvider
79
	#
80
	# Identifies a database connector that ought to be used together with the
81
	# SPARQLStore
82
	#
83
	# List of standard connectors ($smwgSparqlDatabase will have no effect)
84
	# - 'fuseki'
85
	# - 'virtuoso'
86
	# - '4store'
87
	# - 'sesame'
88
	# - 'generic'
89
	#
90
	# With 2.0 it is suggested to assign the necessary connector to
91
	# $smwgSparqlDatabaseConnector in order to avoid arbitrary class assignments in
92
	# $smwgSparqlDatabase (which can change in future releases without further notice).
93
	#
94
	# In case $smwgSparqlDatabaseConnector = 'custom' is maintained, $smwgSparqlDatabase
95
	# is expected to contain a custom class connector where $smwgSparqlDatabase is only
96
	# to be sued for when a custom database connector is necessary.
97
	#
98
	# $smwgSparqlDatabaseConnector = 'custom' is set as legacy configuration to allow for
99
	# existing (prior 2.0) customizing to work without changes.
100
	#
101
	# @since 2.0
102
	##
103
	'smwgSparqlDatabaseConnector' => 'custom',
104
	##
105
106
	##
107
	# Sparql query features that are expected to be supported by the repository:
108
	#
109
	# - SMW_SPARQL_QF_NONE does not support any features (as required by SPARQL 1.1)
110
	# - SMW_SPARQL_QF_REDI to support finding redirects using inverse property paths,
111
	#   can only be used for repositories with full SPARQL 1.1 support (e.g. Fuseki,
112
	#   Sesame)
113
	# - SMW_SPARQL_QF_SUBP to resolve subproperties
114
	# - SMW_SPARQL_QF_SUBC to resolve subcategories
115
	#
116
	# Please check with your repository provider whether SPARQL 1.1 is fully
117
	# supported or not, and if not SMW_SPARQL_QF_NONE should be set.
118
	#
119
	# @since 2.3
120
	##
121
	'smwgSparqlQFeatures' => SMW_SPARQL_QF_REDI | SMW_SPARQL_QF_SUBP | SMW_SPARQL_QF_SUBC,
122
	##
123
124
	##
125
	# @see https://github.com/SemanticMediaWiki/SemanticMediaWiki/issues/1306
126
	#
127
	# Setting to explicitly force a CURLOPT_HTTP_VERSION for the endpoint communication
128
	# and should not be changed unless an error as in 	#1306 was encountered.
129
	#
130
	# @see http://curl.haxx.se/libcurl/c/CURLOPT_HTTP_VERSION.html reads "... libcurl
131
	# to use the specific HTTP versions. This is not sensible to do unless you have
132
	# a good reason.""
133
	#
134
	# @since 2.3
135
	# @default false === means to use the default as determined by cURL
136
	##
137
	'smwgSparqlRepositoryConnectorForcedHttpVersion' => false,
138
	##
139
140
	###
141
	# Setting this option to true before including this file to enable the old
142
	# Type: namespace that SMW used up to version 1.5.*. This should only be
143
	# done to make the pages of this namespace temporarily accessible in order to
144
	# move their content to other pages. If the namespace is not registered, then
145
	# existing pages in this namespace cannot be found in the wiki.
146
	##
147
	'smwgHistoricTypeNamespace' => false,
148
	##
149
150
	###
151
	# If you already have custom namespaces on your site, insert
152
	#    	'smwgNamespaceIndex' => ???,
0 ignored issues
show
Unused Code Comprehensibility introduced by
67% of this comment could be valid code. Did you maybe forget this after debugging?

Sometimes obsolete code just ends up commented out instead of removed. In this case it is better to remove the code once you have checked you do not need it.

The code might also have been commented out for debugging purposes. In this case it is vital that someone uncomments it again or your project may behave in very unexpected ways in production.

This check looks for comments that seem to be mostly valid code and reports them.

Loading history...
153
	# into your LocalSettings.php *before* including this file. The number ??? must
154
	# be the smallest even namespace number that is not in use yet. However, it
155
	# must not be smaller than 100.
156
	##
157
158
	###
159
	# Overwriting the following array, you can define for which namespaces
160
	# the semantic links and annotations are to be evaluated. On other
161
	# pages, annotations can be given but are silently ignored. This is
162
	# useful since, e.g., talk pages usually do not have attributes and
163
	# the like. In fact, is is not obvious what a meaningful attribute of
164
	# a talk page could be. Pages without annotations will also be ignored
165
	# during full RDF export, unless they are referred to from another
166
	# article.
167
	##
168
	'smwgNamespacesWithSemanticLinks' => array(
169
		NS_MAIN => true,
170
		NS_TALK => false,
171
		NS_USER => true,
172
		NS_USER_TALK => false,
173
		NS_PROJECT => true,
174
		NS_PROJECT_TALK => false,
175
		NS_IMAGE => true,
176
		NS_IMAGE_TALK => false,
177
		NS_MEDIAWIKI => false,
178
		NS_MEDIAWIKI_TALK => false,
179
		NS_TEMPLATE => false,
180
		NS_TEMPLATE_TALK => false,
181
		NS_HELP => true,
182
		NS_HELP_TALK => false,
183
		NS_CATEGORY => true,
184
		NS_CATEGORY_TALK => false,
185
	),
186
	##
187
188
	###
189
	# This setting allows you to select in which cases you want to have a factbox
190
	# appear below an article. Note that the Magic Words __SHOWFACTBOX__ and
191
	# __HIDEFACTBOX__ can be used to control Factbox display for individual pages.
192
	# Other options for this setting include:
193
	##
194
	// 	'smwgShowFactbox' => SMW_FACTBOX_NONEMPTY, 	# show only those factboxes that have some content
0 ignored issues
show
Unused Code Comprehensibility introduced by
38% of this comment could be valid code. Did you maybe forget this after debugging?

Sometimes obsolete code just ends up commented out instead of removed. In this case it is better to remove the code once you have checked you do not need it.

The code might also have been commented out for debugging purposes. In this case it is vital that someone uncomments it again or your project may behave in very unexpected ways in production.

This check looks for comments that seem to be mostly valid code and reports them.

Loading history...
195
	// 	'smwgShowFactbox' => SMW_FACTBOX_SPECIAL 	# show only if special properties were set
196
	'smwgShowFactbox' => SMW_FACTBOX_HIDDEN, 	# hide always
197
	// 	'smwgShowFactbox' => SMW_FACTBOX_SHOWN,  	# show always, buggy and not recommended
0 ignored issues
show
Unused Code Comprehensibility introduced by
38% of this comment could be valid code. Did you maybe forget this after debugging?

Sometimes obsolete code just ends up commented out instead of removed. In this case it is better to remove the code once you have checked you do not need it.

The code might also have been commented out for debugging purposes. In this case it is vital that someone uncomments it again or your project may behave in very unexpected ways in production.

This check looks for comments that seem to be mostly valid code and reports them.

Loading history...
198
	##
199
200
	###
201
	# Same as $smwgShowFactbox but for edit mode and same possible values.
202
	##
203
	'smwgShowFactboxEdit' => SMW_FACTBOX_NONEMPTY,
204
	##
205
206
	###
207
	# Should the toolbox of each content page show a link to browse the properties
208
	# of that page using Special:Browse? This is a useful way to access properties
209
	# and it is somewhat more subtle than showing a Factbox on every page.
210
	##
211
	'smwgToolboxBrowseLink' => true,
212
	##
213
214
	###
215
	# Should warnings be displayed in wikitexts right after the problematic input?
216
	# This affects only semantic annotations, not warnings that are displayed by
217
	# inline queries or other features.
218
	##
219
	'smwgInlineErrors' => true,
220
	##
221
222
	###
223
	# Should SMW consider MediaWiki's subcategory hierarchy in querying? If set to
224
	# true, subcategories will always be interpreted like subclasses. For example,
225
	# if A is a subcategory of B then a query for all elements of B will also yield
226
	# all elements of A. If this setting is disabled, then subclass relationships
227
	# can still be given explicitly by using the property "subcategory of" on some
228
	# category page. Only if the setting is false will such annotations be shown in
229
	# the factbox (if enabled).
230
	##
231
	'smwgUseCategoryHierarchy' => true,
232
	##
233
234
	###
235
	# Should category pages that use some [[Category:Foo]] statement be treated as
236
	# elements of the category Foo? If disabled, then it is not possible to make
237
	# category pages elements of other categories. See also the above setting
238
	# $smwgUseCategoryHierarchy.
239
	##
240
	'smwgCategoriesAsInstances' => true,
241
	##
242
243
	###
244
	# Should SMW accept inputs like [[property::Some [[link]] in value]]? If
0 ignored issues
show
Unused Code Comprehensibility introduced by
36% of this comment could be valid code. Did you maybe forget this after debugging?

Sometimes obsolete code just ends up commented out instead of removed. In this case it is better to remove the code once you have checked you do not need it.

The code might also have been commented out for debugging purposes. In this case it is vital that someone uncomments it again or your project may behave in very unexpected ways in production.

This check looks for comments that seem to be mostly valid code and reports them.

Loading history...
245
	# enabled, this may lead to PHP crashes (!) when very long texts are used as
246
	# values. This is due to limitations in the library PCRE that PHP uses for
247
	# pattern matching. The provoked PHP crashes will prevent requests from being
248
	# completed -- usually clients will receive server errors ("invalid response")
249
	# or be offered to download "index.php". It might be okay to enable this if
250
	# such problems are not observed in your wiki.
251
	##
252
	'smwgLinksInValues' => false,
253
	##
254
255
	###
256
	# Settings for recurring events, created with the 	#set_recurring_event parser
257
	# function: the default number of instances defined, if no end date is set,
258
	# and the maximum number that can be defined, regardless of end date.
259
	##
260
	'smwgDefaultNumRecurringEvents' => 100,
261
	'smwgMaxNumRecurringEvents' => 500,
262
	##
263
264
	###
265
	# Should the browse view for incoming links show the incoming links via its
266
	# inverses, or shall they be displayed on the other side?
267
	##
268
	'smwgBrowseShowInverse' => false,
269
	##
270
271
	###
272
	# Should the browse view always show the incoming links as well, and more of
273
	# the incoming values?
274
	##
275
	'smwgBrowseShowAll' => true,
276
	##
277
278
	###
279
	# Whether the browse display is to be generated using an API request or not.
280
	##
281
	'smwgBrowseByApi' => true,
282
	##
283
284
	###
285
	# Should the search by property special page display nearby results when there
286
	# are only a few results with the exact value? Switch this off if this page has
287
	# performance problems.
288
	#
289
	# @since 2.1 enabled default types, to disable the functionality either set the
290
	# variable to array() or false
0 ignored issues
show
Unused Code Comprehensibility introduced by
42% of this comment could be valid code. Did you maybe forget this after debugging?

Sometimes obsolete code just ends up commented out instead of removed. In this case it is better to remove the code once you have checked you do not need it.

The code might also have been commented out for debugging purposes. In this case it is vital that someone uncomments it again or your project may behave in very unexpected ways in production.

This check looks for comments that seem to be mostly valid code and reports them.

Loading history...
291
	##
292
	'smwgSearchByPropertyFuzzy' => array( '_num', '_txt', '_dat', '_mlt_rec' ),
293
	##
294
295
	###
296
	# Number results shown in the listings on pages in the namespaces Property,
297
	# Type, and Concept. If a value of 0 is given, the respective listings are
298
	# hidden completely.
299
	##
300
	'smwgTypePagingLimit' => 200,   // same number as for categories
301
	'smwgConceptPagingLimit' => 200, // same number as for categories
302
	'smwgPropertyPagingLimit' => 25, // use smaller value since property lists need more space
303
	##
304
305
	###
306
	# How many values should at most be displayed for a page on the Property page?
307
	##
308
	'smwgMaxPropertyValues' => 3, // if large values are desired, consider reducing $smwgPropertyPagingLimit for better performance
309
	'smwgSubPropertyListLimit' => 25, // property page to limit the query request on subproperties
310
	##
311
312
	###
313
	# Settings for inline queries ({{	#ask:...}}) and for semantic queries in
314
	# general. This can especially be used to prevent overly high server-load due
315
	# to complex queries. The following settings affect all queries, wherever they
316
	# occur.
317
	##
318
	'smwgQEnabled' => true,   // (De)activates all query related features and interfaces
319
	'smwgQMaxLimit' => 10000, // Max number of results *ever* retrieved, even when using special query pages.
320
	'smwgIgnoreQueryErrors' => true, // Should queries be executed even if some errors were detected?
321
										// A hint that points out errors is shown in any case.
322
323
	'smwgQSubcategoryDepth' => 10,  // Restrict level of sub-category inclusion (steps within category hierarchy)
324
	'smwgQSubpropertyDepth' => 10,  // Restrict level of sub-property inclusion (steps within property hierarchy)
325
										// (Use 0 to disable hierarchy-inferencing in queries)
326
	'smwgQEqualitySupport' => SMW_EQ_SOME, // Evaluate 	#redirects as equality between page names, with possible
327
												// performance-relevant restrictions depending on the storage engine
328
	// 	'smwgQEqualitySupport' => SMW_EQ_FULL, // Evaluate 	#redirects as equality between page names in all cases
0 ignored issues
show
Unused Code Comprehensibility introduced by
38% of this comment could be valid code. Did you maybe forget this after debugging?

Sometimes obsolete code just ends up commented out instead of removed. In this case it is better to remove the code once you have checked you do not need it.

The code might also have been commented out for debugging purposes. In this case it is vital that someone uncomments it again or your project may behave in very unexpected ways in production.

This check looks for comments that seem to be mostly valid code and reports them.

Loading history...
329
	// 	'smwgQEqualitySupport' => SMW_EQ_NONE, // Never evaluate 	#redirects as equality between page names
330
	'smwgQSortingSupport' => true, // (De)activate sorting of results.
331
	'smwgQRandSortingSupport' => true, // (De)activate random sorting of results.
332
	'smwgQDefaultNamespaces' => null, // Which namespaces should be searched by default?
333
										// (value NULL switches off default restrictions on searching -- this is faster)
334
										// Example with namespaces: 	'smwgQDefaultNamespaces' => array(NS_MAIN, NS_IMAGE),
335
336
	###
337
	# List of comparator characters supported by queries, separated by '|', for use in a regex.
338
	#
339
	# Available entries:
340
	#  	< (smaller than) if $smwStrictComparators is false, it's actually smaller than or equal to
341
	#  	> (greater than) if $smwStrictComparators is false, it's actually bigger than or equal to
342
	#  	! (unequal to)
0 ignored issues
show
Unused Code Comprehensibility introduced by
38% of this comment could be valid code. Did you maybe forget this after debugging?

Sometimes obsolete code just ends up commented out instead of removed. In this case it is better to remove the code once you have checked you do not need it.

The code might also have been commented out for debugging purposes. In this case it is vital that someone uncomments it again or your project may behave in very unexpected ways in production.

This check looks for comments that seem to be mostly valid code and reports them.

Loading history...
343
	#  	~ (pattern with '*' as wildcard, only for Type:String)
344
	#  	!~ (not a pattern with '*' as wildcard, only for Type:String, need to be placed before ! and ~ to work correctly)
345
	#  	≤ (smaller than or equal to)
346
	#  	≥ (greater than or equal to)
347
	#
348
	# If unsupported comparators are used, they are treated as part of the queried value
349
	#
350
	##
351
	'smwgQComparators' => '<|>|!~|!|~|≤|≥|<<|>>',
352
	##
353
354
	###
355
	# Sets whether the > and < comparators should be strict or not. If they are strict,
356
	# values that are equal will not be accepted.
357
	##
358
	'smwStrictComparators' => false,
359
360
	// To be used starting with 3.x (due to misspelling)
361
	'smwgStrictComparators' => false,
362
	##
363
364
	###
365
	# Further settings for queries. The following settings affect inline queries
366
	# and querying special pages. Essentially they should mirror the kind of
367
	# queries that should immediately be answered by the wiki, using whatever
368
	# computations are needed.
369
	##
370
	'smwgQMaxSize' => 16, // Maximal number of conditions in queries, use format=debug for example sizes
371
	'smwgQMaxDepth' => 4, // Maximal property depth of queries, e.g. [[rel::<q>[[rel2::Test]]</q>]] has depth 2
372
	##
373
374
	### The below setting defines which query features should be available by default.
375
	# Examples:
376
	# only cateory intersections: 	'smwgQFeatures' => SMW_CATEGORY_QUERY | SMW_CONJUNCTION_QUERY,
377
	# only single concepts:       	'smwgQFeatures' => SMW_CONCEPT_QUERY,
378
	# anything but disjunctions:  	'smwgQFeatures' => SMW_ANY_QUERY & ~SMW_DISJUNCTION_QUERY,
379
	# The default is to support all basic features.
380
	##
381
	'smwgQFeatures' => SMW_PROPERTY_QUERY | SMW_CATEGORY_QUERY | SMW_CONCEPT_QUERY | SMW_NAMESPACE_QUERY | SMW_CONJUNCTION_QUERY | SMW_DISJUNCTION_QUERY,
382
	##
383
384
	###
385
	# Settings about printout of (especially inline) queries:
386
	##
387
	'smwgQDefaultLimit' => 50,      // Default number of rows returned in a query. Can be increased with limit=num in 	#ask
388
	'smwgQMaxInlineLimit' => 500,   // Max number of rows ever printed in a single inline query on a single page.
389
	'smwgQUpperbound' => 5000,      // Max number of rows ever printed in a single inline query on a single page.
390
	'smwgQPrintoutLimit'  => 100,   // Max number of supported printouts (added columns in result table, ?-statements)
391
	'smwgQDefaultLinking' => 'all', // Default linking behavior. Can be one of "none", "subject" (first column), "all".
392
	##
393
394
	###
395
	# Further settings for queries. The following settings affect queries that are
396
	# part of concept pages. These are usually chosen to be les restricted than
397
	# inline queries, since there are two other means for controling their use:
398
	# (1) Concept queries that would not be allowed as normal queries will not be
399
	# executed directly, but can use pre-computed results instead. This is the
400
	# default.
401
	# (2) The whole Concept: namespace can be restricted (using some suitable
402
	# MediaWiki extension) to an experienced user group that may create more
403
	# complex queries responably. Other users can employ thus defined concepts in
404
	# their queries.
405
	##
406
	'smwgQConceptCaching' => CONCEPT_CACHE_HARD, // Which concepts should be displayed only if available from cache?
407
		// CONCEPT_CACHE_ALL   -- show concept elements anywhere only if they are cached
408
		// CONCEPT_CACHE_HARD  -- show without cache if concept is not harder than permitted inline queries
409
		// CONCEPT_CACHE_NONE  -- show all concepts even without any cache
410
		// In any cases, caches will always be used if available.
411
	'smwgQConceptMaxSize' => 20, // Same as $smwgQMaxSize, but for concepts
412
	'smwgQConceptMaxDepth' => 8, // Same as $smwgQMaxDepth, but for concepts
413
414
	// Same as $smwgQFeatures but for concepts
415
	'smwgQConceptFeatures' => SMW_PROPERTY_QUERY | SMW_CATEGORY_QUERY | SMW_NAMESPACE_QUERY |
416
								SMW_CONJUNCTION_QUERY | SMW_DISJUNCTION_QUERY | SMW_CONCEPT_QUERY,
417
418
	// Cache life time in minutes. If a concept cache exists but is older than
419
	// this, SMW tries to recompute it, and will only use the cache if this is not
420
	// allowed due to settings above:
421
	'smwgQConceptCacheLifetime' => 24 * 60,
422
	##
423
424
	### Predefined result formats for queries
425
	# Array of available formats for formatting queries. Can be redefined in
426
	# the settings to disallow certain formats or to register extension formats.
427
	# To disable a format, do "unset($smwgResultFormats['template'])," Disabled
428
	# formats will be treated like if the format parameter had been omitted. The
429
	# formats 'table' and 'list' are defaults that cannot be disabled. The format
430
	# 'broadtable' should not be disabled either in order not to break Special:ask.
431
	##
432
	'smwgResultFormats' => array(
433
		'table'      => 'SMW\TableResultPrinter',
434
		'list'       => 'SMW\ListResultPrinter',
435
		'ol'         => 'SMW\ListResultPrinter',
436
		'ul'         => 'SMW\ListResultPrinter',
437
		'broadtable' => 'SMW\TableResultPrinter',
438
		'category'   => 'SMW\CategoryResultPrinter',
439
		'embedded'   => 'SMW\EmbeddedResultPrinter',
440
		'template'   => 'SMW\ListResultPrinter',
441
		'count'      => 'SMW\ListResultPrinter',
442
		'debug'      => 'SMW\ListResultPrinter',
443
		'feed'       => 'SMW\FeedResultPrinter',
444
		'csv'        => 'SMW\CsvResultPrinter',
445
		'dsv'        => 'SMW\DsvResultPrinter',
446
		'json'       => 'SMW\JsonResultPrinter',
447
		'rdf'        => 'SMW\RdfResultPrinter'
448
	),
449
	##
450
451
	### Predefined aliases for result formats
452
	# Array of available aliases for result formats. Can be redefined in
453
	# the settings to disallow certain aliases or to register extension aliases.
454
	# To disable an alias, do "unset($smwgResultAliases['alias'])," Disabled
455
	# aliases will be treated like if the alias parameter had been omitted.
456
	##
457
	'smwgResultAliases' => array( 'feed' => array( 'rss' ) ),
458
	##
459
460
	### Predefined sources for queries
461
	# Array of available sources for answering queries. Can be redefined in
462
	# the settings to register new sources (usually an extension will do so
463
	# on installation). Unknown source will be rerouted to the local wiki.
464
	# Note that the basic installation comes with no additional source besides
465
	# the local source (which in turn cannot be disabled or set explicitly).
466
	# Set a new store like this: $smwgQuerySources['freebase' => "SMWFreebaseStore",
467
	##
468
	'smwgQuerySources' => array(
469
	//	'local'      => '',
470
	),
471
	##
472
473
	### Default property type
474
	# Undefined properties (those without pages or whose pages have no "has type"
475
	# statement) will be assumed to be of this type. This is an internal type id.
476
	# See the file languages/SMW_LanguageXX.php to find what IDs to use for
477
	# datatpyes in your language. The default corresponds to "Type:Page".
478
	##
479
	'smwgPDefaultType' => '_wpg',
480
	##
481
482
	###
483
	# Settings for OWL/RDF export
484
	##
485
	'smwgAllowRecursiveExport' => false, // can normal users request recursive export?
486
	'smwgExportBacklinks' => true, // should backlinks be included by default?
487
	// global $smwgNamespace,                     // The Namespace of exported URIs.
0 ignored issues
show
Unused Code Comprehensibility introduced by
50% of this comment could be valid code. Did you maybe forget this after debugging?

Sometimes obsolete code just ends up commented out instead of removed. In this case it is better to remove the code once you have checked you do not need it.

The code might also have been commented out for debugging purposes. In this case it is vital that someone uncomments it again or your project may behave in very unexpected ways in production.

This check looks for comments that seem to be mostly valid code and reports them.

Loading history...
488
	// 	'smwgNamespace' => "http://example.org/id/", // Will be set automatically if
0 ignored issues
show
Unused Code Comprehensibility introduced by
50% of this comment could be valid code. Did you maybe forget this after debugging?

Sometimes obsolete code just ends up commented out instead of removed. In this case it is better to remove the code once you have checked you do not need it.

The code might also have been commented out for debugging purposes. In this case it is vital that someone uncomments it again or your project may behave in very unexpected ways in production.

This check looks for comments that seem to be mostly valid code and reports them.

Loading history...
489
	// nothing is given, but in order to make pretty URIs you will need to set this
490
	// to something nice and adapt your Apache configuration appropriately. This is
491
	// done, e.g., on semanticweb.org, where URIs are of the form
492
	// http://semanticweb.org/id/FOAF
493
	##
494
495
	###
496
	# The maximal number that SMW will normally display without using scientific exp
497
	# notation. The deafult is rather large since some users have problems understanding
498
	# exponents. Scineitfic applications may prefer a smaller value for concise display.
499
	##
500
	'smwgMaxNonExpNumber' => 1000000000000000,
501
	##
502
503
	###
504
	# SMW defers some tasks until after a page was edited by using the MediaWiki
505
	# job queueing system (see http://www.mediawiki.org/wiki/Manual:Job_queue).
506
	# For example, when the type of a property is changed, all affected pages will
507
	# be scheduled for (later) update. If a wiki generates too many jobs in this
508
	# way (Special:Statistics and "showJobs.php" can be used to check that), the
509
	# following setting can be used to disable jobs. Note that this will cause some
510
	# parts of the semantic data to get out of date, so that manual modifications
511
	# or the use of SMW_refreshData.php might be needed.
512
	##
513
	'smwgEnableUpdateJobs' => true,
514
	##
515
516
	### List of enabled special page properties.
517
	# Modification date (_MDAT) is enabled by default for backward compatibility.
518
	# Extend array to enable other properties:
519
	#     $smwgPageSpecialProperties[ => '_CDAT',
0 ignored issues
show
Unused Code Comprehensibility introduced by
63% of this comment could be valid code. Did you maybe forget this after debugging?

Sometimes obsolete code just ends up commented out instead of removed. In this case it is better to remove the code once you have checked you do not need it.

The code might also have been commented out for debugging purposes. In this case it is vital that someone uncomments it again or your project may behave in very unexpected ways in production.

This check looks for comments that seem to be mostly valid code and reports them.

Loading history...
520
	# Or:
521
	#     array_merge( $smwgPageSpecialProperties, array( '_CDAT' ) ),
0 ignored issues
show
Unused Code Comprehensibility introduced by
57% of this comment could be valid code. Did you maybe forget this after debugging?

Sometimes obsolete code just ends up commented out instead of removed. In this case it is better to remove the code once you have checked you do not need it.

The code might also have been commented out for debugging purposes. In this case it is vital that someone uncomments it again or your project may behave in very unexpected ways in production.

This check looks for comments that seem to be mostly valid code and reports them.

Loading history...
522
	# Or rewrite entire array:
523
	#     	'smwgPageSpecialProperties' => array( '_MDAT', '_CDAT' ),
0 ignored issues
show
Unused Code Comprehensibility introduced by
54% of this comment could be valid code. Did you maybe forget this after debugging?

Sometimes obsolete code just ends up commented out instead of removed. In this case it is better to remove the code once you have checked you do not need it.

The code might also have been commented out for debugging purposes. In this case it is vital that someone uncomments it again or your project may behave in very unexpected ways in production.

This check looks for comments that seem to be mostly valid code and reports them.

Loading history...
524
	# However, DO NOT use `+=' operator! This DOES NOT work:
525
	#     $smwgPageSpecialProperties += array( '_MDAT' ),
0 ignored issues
show
Unused Code Comprehensibility introduced by
47% of this comment could be valid code. Did you maybe forget this after debugging?

Sometimes obsolete code just ends up commented out instead of removed. In this case it is better to remove the code once you have checked you do not need it.

The code might also have been commented out for debugging purposes. In this case it is vital that someone uncomments it again or your project may behave in very unexpected ways in production.

This check looks for comments that seem to be mostly valid code and reports them.

Loading history...
526
	##
527
	'smwgPageSpecialProperties' => array( '_MDAT' ),
528
	##
529
530
	###
531
	# Properties (usually given as internal ids or DB key versions of property
532
	# titles) that are relevant for declaring the behavior of a property P on a
533
	# property page in the sense that changing their values requires that all
534
	# pages that use P must be processed again. For example, if _PVAL (allowed
535
	# values) for a property change, then pages must be processed again. This
536
	# setting is not normally changed by users but by extensions that add new
537
	# types that have their own additional declaration properties.
538
	##
539
	'smwgDeclarationProperties' => array( '_PVAL', '_LIST', '_PVAP', '_PVUC', '_PDESC', '_PPLB' ),
540
	##
541
542
	###
543
	# By default, DataTypes (Date, URL etc.) are registered with a corresponding
544
	# property of the same name to match the expected semantics. Yet, users can
545
	# decide to change the behaviour by exempting listed DataTypes from the property
546
	# registration process.
547
	#
548
	# @since 2.5
549
	##
550
	'smwgDataTypePropertyExemptionList' => array(
551
		'Record',
552
		'Reference'
553
	),
554
	##
555
556
	// some default settings which usually need no modification
557
558
	###
559
	# -- FEATURE IS DISABLED --
560
	# Setting this to true allows to translate all the labels within
561
	# the browser GIVEN that they have interwiki links.
562
	##
563
	'smwgTranslate' => false,
564
	##
565
566
	###
567
	# -- FEATURE IS DISABLED --
568
	# If you want to import ontologies, you need to install RAP,
569
	# a free RDF API for PHP, see
570
	#     http://www.wiwiss.fu-berlin.de/suhl/bizer/rdfapi/
571
	# The following is the path to your installation of RAP
572
	# (the directory where you extracted the files to) as seen
573
	# from your local filesystem. Note that ontology import is
574
	# highly experimental at the moment, and may not do what you
575
	# extect.
576
	##
577
	// 	'smwgRAPPath' => $smwgIP . 'libs/rdfapi-php',
0 ignored issues
show
Unused Code Comprehensibility introduced by
46% of this comment could be valid code. Did you maybe forget this after debugging?

Sometimes obsolete code just ends up commented out instead of removed. In this case it is better to remove the code once you have checked you do not need it.

The code might also have been commented out for debugging purposes. In this case it is vital that someone uncomments it again or your project may behave in very unexpected ways in production.

This check looks for comments that seem to be mostly valid code and reports them.

Loading history...
578
	// 	'smwgRAPPath' => '/another/example/path/rdfapi-php',
0 ignored issues
show
Unused Code Comprehensibility introduced by
58% of this comment could be valid code. Did you maybe forget this after debugging?

Sometimes obsolete code just ends up commented out instead of removed. In this case it is better to remove the code once you have checked you do not need it.

The code might also have been commented out for debugging purposes. In this case it is vital that someone uncomments it again or your project may behave in very unexpected ways in production.

This check looks for comments that seem to be mostly valid code and reports them.

Loading history...
579
	##
580
581
	###
582
	# If the following is set to true, it is possible to initiate the repairing
583
	# or updating of all wiki data using the interface on Special:SMWAdmin.
584
	##
585
	'smwgAdminRefreshStore' => true,
586
	##
587
588
	###
589
	# Allows to restrict access to the "Database installation and upgrade"
590
	# feature in the Special:SemanticMediaWiki (or Special:SMWAdmin)
591
	#
592
	# @sine 2.5
593
	##
594
	'smwgAdminSetupStore' => true,
595
	##
596
597
	###
598
	# Allows to restrict access to the "Object ID lookup and disposal"
599
	# feature in the Special:SemanticMediaWiki (or Special:SMWAdmin)
600
	#
601
	# @sine 2.5
602
	##
603
	'smwgAdminIdDisposal' => true,
604
	##
605
606
	###
607
	# Sets whether or not the 'printouts' textarea should have autocompletion
608
	# on property names.
609
	##
610
	'smwgAutocompleteInSpecialAsk' => true,
611
	##
612
613
	###
614
	# Sets whether or not to refresh the pages of which semantic data is stored.
615
	# Introduced in SMW 1.5.6
616
	##
617
	'smwgAutoRefreshSubject' => true,
618
	##
619
620
	###
621
	# Sets Semantic MediaWiki object cache and is used to track temporary
622
	# changes in SMW
623
	#
624
	# @see http://www.mediawiki.org/wiki/$wgMainCacheType
625
	#
626
	# @since 1.9
627
	##
628
	'smwgCacheType' => CACHE_ANYTHING,  // To be removed with 3.0 use $smwgMainCacheType
629
	'smwgMainCacheType' => CACHE_ANYTHING, // Isn't used yet
630
	##
631
632
	###
633
	# Separate cache type to allow for adding a more responsive cache layer
634
	# (redis, riak) when requesting value lookups from the SQLStore.
635
	#
636
	# CACHE_NONE = disabled, uses the standard SQLStore DB access for all
637
	# lookups
638
	#
639
	# @since 2.3 (experimental)
0 ignored issues
show
Unused Code Comprehensibility introduced by
38% of this comment could be valid code. Did you maybe forget this after debugging?

Sometimes obsolete code just ends up commented out instead of removed. In this case it is better to remove the code once you have checked you do not need it.

The code might also have been commented out for debugging purposes. In this case it is vital that someone uncomments it again or your project may behave in very unexpected ways in production.

This check looks for comments that seem to be mostly valid code and reports them.

Loading history...
640
	#
641
	# @default: CACHE_NONE, users need to actively enable it in order
642
	# to make use of it
643
	##
644
	'smwgValueLookupCacheType' => CACHE_NONE,
645
	##
646
647
	###
648
	# Declares a lifetime of a cached item for `smwgValueLookupCacheType` until it
649
	# is removed if not invalidated before.
650
	#
651
	# @since 2.3
652
	##
653
	'smwgValueLookupCacheLifetime' => 60 * 60 * 24 * 7, // a week
654
	##
655
656
	##
657
	# Features expected to be enabled in CachedValueLookupStore
658
	#
659
	# Flags that declare a enable/disable state of a supported functionality. If a
660
	# feature is disabled then a connection is always established to the standard
661
	# Repository/DB backend.
662
	#
663
	# The settings are only relevant for cases where `smwgValueLookupCacheType` is
664
	# set.
665
	#
666
	# - SMW_VL_SD: corresponds to Store::getSemanticData
667
	# - SMW_VL_PL: corresponds to Store::getProperties
668
	# - SMW_VL_PV: corresponds to Store::getPropertyValues
669
	# - SMW_VL_PS: corresponds to Store::getPropertySubjects
670
	#
671
	# @since 2.3
672
	#
673
	# @default: all features are enabled
674
	##
675
	'smwgValueLookupFeatures' => SMW_VL_SD | SMW_VL_PL | SMW_VL_PV | SMW_VL_PS,
676
	##
677
678
	###
679
	# An array containing cache related settings used within Semantic MediaWiki
680
	# and requires $smwgCacheType be set otherwise caching will have no effect.
681
	#
682
	# - smwgWantedPropertiesCache Enable to serve wanted properties from cache
683
	# - smwgWantedPropertiesCacheExpiry Number of seconds before the cache expires
684
	#
685
	# - smwgUnusedPropertiesCache Enable to serve unused properties from cache
686
	# - smwgUnusedPropertiesCacheExpiry Number of seconds before the cache expires
687
	#
688
	# - smwgPropertiesCache Enable to serve properties from cache
689
	# - smwgPropertiesCacheExpiry Number of seconds before the cache expires
690
	#
691
	# - smwgStatisticsCache Enable to serve statistics from cache
692
	# - smwgStatisticsCacheExpiry Number of seconds before the cache expires
693
	#
694
	# @since 1.9
695
	##
696
	'smwgCacheUsage' => array(
697
		'smwgWantedPropertiesCache' => true,
698
		'smwgWantedPropertiesCacheExpiry' => 3600,
699
		'smwgUnusedPropertiesCache' => true,
700
		'smwgUnusedPropertiesCacheExpiry' => 3600,
701
		'smwgPropertiesCache' => true,
702
		'smwgPropertiesCacheExpiry' => 3600,
703
		'smwgStatisticsCache' => true,
704
		'smwgStatisticsCacheExpiry' => 3600,
705
	),
706
	##
707
708
	###
709
	# Sets whether or not to refresh semantic data in the store when a page is
710
	# manually purged
711
	#
712
	# @since 1.9
713
	#
714
	# @requires  $smwgCacheType be set
715
	# @default true
716
	##
717
	'smwgAutoRefreshOnPurge' => true,
718
	##
719
720
	###
721
	# Sets whether or not to refresh semantic data in the store when a page was
722
	# moved
723
	#
724
	# @since 1.9
725
	#
726
	# @requires  $smwgCacheType be set
727
	# @default true
728
	##
729
	'smwgAutoRefreshOnPageMove' => true,
730
	##
731
732
	##
733
	# These are fixed properties, i.e. user defined properties having a
734
	# dedicated table for them. Entries in this array have the following format:
735
	#
736
	# 		property_key => property_type.
737
	#
738
	# The 'property_key' is the title of the property (with underscores instead
739
	# of _ and capital first letter).
740
	# The 'property_type' denotes the type of the property and has to be one of the following:
741
	#		SMWDataItem::TYPE_BLOB
742
	#		SMWDataItem::TYPE_URI
743
	#		SMWDataItem::TYPE_WIKIPAGE
744
	#		SMWDataItem::TYPE_NUMBER
745
	#		SMWDataItem::TYPE_TIME
746
	#		SMWDataItem::TYPE_BOOLEAN
747
	#		SMWDataItem::TYPE_CONTAINER
748
	#		SMWDataItem::TYPE_GEO
749
	#		SMWDataItem::TYPE_CONCEPT
750
	#		SMWDataItem::TYPE_PROPERTY
751
	#
752
	# A run of setup using SMWAdmin is needed to create these tables. If an already used property is assigned a new table all old data for this property will
753
	# become inaccessible for SMW. This can be repaired by either migrating it to the new table (repair data) or will eventually be updated on page edits.
754
	#
755
	# Example: If you have a property named 'Age' which is of type 'Number' then add in LocalSettings:
756
	#
757
	# 		'smwgFixedProperties' => array(
0 ignored issues
show
Unused Code Comprehensibility introduced by
43% of this comment could be valid code. Did you maybe forget this after debugging?

Sometimes obsolete code just ends up commented out instead of removed. In this case it is better to remove the code once you have checked you do not need it.

The code might also have been commented out for debugging purposes. In this case it is vital that someone uncomments it again or your project may behave in very unexpected ways in production.

This check looks for comments that seem to be mostly valid code and reports them.

Loading history...
758
	#		'Age' => SMWDataItem::TYPE_NUMBER
0 ignored issues
show
Unused Code Comprehensibility introduced by
38% of this comment could be valid code. Did you maybe forget this after debugging?

Sometimes obsolete code just ends up commented out instead of removed. In this case it is better to remove the code once you have checked you do not need it.

The code might also have been commented out for debugging purposes. In this case it is vital that someone uncomments it again or your project may behave in very unexpected ways in production.

This check looks for comments that seem to be mostly valid code and reports them.

Loading history...
759
	#  	),
760
	#
761
	# @see http://semantic-mediawiki.org/wiki/Fixed_properties
762
	#
763
	# @since 1.9
764
	#
765
	# @var array
766
	##
767
	'smwgFixedProperties' => array(),
768
769
	###
770
	# Sets a threshold value for when a property is being highlighted as "hardly
771
	# begin used" on Special:Properties
772
	#
773
	# @since 1.9
774
	#
775
	# default = 5
776
	##
777
	'smwgPropertyLowUsageThreshold' => 5,
778
	##
779
780
	###
781
	# Hide properties where the usage count is zero on Special:Properties
782
	#
783
	# @since 1.9
784
	#
785
	# default = true (legacy behaviour)
786
	##
787
	'smwgPropertyZeroCountDisplay' => true,
788
	##
789
790
	###
791
	# Sets whether or not a factbox content should be stored in cache. This will
792
	# considerable improve page response time as non-changed page content will
793
	# not cause re-parsing of factbox content and instead is served directly from
794
	# cache while only a new revision will trigger to re-parse the factbox.
795
	#
796
	# If smwgFactboxUseCache is set false (equals legacy behaviour) then every page
797
	# request will bind the factbox to be re-parsed.
798
	#
799
	# @since 1.9
800
	#
801
	# @requires $smwgCacheType be set
802
	# @default true
803
	##
804
	'smwgFactboxUseCache' => true,
805
	##
806
807
	###
808
	# Sets whether or not a cached factbox should be invalidated on an action=purge
809
	# event
810
	#
811
	# If set false the factbox cache will be only reset after a new page revision
812
	# but if set true each purge request (no new page revision) will invalidate
813
	# the factbox cache
814
	#
815
	# @since 1.9
816
	#
817
	# @requires $smwgCacheType be set
818
	# @default true
819
	##
820
	'smwgFactboxCacheRefreshOnPurge' => true,
821
	##
822
823
	###
824
	# This option enables to omit categories (marked with __HIDDENCAT__) from
825
	# the annotation process.
826
	#
827
	# If a category is updated of either being hidden or visible, pages need to
828
	# be refreshed to ensure that the StoreUpdater can make use of the changed
829
	# environment.
830
	#
831
	# @since 1.9
832
	# @default true (true = legacy behaviour, false = not to show hidden categories)
833
	##
834
	'smwgShowHiddenCategories' => true,
835
	##
836
837
	###
838
	# QueryProfiler related setting to enable/disable specific monitorable profile
839
	# data
840
	#
841
	# @note If these settings are changed, please ensure to run update.php/rebuildData.php
842
	#
843
	# - smwgQueryProfiler can be set false itself allowing it to disable its
844
	# functionality but it may impact secondary processes that rely on profile
845
	# information to be available (Notification system etc.)
846
	#
847
	# - smwgQueryDurationEnabled to record query duration (the time
848
	# between the query result selection and output its)
849
	#
850
	# False will disabled the query profiler (not recommended)
851
	#
852
	# @since 1.9
853
	##
854
	'smwgQueryProfiler' => array(
855
		'smwgQueryDurationEnabled' => false,
856
	),
857
	##
858
859
	###
860
	# Enables SMW specific annotation and content processing for listed SpecialPages
861
	#
862
	# @since 1.9
863
	##
864
	'smwgEnabledSpecialPage' => array( 'Ask' ),
865
	##
866
867
	###
868
	# Search engine to fall back to in case SMWSearch is used as custom search
869
	# engine but is unable to interpret the search term as an SMW query
870
	#
871
	# Leave as null to select the default search engine for the selected database
872
	# type (e.g. SearchMySQL, SearchPostgres or SearchOracle), or set to a class
873
	# name to override to a custom search engine.
874
	#
875
	# @since 2.1
876
	##
877
	'smwgFallbackSearchType' => null,
878
	##
879
880
	###
881
	# If enabled it will display help information on the edit page to support users
882
	# unfamiliar with SMW when extending page content.
883
	#
884
	# @since 2.1
885
	##
886
	'smwgEnabledEditPageHelp' => true,
887
	##
888
889
	###
890
	# Various MediaWiki update operations in MW 1.26+ started to use DeferredUpdates
891
	# and to ensure that the Store update follows in queue of updates made to a page
892
	# this setting should be enabled by default for MW 1.26 onwards.
893
	#
894
	# It will improve page responsiveness for purge and move action significantly.
895
	#
896
	# @since 2.4
897
	##
898
	'smwgEnabledDeferredUpdate' => true,
899
	##
900
901
	###
902
	# Improves performance for selected Job operations that can be executed in a deferred
903
	# processing mode (or asynchronous to the current transaction) as those (if enabled)
904
	# are send as request to a dispatcher in order for them to be decoupled from the
905
	# initial transaction.
906
	#
907
	# @since 2.3
908
	##
909
	'smwgEnabledHttpDeferredJobRequest' => true,
910
	##
911
912
	###
913
	# If enabled it will store dependencies for queries allowing it to purge
914
	# the ParserCache on subjects with embedded queries that contain altered entities.
915
	#
916
	# The setting requires to run `update.php` (it creates an extra table). Also
917
	# as noted in 	#1117, `SMW\ParserCachePurgeJob` should be scheduled accordingly.
918
	#
919
	# Requires `smwgEnabledHttpDeferredJobRequest` to be set true.
920
	#
921
	# @since 2.3 (experimental)
0 ignored issues
show
Unused Code Comprehensibility introduced by
38% of this comment could be valid code. Did you maybe forget this after debugging?

Sometimes obsolete code just ends up commented out instead of removed. In this case it is better to remove the code once you have checked you do not need it.

The code might also have been commented out for debugging purposes. In this case it is vital that someone uncomments it again or your project may behave in very unexpected ways in production.

This check looks for comments that seem to be mostly valid code and reports them.

Loading history...
922
	# @default false
923
	##
924
	'smwgEnabledQueryDependencyLinksStore' => false,
925
	##
926
927
	###
928
	# Relates to `smwgEnabledQueryDependencyLinksStore` and defines property keys
929
	# to be excluded from the dependency detection.
930
	#
931
	# For example, to avoid a purge process being triggered for each altered subobject
932
	# '_SOBJ' is excluded from the processing but it will not exclude any properties
933
	# defined by a subobject (given that it is not part of an extended exclusion list).
934
	#
935
	# `_MDAT` is excluded to avoid a purge on each page edit with a `Modification date`
936
	# change that would otherwise trigger a dependency update.
937
	#
938
	# '_ASKDU' changes to the duration of a query should not trigger an update of
939
	# possible query dependencies (as this has no bearing on the result list).
940
	#
941
	# @since 2.3 (experimental)
0 ignored issues
show
Unused Code Comprehensibility introduced by
38% of this comment could be valid code. Did you maybe forget this after debugging?

Sometimes obsolete code just ends up commented out instead of removed. In this case it is better to remove the code once you have checked you do not need it.

The code might also have been commented out for debugging purposes. In this case it is vital that someone uncomments it again or your project may behave in very unexpected ways in production.

This check looks for comments that seem to be mostly valid code and reports them.

Loading history...
942
	##
943
	'smwgQueryDependencyPropertyExemptionlist' => array( '_MDAT', '_SOBJ', '_ASKDU' ),
944
	##
945
946
	###
947
	# Listed properties are marked as affiliate, meaning that when an alteration to
948
	# a property value occurs query dependencies for the related entity are recorded
949
	# as well. For example, _DTITLE is most likely such property where a change would
950
	# normally not be reflected in query results (as it not directlty linked to a
951
	# query) but when added as an affiliated, changes to its content will be
952
	# handled as if it is linked to an embedded entity.
953
	#
954
	# @since 2.4 (experimental)
0 ignored issues
show
Unused Code Comprehensibility introduced by
38% of this comment could be valid code. Did you maybe forget this after debugging?

Sometimes obsolete code just ends up commented out instead of removed. In this case it is better to remove the code once you have checked you do not need it.

The code might also have been commented out for debugging purposes. In this case it is vital that someone uncomments it again or your project may behave in very unexpected ways in production.

This check looks for comments that seem to be mostly valid code and reports them.

Loading history...
955
	##
956
	'smwgQueryDependencyAffiliatePropertyDetectionlist' => array(),
957
	##
958
959
	###
960
	# The setting is introduced the keep backwards compatibility with existing Rdf/Turtle
961
	# exports. The `aux` marker is epxected only used to be used for selected properties
962
	# to generate a helper value and not for any other predefined property.
963
	#
964
	# Any property that does not explicitly require an auxiliary value (such `_dat`/
965
	# `_geo` type values) now uses its native as condition descriptor (`Has_subobject`
966
	# instead of `Has_subobject-23aux`)
967
	#
968
	# For SPARQL repository users that don't want to run an a  `rebuildData.php`,
969
	# the setting has to be TRUE.
970
	#
971
	# This BC setting is planned to vanish with 3.x.
972
	#
973
	# @since 2.3
974
	##
975
	'smwgExportBCAuxiliaryUse' => false,
976
	##
977
978
	##
979
	# The preferred form is to use canonical identifiers (Category:, Property:)
980
	# instead of localized names to ensure that RDF/Query statements are language
981
	# agnostic and do work even after the site/content language changes.
982
	#
983
	# This BC setting is planned to vanish with 3.x.
984
	#
985
	# @since 2.3
986
	##
987
	'smwgExportBCNonCanonicalFormUse' => false,
988
	##
989
990
	##
991
	# The strict mode is to help to remove ambiguity during the annotation [[ ... :: ... ]]
992
	# parsing process.
993
	#
994
	# The default interpretation (strict) is to find a single triple such as
995
	# [[property::value:partOfTheValue::alsoPartOfTheValue]] where in case the strict
0 ignored issues
show
Unused Code Comprehensibility introduced by
37% of this comment could be valid code. Did you maybe forget this after debugging?

Sometimes obsolete code just ends up commented out instead of removed. In this case it is better to remove the code once you have checked you do not need it.

The code might also have been commented out for debugging purposes. In this case it is vital that someone uncomments it again or your project may behave in very unexpected ways in production.

This check looks for comments that seem to be mostly valid code and reports them.

Loading history...
996
	# mode is disabled multiple properties can be assigned using a
997
	# [[property1::property2::value]] notation but may cause value strings to be
998
	# interpret unanticipated in case of additional colons.
999
	#
1000
	# @since 2.3
1001
	# @default true
1002
	##
1003
	'smwgEnabledInTextAnnotationParserStrictMode' => true,
1004
	##
1005
1006
	##
1007
	# Features or restrictions for specific DataValue types
1008
	#
1009
	# - SMW_DV_NONE
1010
	#
1011
	# - SMW_DV_PROV_REDI (PropertyValue) If a property is redirected to a different
1012
	# target (Foo -> Bar) then follow it by default in order to allow query results
1013
	# to be displayed equivalent for both queries without having to adjust
1014
	# (or change) a query. This flag is mainly provided to restore backwards
1015
	# compatibility where behaviour is not expected to be altered, nevertheless it is
1016
	# recommended that the setting is enabled to improve user friendliness in terms
1017
	# of query execution.
1018
	#
1019
	# - SMW_DV_MLTV_LCODE (MonolingualTextValue) is to require a language code in order
1020
	# for a DV to be completed otherwise a MLTV can operate without a language code
1021
	#
1022
	# - SMW_DV_PVAP (Allows pattern) to allow regular expression pattern matching
1023
	# when `Allows pattern` property is assigned to user-defined property
1024
	#
1025
	# - SMW_DV_WPV_DTITLE (WikiPageValue) is to allow requesting a lookup for a display
1026
	# title and if present will be used as caption for the invoked subject
1027
	#
1028
	# - SMW_DV_PROV_DTITLE (PropertyValue) in combination with SMW_DV_WPV_DTITLE, If
1029
	# enabled it will attempt to resolve a property label by matching it against a
1030
	# possible assigned property "Display title of" value. For example, property
1031
	# "Foo" has "Display title of" "hasFoolishFoo" where "hasFoolishFoo" is being
1032
	# resolved as "Foo" when creating annotations. Currently, this uses an
1033
	# uncached lookup and therefore is disabled by default to avoid a possible
1034
	# performance impact (which has not been established or analyzed).
1035
	#
1036
	# - SMW_DV_PVUC (Uniqueness constraint) to specify that a property can only
1037
	# assign a value that is unique in its literal representation (the state of
1038
	# uniqueness for a value is established by the fact that it is assigned before
1039
	# any other value of the same representation to a property).
1040
	#
1041
	# - SMW_DV_TIMEV_CM (TimeValue) to indicate the CalendarModel if is not a
1042
	# CM_GREGORIAN
1043
	#
1044
	# - SMW_DV_NUMV_USPACE (Number/QuantityValue) to preserve spaces within
1045
	# unit labels
1046
	#
1047
	# - SMW_DV_PPLB to support the use of preferred property labels
1048
	#
1049
	# - SMW_DV_PROV_LHNT (PropertyValue) to output a <sup>p</sup> hint marker on
1050
	# properties that use a preferred label
1051
	#
1052
	# @since 2.4
1053
	##
1054
	'smwgDVFeatures' => SMW_DV_PROV_REDI | SMW_DV_MLTV_LCODE | SMW_DV_PVAP | SMW_DV_WPV_DTITLE | SMW_DV_TIMEV_CM | SMW_DV_PPLB | SMW_DV_PROV_LHNT,
1055
	##
1056
1057
	##
1058
	# Fulltext search support
1059
	#
1060
	# If enabled, it will store text elements using a separate table in order for the
1061
	# DB back-end to use special fulltext index operations.
1062
	#
1063
	# - Tested with MySQL/MariaDB
1064
	# - Tested with SQLite
1065
	#
1066
	# @since 2.5
1067
	##
1068
	'smwgEnabledFulltextSearch' => false,
1069
	##
1070
1071
	##
1072
	# Throttle index updates
1073
	#
1074
	# The objective is to postpone an update by relying on a deferred process that
1075
	# runs the index update decoupled from the storage back-end update.
1076
	#
1077
	# In case `smwgFulltextDeferredUpdate` and `	'smwgEnabledDeferredUpdate']` are
0 ignored issues
show
Unused Code Comprehensibility introduced by
38% of this comment could be valid code. Did you maybe forget this after debugging?

Sometimes obsolete code just ends up commented out instead of removed. In this case it is better to remove the code once you have checked you do not need it.

The code might also have been commented out for debugging purposes. In this case it is vital that someone uncomments it again or your project may behave in very unexpected ways in production.

This check looks for comments that seem to be mostly valid code and reports them.

Loading history...
1078
	# both enabled then the updater will try to open a new request and posting instructions
1079
	# to execute the `SearchTableUpdateJob` immediately in background. If the request
1080
	# cannot be executed then the `SearchTableUpdateJob` will be enqueued and requires
1081
	# `runJobs.php` to schedule the index table update.
1082
	#
1083
	# If a user wants to push updates to the updater immediately then this setting needs
1084
	# to be disabled but by disabling this setting update lag may increase due to having
1085
	# the process being executed synchronously to the wikipage, store-backend storage.
1086
	#
1087
	# @since 2.5
1088
	# @default true
1089
	##
1090
	'smwgFulltextDeferredUpdate' => true,
1091
	##
1092
1093
	##
1094
	# Fulltext search table options
1095
	#
1096
	# This setting directly influences how a ft table is created therefore change
1097
	# the content with caution.
1098
	#
1099
	# - MySQL version 5.5 or later with only MyISAM and InnoDB storage engines
1100
	# to support full-text search (according to sources)
1101
	#
1102
	# - MariaDB full-text indexes can be used only with MyISAM and Aria tables,
1103
	# from MariaDB 10.0.5 with InnoDB tables and from MariaDB 10.0.15
1104
	# with Mroonga tables (according to sources)
1105
	#
1106
	# - SQLite FTS3 has been available since version 3.5, FTS4 were added with
1107
	# version 3.7.4, and FTS5 is available with version 3.9.0 (according to
1108
	# sources), The setting allows to specify extra arguments after the module
1109
	# engine such as array( 'FTS4', 'tokenize=porter' ).
0 ignored issues
show
Unused Code Comprehensibility introduced by
42% of this comment could be valid code. Did you maybe forget this after debugging?

Sometimes obsolete code just ends up commented out instead of removed. In this case it is better to remove the code once you have checked you do not need it.

The code might also have been commented out for debugging purposes. In this case it is vital that someone uncomments it again or your project may behave in very unexpected ways in production.

This check looks for comments that seem to be mostly valid code and reports them.

Loading history...
1110
	#
1111
	# It is possible to extend the option decription (MySQL 5.7+)  with
1112
	# 'mysql' => array( 'ENGINE=MyISAM, DEFAULT CHARSET=utf8', 'WITH PARSER ngram' )
0 ignored issues
show
Unused Code Comprehensibility introduced by
50% of this comment could be valid code. Did you maybe forget this after debugging?

Sometimes obsolete code just ends up commented out instead of removed. In this case it is better to remove the code once you have checked you do not need it.

The code might also have been commented out for debugging purposes. In this case it is vital that someone uncomments it again or your project may behave in very unexpected ways in production.

This check looks for comments that seem to be mostly valid code and reports them.

Loading history...
1113
	#
1114
	# @since 2.5
1115
	##
1116
	'smwgFulltextSearchTableOptions' => array(
1117
		'mysql'  => array( 'ENGINE=MyISAM, DEFAULT CHARSET=utf8' ),
1118
		'sqlite' => array( 'FTS4' )
1119
	),
1120
	##
1121
1122
	##
1123
	# List of property keys for which value assignments are being exempted from the
1124
	# fulltext indexing process because there are either insignificant or mostly
1125
	# represent single terms which are not required to be searched via a FT or a
1126
	# proximity.
1127
	#
1128
	# Listed properties will use the standard LIKE/NLIKE expression when used in
1129
	# connection with the ~/!~ operator.
1130
	#
1131
	# @since 2.5
1132
	##
1133
	'smwgFulltextSearchPropertyExemptionList' => array(
1134
		'_ASKFO', '_ASKST', '_IMPO', '_LCODE', '_UNIT', '_CONV', '_TYPE', '_ERRT'
1135
	),
1136
	##
1137
1138
	##
1139
	# Describes the minimum word/token length to help to decide whether MATCH or LIKE
1140
	# operators are to be used for a condition statement.
1141
	#
1142
	# For MySQL it is expected it corresponds to either innodb_ft_min_token_size or
1143
	# ft_min_word_len
1144
	#
1145
	# @since 2.5
1146
	##
1147
	'smwgFulltextSearchMinTokenSize' => 3,
1148
	##
1149
1150
	##
1151
	# To detect a possible language candidate from an indexable text element.
1152
	#
1153
	# TextCatLanguageDetector, a large list of languages does have a detrimental
1154
	# influence on the performance when trying to detect a language from a free text.
1155
	#
1156
	# Stopwords are only applied after language detection has been enabled.
1157
	#
1158
	# @see https://github.com/wikimedia/wikimedia-textcat
1159
	#
1160
	# @since 2.5
1161
	# @default empty list (language detection is disabled by default)
1162
	##
1163
	'smwgFulltextLanguageDetection' => array(
1164
	//	'TextCatLanguageDetector' => array( 'en', 'de', 'fr', 'es', 'ja', 'zh' )
0 ignored issues
show
Unused Code Comprehensibility introduced by
58% of this comment could be valid code. Did you maybe forget this after debugging?

Sometimes obsolete code just ends up commented out instead of removed. In this case it is better to remove the code once you have checked you do not need it.

The code might also have been commented out for debugging purposes. In this case it is vital that someone uncomments it again or your project may behave in very unexpected ways in production.

This check looks for comments that seem to be mostly valid code and reports them.

Loading history...
1165
	//	'CdbNGramLanguageDetector' => array( 'en', 'de', 'fr', 'es', 'ja', 'zh' )
0 ignored issues
show
Unused Code Comprehensibility introduced by
58% of this comment could be valid code. Did you maybe forget this after debugging?

Sometimes obsolete code just ends up commented out instead of removed. In this case it is better to remove the code once you have checked you do not need it.

The code might also have been commented out for debugging purposes. In this case it is vital that someone uncomments it again or your project may behave in very unexpected ways in production.

This check looks for comments that seem to be mostly valid code and reports them.

Loading history...
1166
	),
1167
	##
1168
1169
	##
1170
	# Using MySQL's "Global Transaction Identifier" will create issues when executing
1171
	# queries that rely on temporary tables, according to the documentation "... the
1172
	# operations listed here cannot be used ... CREATE TEMPORARY TABLE statements
1173
	# inside transactions".
1174
	#
1175
	# MySQL Global transaction identifier is a unique transaction ID assigned to every
1176
	# transaction that happens in MySQL database.
1177
	#
1178
	# Issue is encountered when @@GLOBAL.ENFORCE_GTID_CONSISTENCY = 1
1179
	#
1180
	# @see https://dev.mysql.com/doc/refman/5.6/en/replication-options-gtids.html
1181
	# @see https://support.software.dell.com/kb/184275
1182
	#
1183
	# @since 2.5
1184
	# @default false
1185
	##
1186
	'smwgQTemporaryTablesAutoCommitMode' => false,
1187
	##
1188
1189
	###
1190
	# Support to store a computed subject list that were fetched from the QueryEngine
1191
	# (not the string result generated from a result printer) and improve general
1192
	# page-loading time for articles that contain embedded queries and decrease
1193
	# server load on query requests.
1194
	#
1195
	# It is recommended that `smwgEnabledQueryDependencyLinksStore` is enabled to make
1196
	# use of automatic query results cache eviction.
1197
	#
1198
	# @since 2.5 (experimental)
0 ignored issues
show
Unused Code Comprehensibility introduced by
38% of this comment could be valid code. Did you maybe forget this after debugging?

Sometimes obsolete code just ends up commented out instead of removed. In this case it is better to remove the code once you have checked you do not need it.

The code might also have been commented out for debugging purposes. In this case it is vital that someone uncomments it again or your project may behave in very unexpected ways in production.

This check looks for comments that seem to be mostly valid code and reports them.

Loading history...
1199
	#
1200
	# @default: CACHE_NONE (== that this feature is disabled)
1201
	##
1202
	'smwgQueryResultCacheType' => CACHE_NONE,
1203
	##
1204
1205
	###
1206
	# Specifies the lifetime of embedded query and their results fetched from a
1207
	# QueryEngine for when `smwgQueryResultCacheType` is enabled.
1208
	#
1209
	# @since 2.5
1210
	##
1211
	'smwgQueryResultCacheLifetime' => 60 * 60 * 24, // a day
1212
	##
1213
1214
	###
1215
	# Specifies the lifetime of non-embedded queries (Special:Ask, API etc.) and their
1216
	# results that are fetched from a QueryEngine for when `smwgQueryResultCacheType` is
1217
	# enabled.
1218
	#
1219
	# This setting can also be used to minimize a possible DoS vector by preventing
1220
	# an advisory to make unlimited query requests from either Special:Ask or the
1221
	# API that may lock the DB due to complex query answering and instead being
1222
	# rerouted to the cache once a result has been computed.
1223
	#
1224
	# @note Non-embedded queries cannot not be tracked using the `QueryDependencyLinksStore`
1225
	# (subject is being missing that would identify the entity) therefore
1226
	# an auto-purge mechanism as in case of an embedded entity is not possible hence
1227
	# the lifetime should be carefully selected to provide the necessary means for a
1228
	# user and the application.
1229
	#
1230
	# 0/false as setting to disable caching of non-embedded queries.
1231
	#
1232
	# @since 2.5
1233
	##
1234
	'smwgQueryResultNonEmbeddedCacheLifetime' => 60 * 10, // 10 min
1235
	##
1236
1237
	###
1238
	# Enables the manual refresh for embedded queries when the action=purge event is
1239
	# triggered.
1240
	#
1241
	# @since 2.5
1242
	##
1243
	'smwgQueryResultCacheRefreshOnPurge' => true,
1244
	##
1245
1246
);
1247