mirror of
https://github.com/discourse/discourse.git
synced 2026-08-06 13:08:40 +08:00
Previously, browser pageviews were persisted through the MessageBus piggyback path, which could miss navigation and unload events. This change records piggyback and sendBeacon pageviews in browser_pageview_events with a source, and uses the beacon transport for dashboard_improvements because keepalive requests can complete after page navigation starts. --------- Co-authored-by: Natalie Tay <natalie.tay@gmail.com>
7 lines
218 B
Ruby
Vendored
7 lines
218 B
Ruby
Vendored
# frozen_string_literal: true
|
|
|
|
class AddSourceToBrowserPageviewEvents < ActiveRecord::Migration[8.0]
|
|
def change
|
|
add_column :browser_pageview_events, :source, :integer, limit: 2, default: 1, null: false
|
|
end
|
|
end
|