mediawiki-extensions-AbuseF.../includes
Dreamy Jazz 774f4f02ef Create protected variable access logs POSTSEND
Why:
* The ProtectedVarsAccessLogger::logViewProtectedVariableValue
  method creates a debounced log entry for accessing protected
  variable values.
* This log can be created when a user calls the 'abuselog' query
  API. This API query is made using a GET request.
* Because the ProtectedVarsAccessLogger creates the log
  when it is called, the TransactionProfiler raises a warning
  about writing to the primary DB on a GET request.
* We should address this warning by creating the log entry on
  POSTSEND, in a similar way to how the CheckUser extension
  creates CheckUser log entries.

What:
* Wrap the call to ProtectedVarsAccessLogger::log in
  ::logViewProtectedVariableValue with a DeferredUpdate callback
  that is run POSTSEND.
** As part of this, the expectations that the code only uses the
   replica DBs are silenced inside the DeferredUpdate as the
   PostSend-GET expectations do not usually allow for writes.
   The only other method would to be create the log via a job,
   but we want the log creation to occur quickly and reliably.

Bug: T379083
Change-Id: If14e65b27b0bdd4fd0b99319024ffa281bf44656
2024-11-11 14:33:47 +00:00
..
Api Use type-declaration on api module constructor 2024-10-25 19:02:04 +02:00
ChangeTags Use namespaced classes 2024-10-19 21:55:40 +02:00
Consequences Use namespaced classes 2024-10-19 21:55:40 +02:00
EditBox Use namespaced classes 2024-06-12 20:01:35 +02:00
Filter Miscellaneous minor fixes 2024-07-03 02:31:38 +02:00
Hooks Use explicit nullable type on parameter arguments (for PHP 8.4) 2024-10-26 14:38:46 +02:00
LogFormatter Log specific views of protected variables 2024-10-02 00:53:34 -07:00
Pager AbuseLogPager: Fix passing false as message parameter 2024-10-23 17:53:07 +02:00
Parser Use explicit nullable type on parameter arguments (for PHP 8.4) 2024-10-26 14:38:46 +02:00
Special Merge "Protected variable logs: fallback to accountname if user_name is not set" 2024-10-21 20:18:15 +00:00
VariableGenerator Use explicit nullable type on parameter arguments (for PHP 8.4) 2024-10-26 14:38:46 +02:00
Variables Use namespaced classes 2024-10-19 21:55:40 +02:00
View Add code comments to help find dynamically-generated IDs in the codebase 2024-10-29 03:10:27 +00:00
Watcher Migrate to IDatabase::newUpdateQueryBuilder 2024-04-15 23:07:44 +02:00
AbuseFilter.php
AbuseFilterChangesList.php Use namespaced classes 2024-06-12 20:01:35 +02:00
AbuseFilterPermissionManager.php Log specific views of protected variables 2024-10-02 00:53:34 -07:00
AbuseFilterPreAuthenticationProvider.php Use namespaced classes 2024-10-19 21:55:40 +02:00
AbuseFilterServices.php Use explicit nullable type on parameter arguments (for PHP 8.4) 2024-10-26 14:38:46 +02:00
AbuseLogger.php Use namespaced classes 2024-10-19 21:55:40 +02:00
AbuseLoggerFactory.php Log specific views of protected variables 2024-10-02 00:53:34 -07:00
ActionSpecifier.php
BlockAutopromoteStore.php Use namespaced classes 2024-10-19 21:55:40 +02:00
BlockedDomainFilter.php Use namespaced classes 2024-10-19 21:55:40 +02:00
BlockedDomainStorage.php Use namespaced classes 2024-10-19 21:55:40 +02:00
CentralDBManager.php
CentralDBNotAvailableException.php
EchoNotifier.php
EditRevUpdater.php Migrate to IDatabase::newUpdateQueryBuilder 2024-04-15 23:07:44 +02:00
EditStashCache.php Use namespaced classes 2024-10-19 21:55:40 +02:00
EmergencyCache.php Use namespaced classes 2024-10-19 21:55:40 +02:00
FilterCompare.php Convert af_hidden into a bitmask 2024-05-28 00:59:08 -07:00
FilterImporter.php Use namespaced classes 2024-06-12 20:01:35 +02:00
FilterLookup.php Use namespaced classes 2024-10-19 21:55:40 +02:00
FilterProfiler.php Use namespaced classes 2024-10-19 21:55:40 +02:00
FilterRunner.php
FilterRunnerFactory.php Use namespaced classes 2024-10-19 21:55:40 +02:00
FilterStore.php Remove AbuseFilterActorMigration 2024-06-15 09:42:27 +02:00
FilterUser.php
FilterUtils.php Allow variables to be restricted by user right 2024-06-04 06:54:53 -07:00
FilterValidator.php Miscellaneous minor fixes 2024-07-03 02:31:38 +02:00
GlobalNameUtils.php
InvalidImportDataException.php
KeywordsManager.php Add user_unnamed_ip variable 2024-05-23 07:19:48 -07:00
ProtectedVarsAccessLogger.php Create protected variable access logs POSTSEND 2024-11-11 14:33:47 +00:00
RunnerData.php
ServiceWiring.php Use namespaced classes 2024-10-19 21:55:40 +02:00
SpecsFormatter.php Use namespaced classes 2024-10-19 21:55:40 +02:00
TableDiffFormatterFullContext.php
TextExtractor.php Use namespaced classes 2024-10-19 21:55:40 +02:00
ThrottleFilterPresentationModel.php Use namespaced classes 2024-06-12 20:01:35 +02:00