Michael Kohl
2555b59d87
Extract page view updates into workers ( #12686 )
...
* Extract page view updates into workers
* Restructure code
* Update specs
* Fix and reactive 2 specs
* Update according to PR feedback
* Use create! over create
2021-02-17 09:24:05 +07:00
Krzysztof Rybka
397a1c2389
Update page views counters a little bit more often ( #11286 )
2020-11-06 13:09:11 -05:00
Molly Struve
ca3452f044
Refactor:Remove Production Conditional for Page View Updates ( #11164 )
2020-10-30 13:32:54 -05:00
Michael Kohl
a4dadfb728
Standardize ActiveRecord order clauses ( #9395 )
...
* Change simple order clauses
* Change nested order clauses
2020-07-20 10:00:51 -04:00
rhymes
f1ec04a0c9
Rubocop: move dot in multi-line calls to leading position ( #9262 )
2020-07-16 15:51:11 +02:00
rhymes
5b62811c98
[deploy] Rubocop: fix violations of Layout/LineLength ( #9197 )
2020-07-08 08:36:36 -05:00
Ben Halpern
e260f86e69
[deploy] Add trailing slash back in ( #8838 )
2020-06-22 17:22:42 -04:00
Vaidehi Joshi
c4d9c4aed9
Remove trailing slashes from URLs to improve SEO ( #8836 ) [deploy]
2020-06-22 13:44:58 -07:00
Molly Struve
faa4325c1f
Only Update page_views When They Are Valid (ie created) ( #5195 ) [deploy]
2019-12-26 11:28:18 -06:00
Molly Struve
f26a6f49d2
Revert "Use raw SQL to Update page_views so new and existing Records can be updated ( #5167 ) [deploy]" ( #5185 )
...
This reverts commit 9a7fb3b04e .
2019-12-19 16:43:37 -05:00
Molly Struve
9a7fb3b04e
Use raw SQL to Update page_views so new and existing Records can be updated ( #5167 ) [deploy]
2019-12-19 14:28:32 -06:00
Molly Struve
2d6d611634
switch back to update_column to improve performance ( #5074 ) [deploy]
2019-12-10 18:38:04 -05:00
Molly Struve
3f8a6caa72
Use find_or_create_by when updating a pageview and use update in case of creation ( #5066 ) [deploy]
2019-12-10 13:48:50 -06:00
Ben Halpern
eaf6ea2f4b
Update pageviews count less often in page_views_controller ( #4945 ) [deploy]
2019-11-26 14:11:47 -05:00
Ben Halpern
befefd08d0
Remove extra dependencies for PageViewsController ( #4923 ) [deploy]
...
* Remove extra dependencies for PageViewsController
* Fix strongparams and fix typo
* Fix spec
* Remove unnecessary page_view param
* Remove additional unnecessary page_view
* Create ApplicationMetalController for shared Metal behavior
* Revert rand numbers to ensure apples-to-apples perf compare
* Whoops, revert change revert
* Clarify comment
2019-11-25 19:06:34 -05:00
Ben Halpern
36479f09c3
Replace current_user.id with session_current_user_id ( #4880 ) [deploy]
...
* Replace current_user.id with efficient_current_user_id in high-leverage areas
* Update name of efficient_current_user_id
* Replace user_signed_in? in pageviews
* Remove unneeded ?
2019-11-22 14:27:43 -05:00
rhymes
7da7a16d8d
Pro: add referrers to dashboard and single article stats ( #3295 )
...
* Reorganize PageViewsController
* Add domain and path to PageView model
* Add before_create callback to populate domain and path
* Add list of referrers to AnalyticsService
* Add referrers to the UI
* Remove useless referrers card and tweak table line height
* Add referrer stats to article stats page
* Add not null and empty default to domain and path
* Refactor JS analytics client
* create_list is a step back here
* Revert "Add not null and empty default to domain and path"
This reverts commit bc02440076047a887c65d300bccd4661ecc8ffd0.
* Add index on domain concurrently
* Make the script more robust
2019-06-25 13:58:09 -04:00
Ben Halpern
4b1b137c0f
Fix/augment dashboard and article view count issues ( #2449 )
2019-04-15 10:24:38 -04:00
Ben Halpern
7bf37108b1
Night theme improvements + small fixes ( #2114 )
2019-03-19 13:36:30 -04:00
Ben Halpern
c901c7138d
Fix possible race condition with page view tracking ( #2103 )
...
* Fix possible race condition with page view tracking
* Change min number to check for html variant calculation
2019-03-18 15:53:13 -04:00
Ben Halpern
825aa9be91
Add page_view model ( #1985 )
...
* Add page_view model
* Uncomment DJ routes
* Add time on site max and don't update article page views every time
2019-03-07 11:53:33 -08:00