You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
mastodon/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.
4 years ago
..
accounts Add user notes on accounts (#14148) 5 years ago
admin Change deletes to preserve soft-deleted statuses in unresolved reports (#11805) 5 years ago
announcements Add announcements (#12662) 5 years ago
apps Remove useless `respond_to` calls (#13208) 5 years ago
crypto Fix wrong route helper in encrypted messages controller (#13952) 5 years ago
featured_tags Remove useless `respond_to` calls (#13208) 5 years ago
instances Remove useless `respond_to` calls (#13208) 5 years ago
lists Extract counters from accounts table to account_stats table (#9295) 6 years ago
polls Add more tests for ActivityPub controllers (#13585) 5 years ago
push Add more tests for ActivityPub controllers (#13585) 5 years ago
statuses Fix not being able to unbookmark toots when blocked by their author (#14604) 4 years ago
timelines Use Status.group instead of Status.distinct in HashQueryService (#14662) 4 years ago
accounts_controller.rb Add specific rate limits for posting and following (#13172) 5 years ago
announcements_controller.rb Fix dismissing an announcement twice raising an obscure error (#13124) 5 years ago
apps_controller.rb Add whitelist mode (#11291) 6 years ago
blocks_controller.rb Remove useless `respond_to` calls (#13208) 5 years ago
bookmarks_controller.rb Remove useless `respond_to` calls (#13208) 5 years ago
conversations_controller.rb Remove useless `respond_to` calls (#13208) 5 years ago
custom_emojis_controller.rb Remove useless `respond_to` calls (#13208) 5 years ago
directories_controller.rb Add profile directory to web UI (#11688) 5 years ago
domain_blocks_controller.rb Remove useless `respond_to` calls (#13208) 5 years ago
endorsements_controller.rb Remove useless `respond_to` calls (#13208) 5 years ago
favourites_controller.rb Remove useless `respond_to` calls (#13208) 5 years ago
featured_tags_controller.rb Add featured tags API (#11778) 5 years ago
filters_controller.rb Remove useless `respond_to` calls (#13208) 5 years ago
follow_requests_controller.rb Add updated relationship to follow request API responses (#11800) 5 years ago
instances_controller.rb Remove useless `respond_to` calls (#13208) 5 years ago
lists_controller.rb Fix low-hanging rubocop gripes (#8458) 6 years ago
markers_controller.rb Add timeline read markers API (#11762) 5 years ago
media_controller.rb Add customizable thumbnails for audio and video attachments (#14145) 5 years ago
mutes_controller.rb Remove useless `respond_to` calls (#13208) 5 years ago
notifications_controller.rb Remove useless `respond_to` calls (#13208) 5 years ago
polls_controller.rb Add more tests for ActivityPub controllers (#13585) 5 years ago
preferences_controller.rb Remove useless `respond_to` calls (#13208) 5 years ago
reports_controller.rb Add rate limit for reporting (#13390) 5 years ago
scheduled_statuses_controller.rb Add scheduled statuses (#9706) 6 years ago
statuses_controller.rb Fix/14021 behaviour on add or remove toots (#14212) 5 years ago
streaming_controller.rb Remove useless `respond_to` calls (#13208) 5 years ago
suggestions_controller.rb Remove useless `respond_to` calls (#13208) 5 years ago
trends_controller.rb Remove useless `respond_to` calls (#13208) 5 years ago