Glitch-Shrike/app/controllers/api/v1
Akihiko Odaki 41eeb9ebaa
Use Status.group instead of Status.distinct in HashQueryService (#14662)
DISTINCT clause removes duplicated records according to all the selected
attributes. In reality, it can remove duplicated records only looking at
statuses.id, but the clause confuses the query planner and yields
insufficient performance.
The behavior is also problematic if the scope produced by HashQueryService
is used to query columns without id (using pluck method, for example). The
scope is expected to contain unique statuses, but the uniquness will be
evaluated with some arbitrary columns other than id.

GROUP BY clause resolves those problem by explicitly specifying the
column to take into account for the record distinction.

A workaround for the problem of DISTINCT clause in
Api::V1::Timelines::TagController is no longer necessary and removed.
2020-08-25 13:39:35 +02:00
..
accounts Add user notes on accounts (#14148) 2020-06-30 19:19:50 +02:00
admin
announcements
apps
crypto Fix wrong route helper in encrypted messages controller (#13952) 2020-06-03 20:32:15 +02:00
featured_tags
instances
lists
polls Add more tests for ActivityPub controllers (#13585) 2020-05-03 16:30:36 +02:00
push Add more tests for ActivityPub controllers (#13585) 2020-05-03 16:30:36 +02:00
statuses Fix not being able to unbookmark toots when blocked by their author (#14604) 2020-08-19 19:02:06 +02:00
timelines Use Status.group instead of Status.distinct in HashQueryService (#14662) 2020-08-25 13:39:35 +02:00
accounts_controller.rb
announcements_controller.rb
apps_controller.rb
blocks_controller.rb
bookmarks_controller.rb
conversations_controller.rb
custom_emojis_controller.rb
directories_controller.rb
domain_blocks_controller.rb
endorsements_controller.rb
favourites_controller.rb
featured_tags_controller.rb
filters_controller.rb
follow_requests_controller.rb
instances_controller.rb
lists_controller.rb
markers_controller.rb
media_controller.rb Add customizable thumbnails for audio and video attachments (#14145) 2020-06-29 13:56:55 +02:00
mutes_controller.rb
notifications_controller.rb
polls_controller.rb Add more tests for ActivityPub controllers (#13585) 2020-05-03 16:30:36 +02:00
preferences_controller.rb
reports_controller.rb Add rate limit for reporting (#13390) 2020-04-05 14:40:08 +02:00
scheduled_statuses_controller.rb
statuses_controller.rb Fix/14021 behaviour on add or remove toots (#14212) 2020-07-19 17:04:02 +02:00
streaming_controller.rb
suggestions_controller.rb
trends_controller.rb