Skip to content

Commit 5492d74

Browse files
Al2Klimovjulianbrost
authored andcommitted
Schema: don't limit browser_session.user_agent to 4096 chars
1 parent e9ae2de commit 5492d74

File tree

4 files changed

+4
-2
lines changed

4 files changed

+4
-2
lines changed

schema/mysql/schema.sql

+1-1
Original file line numberDiff line numberDiff line change
@@ -448,7 +448,7 @@ CREATE INDEX idx_incident_history_time_type ON incident_history(time, type) COMM
448448
CREATE TABLE browser_session (
449449
php_session_id varchar(256) NOT NULL,
450450
username varchar(254) NOT NULL COLLATE utf8mb4_unicode_ci,
451-
user_agent varchar(4096) NOT NULL,
451+
user_agent text NOT NULL,
452452
authenticated_at bigint NOT NULL,
453453

454454
CONSTRAINT pk_browser_session PRIMARY KEY (php_session_id)

schema/mysql/upgrades/035.sql

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
ALTER TABLE browser_session MODIFY COLUMN user_agent text NOT NULL;

schema/pgsql/schema.sql

+1-1
Original file line numberDiff line numberDiff line change
@@ -493,7 +493,7 @@ COMMENT ON INDEX idx_incident_history_time_type IS 'Incident History ordered by
493493
CREATE TABLE browser_session (
494494
php_session_id varchar(256) NOT NULL,
495495
username citext NOT NULL,
496-
user_agent varchar(4096) NOT NULL,
496+
user_agent text NOT NULL,
497497
authenticated_at bigint NOT NULL,
498498

499499
CONSTRAINT pk_browser_session PRIMARY KEY (php_session_id),

schema/pgsql/upgrades/035.sql

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
ALTER TABLE browser_session ALTER COLUMN user_agent TYPE text;

0 commit comments

Comments
 (0)