Commit graph

10 commits

Author SHA1 Message Date
Petr Pchelko
ea04a07b7d REST PageHistoryCount: Add object caching with incremental updates.
Bug: T237430
Change-Id: I7876b7ee9fdf55dbaec5946fb1f28c0ed068de74
2019-11-27 14:56:46 -06:00
Nikki Nikkhoui
d860dd9ee9 Increase history edit count endpoint limits
Bumped up limits for history edit count endpoint for all edits, bot edits, anon edits, editors, and reverted edits

Bug: T238380
Change-Id: I1da771d4cadbc0c280935ecfca800e382cd1629f
2019-11-25 11:31:12 -08:00
Tim Starling
0d4afbd8af Workaround for MariaDB query plan bug
Removing the quotes makes this query about a million times faster, for
unclear reasons.

I also have a patch to addQuotes(), but it should be possible to merge
this hack faster.

Bug: T238378
Change-Id: I4ba6d8ba02233aca91ae2e7a4e6ec7f5a316214a
2019-11-15 17:37:27 +11:00
Petr Pchelko
5b77ce93ad REST: Deduplicate and normalize REST error message names
Bug: T237568
Change-Id: I6f35757f948b34a6a641808db8e5f98983054b7b
2019-11-08 09:37:26 -08:00
Petr Pchelko
24a67d77b4 REST History Counts: Limit the number of edits to count
Bug: T237115
Change-Id: Ie015e1316de734599266fcaedf1aede7c1e528a7
2019-11-06 14:26:07 -08:00
Petr Pchelko
7fef88e7cc REST: Implement from and to for editors count handler.
* Move Title::{get,count}AuthorsBetween to RevisionStore
* Use it in REST count handler to to provide 'from' and 'to'
support for editors count.

Bug: T235896
Bug: T235666
Change-Id: Ib7947ae64b82871ceb4a3097a0ea03c0ba218c7c
2019-11-05 07:48:38 -08:00
Petr Pchelko
d951e6ccb6 REST: Add 'from' and 'to' parameters to historycount endpoint.
* Add 'from' and 'to' query parameters to history count endpoint,
in case we are counting 'edits'. The support for parameters will be
expanded in the future, given that 'editors' is on the way.

* Refactor RevisionStore::countRevisionsBetween to be able to omit
starting or ending revision.

Bug: T235666
Change-Id: I1fc3f2d4e422f17ccfc99664ea35e210c13ade5f
2019-11-04 15:21:22 -08:00
Bill Pirkle
f54b4a72be Add minor edit count to available REST API history counts
Add "minor" as an allowed value for the count type parameter
in PageHistoryCountHandler.php

Bug: T235587
Change-Id: I31cf37a28c62efa98d719d386001e560ca5dd188
2019-11-04 10:57:41 -06:00
Bill Pirkle
939def09f2 Rename/deprecate some REST history count types
For consistency with the history endpoint, the following REST
history count types will be renamed. The old names will continue
to function for now, but will return a Deprecation header, plus
a Link header pointing to the REST API endpoint documentation:
  anonedits => anonymous
  botedits => bot
  revertededits => reverted

Bug: T234941
Bug: T236323
Bug: T236324
Bug: T236325
Change-Id: Ice84bd93cbc9c33a5ae67a16094104eef919cb7b
2019-10-28 09:37:26 -05:00
Bill Pirkle
c6460e11eb Add core REST API endpoint for history edit counts
Add core REST API endpoint for history edit counts.
Support count types are:
  anonedits
  botedits
  editors
  edits
  revertededits

Bug: T231590
Change-Id: Iedbca15956e14aac9f105a1f1446555b21ac9e46
2019-10-10 12:51:59 -05:00