Skip to content

Commit a38baa5

Browse files
authored
Merge pull request #2684 from umami-software/hotfix2
v2.11.2
2 parents be7f69f + 2a43d0b commit a38baa5

128 files changed

Lines changed: 4081 additions & 631 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
Lines changed: 57 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,57 @@
1+
CREATE TABLE umami.event_data_new
2+
(
3+
website_id UUID,
4+
session_id UUID,
5+
event_id UUID,
6+
url_path String,
7+
event_name String,
8+
data_key String,
9+
string_value Nullable(String),
10+
number_value Nullable(Decimal64(4)),
11+
date_value Nullable(DateTime('UTC')),
12+
data_type UInt32,
13+
created_at DateTime('UTC'),
14+
job_id Nullable(UUID)
15+
)
16+
engine = MergeTree
17+
ORDER BY (website_id, event_id, data_key, created_at)
18+
SETTINGS index_granularity = 8192;
19+
20+
INSERT INTO umami.event_data_new
21+
SELECT website_id,
22+
session_id,
23+
event_id,
24+
url_path,
25+
event_name,
26+
event_key,
27+
string_value,
28+
number_value,
29+
date_value,
30+
data_type,
31+
created_at,
32+
NULL
33+
FROM umami.event_data;
34+
35+
CREATE TABLE umami.session_data
36+
(
37+
website_id UUID,
38+
session_id UUID,
39+
data_key String,
40+
string_value Nullable(String),
41+
number_value Nullable(Decimal64(4)),
42+
date_value Nullable(DateTime('UTC')),
43+
data_type UInt32,
44+
created_at DateTime('UTC'),
45+
job_id Nullable(UUID)
46+
)
47+
engine = MergeTree
48+
ORDER BY (website_id, session_id, data_key, created_at)
49+
SETTINGS index_granularity = 8192;
50+
51+
RENAME TABLE umami.event_data TO umami.event_data_old;
52+
RENAME TABLE umami.event_data_new TO umami.event_data;
53+
54+
/*
55+
DROP TABLE umami.event_data_old
56+
*/
57+

db/clickhouse/schema.sql

Lines changed: 21 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ CREATE TABLE umami.website_event
2727
event_type UInt32,
2828
event_name String,
2929
created_at DateTime('UTC'),
30-
job_id UUID
30+
job_id Nullable(UUID)
3131
)
3232
engine = MergeTree
3333
ORDER BY (website_id, session_id, created_at)
@@ -40,14 +40,30 @@ CREATE TABLE umami.event_data
4040
event_id UUID,
4141
url_path String,
4242
event_name String,
43-
event_key String,
43+
data_key String,
4444
string_value Nullable(String),
45-
number_value Nullable(Decimal64(4)), --922337203685477.5625
45+
number_value Nullable(Decimal64(4)),
4646
date_value Nullable(DateTime('UTC')),
4747
data_type UInt32,
4848
created_at DateTime('UTC'),
49-
job_id UUID
49+
job_id Nullable(UUID)
5050
)
5151
engine = MergeTree
52-
ORDER BY (website_id, event_id, event_key, created_at)
52+
ORDER BY (website_id, event_id, data_key, created_at)
53+
SETTINGS index_granularity = 8192;
54+
55+
CREATE TABLE umami.session_data
56+
(
57+
website_id UUID,
58+
session_id UUID,
59+
data_key String,
60+
string_value Nullable(String),
61+
number_value Nullable(Decimal64(4)),
62+
date_value Nullable(DateTime('UTC')),
63+
data_type UInt32,
64+
created_at DateTime('UTC'),
65+
job_id Nullable(UUID)
66+
)
67+
engine = MergeTree
68+
ORDER BY (website_id, session_id, data_key, created_at)
5369
SETTINGS index_granularity = 8192;
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
-- DropIndex
2+
DROP INDEX `event_data_website_id_created_at_event_key_idx` ON `event_data`;
3+
4+
-- DropIndex
5+
DROP INDEX `event_data_website_id_website_event_id_created_at_idx` ON `event_data`;
6+
7+
-- AlterTable
8+
ALTER TABLE `event_data` RENAME COLUMN `event_key` TO `data_key`;
9+
10+
-- AlterTable
11+
ALTER TABLE `session_data` RENAME COLUMN `event_key` TO `data_key`;
12+
13+
-- CreateIndex
14+
CREATE INDEX `event_data_website_id_created_at_data_key_idx` ON `event_data`(`website_id`, `created_at`, `data_key`);
15+
16+
-- CreateIndex
17+
CREATE INDEX `session_data_session_id_created_at_idx` ON `session_data`(`session_id`, `created_at`);
18+
19+
-- CreateIndex
20+
CREATE INDEX `session_data_website_id_created_at_data_key_idx` ON `session_data`(`website_id`, `created_at`, `data_key`);

db/mysql/schema.prisma

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -125,7 +125,7 @@ model EventData {
125125
id String @id() @map("event_data_id") @db.VarChar(36)
126126
websiteId String @map("website_id") @db.VarChar(36)
127127
websiteEventId String @map("website_event_id") @db.VarChar(36)
128-
eventKey String @map("event_key") @db.VarChar(500)
128+
dataKey String @map("data_key") @db.VarChar(500)
129129
stringValue String? @map("string_value") @db.VarChar(500)
130130
numberValue Decimal? @map("number_value") @db.Decimal(19, 4)
131131
dateValue DateTime? @map("date_value") @db.Timestamp(0)
@@ -138,17 +138,16 @@ model EventData {
138138
@@index([createdAt])
139139
@@index([websiteId])
140140
@@index([websiteEventId])
141-
@@index([websiteId, websiteEventId, createdAt])
142141
@@index([websiteId, createdAt])
143-
@@index([websiteId, createdAt, eventKey])
142+
@@index([websiteId, createdAt, dataKey])
144143
@@map("event_data")
145144
}
146145

147146
model SessionData {
148147
id String @id() @map("session_data_id") @db.VarChar(36)
149148
websiteId String @map("website_id") @db.VarChar(36)
150149
sessionId String @map("session_id") @db.VarChar(36)
151-
eventKey String @map("event_key") @db.VarChar(500)
150+
dataKey String @map("data_key") @db.VarChar(500)
152151
stringValue String? @map("string_value") @db.VarChar(500)
153152
numberValue Decimal? @map("number_value") @db.Decimal(19, 4)
154153
dateValue DateTime? @map("date_value") @db.Timestamp(0)
@@ -161,6 +160,8 @@ model SessionData {
161160
@@index([createdAt])
162161
@@index([websiteId])
163162
@@index([sessionId])
163+
@@index([sessionId, createdAt])
164+
@@index([websiteId, createdAt, dataKey])
164165
@@map("session_data")
165166
}
166167

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
-- DropIndex
2+
DROP INDEX IF EXISTS "event_data_website_id_created_at_event_key_idx";
3+
4+
-- AlterTable
5+
ALTER TABLE "event_data" RENAME COLUMN "event_key" TO "data_key";
6+
7+
-- AlterTable
8+
ALTER TABLE "session_data" DROP COLUMN "deleted_at";
9+
ALTER TABLE "session_data" RENAME COLUMN "session_key" TO "data_key";
10+
11+
-- CreateIndex
12+
CREATE INDEX "event_data_website_id_created_at_data_key_idx" ON "event_data"("website_id", "created_at", "data_key");
13+
14+
-- CreateIndex
15+
CREATE INDEX "session_data_session_id_created_at_idx" ON "session_data"("session_id", "created_at");
16+
17+
-- CreateIndex
18+
CREATE INDEX "session_data_website_id_created_at_data_key_idx" ON "session_data"("website_id", "created_at", "data_key");

db/postgresql/schema.prisma

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -125,7 +125,7 @@ model EventData {
125125
id String @id() @map("event_data_id") @db.Uuid
126126
websiteId String @map("website_id") @db.Uuid
127127
websiteEventId String @map("website_event_id") @db.Uuid
128-
eventKey String @map("event_key") @db.VarChar(500)
128+
dataKey String @map("data_key") @db.VarChar(500)
129129
stringValue String? @map("string_value") @db.VarChar(500)
130130
numberValue Decimal? @map("number_value") @db.Decimal(19, 4)
131131
dateValue DateTime? @map("date_value") @db.Timestamptz(6)
@@ -139,28 +139,29 @@ model EventData {
139139
@@index([websiteId])
140140
@@index([websiteEventId])
141141
@@index([websiteId, createdAt])
142-
@@index([websiteId, createdAt, eventKey])
142+
@@index([websiteId, createdAt, dataKey])
143143
@@map("event_data")
144144
}
145145

146146
model SessionData {
147147
id String @id() @map("session_data_id") @db.Uuid
148148
websiteId String @map("website_id") @db.Uuid
149149
sessionId String @map("session_id") @db.Uuid
150-
sessionKey String @map("session_key") @db.VarChar(500)
150+
dataKey String @map("data_key") @db.VarChar(500)
151151
stringValue String? @map("string_value") @db.VarChar(500)
152152
numberValue Decimal? @map("number_value") @db.Decimal(19, 4)
153153
dateValue DateTime? @map("date_value") @db.Timestamptz(6)
154154
dataType Int @map("data_type") @db.Integer
155155
createdAt DateTime? @default(now()) @map("created_at") @db.Timestamptz(6)
156-
deletedAt DateTime? @default(now()) @map("deleted_at") @db.Timestamptz(6)
157156
158157
website Website @relation(fields: [websiteId], references: [id])
159158
session Session @relation(fields: [sessionId], references: [id])
160159
161160
@@index([createdAt])
162161
@@index([websiteId])
163162
@@index([sessionId])
163+
@@index([sessionId, createdAt])
164+
@@index([websiteId, createdAt, dataKey])
164165
@@map("session_data")
165166
}
166167

package.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "umami",
3-
"version": "2.11.1",
3+
"version": "2.11.2",
44
"description": "A simple, fast, privacy-focused alternative to Google Analytics.",
55
"author": "Umami Software, Inc. <hello@umami.is>",
66
"license": "MIT",
@@ -66,7 +66,7 @@
6666
"dependencies": {
6767
"@clickhouse/client": "^0.2.2",
6868
"@fontsource/inter": "^4.5.15",
69-
"@prisma/client": "5.11.0",
69+
"@prisma/client": "5.12.1",
7070
"@prisma/extension-read-replicas": "^0.3.0",
7171
"@react-spring/web": "^9.7.3",
7272
"@tanstack/react-query": "^5.28.6",
@@ -102,7 +102,7 @@
102102
"next-basics": "^0.39.0",
103103
"node-fetch": "^3.2.8",
104104
"npm-run-all": "^4.1.5",
105-
"prisma": "5.11.0",
105+
"prisma": "5.12.1",
106106
"react": "^18.2.0",
107107
"react-basics": "^0.123.0",
108108
"react-beautiful-dnd": "^13.1.0",

public/intl/messages/am-ET.json

Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,12 @@
3535
"value": "Add member"
3636
}
3737
],
38+
"label.add-step": [
39+
{
40+
"type": 0,
41+
"value": "Add step"
42+
}
43+
],
3844
"label.add-website": [
3945
{
4046
"type": 0,
@@ -555,6 +561,20 @@
555561
"value": " hours"
556562
}
557563
],
564+
"label.last-months": [
565+
{
566+
"type": 0,
567+
"value": "Last "
568+
},
569+
{
570+
"type": 1,
571+
"value": "x"
572+
},
573+
{
574+
"type": 0,
575+
"value": " months"
576+
}
577+
],
558578
"label.leave": [
559579
{
560580
"type": 0,
@@ -965,6 +985,12 @@
965985
"value": "Single day"
966986
}
967987
],
988+
"label.steps": [
989+
{
990+
"type": 0,
991+
"value": "Steps"
992+
}
993+
],
968994
"label.sum": [
969995
{
970996
"type": 0,
@@ -1139,6 +1165,12 @@
11391165
"value": "Untitled"
11401166
}
11411167
],
1168+
"label.update": [
1169+
{
1170+
"type": 0,
1171+
"value": "Update"
1172+
}
1173+
],
11421174
"label.url": [
11431175
{
11441176
"type": 0,
@@ -1169,6 +1201,18 @@
11691201
"value": "Users"
11701202
}
11711203
],
1204+
"label.utm": [
1205+
{
1206+
"type": 0,
1207+
"value": "UTM"
1208+
}
1209+
],
1210+
"label.utm-description": [
1211+
{
1212+
"type": 0,
1213+
"value": "Track your campaigns through UTM parameters."
1214+
}
1215+
],
11721216
"label.value": [
11731217
{
11741218
"type": 0,
@@ -1199,12 +1243,24 @@
11991243
"value": "Views"
12001244
}
12011245
],
1246+
"label.views-per-visit": [
1247+
{
1248+
"type": 0,
1249+
"value": "Views per visit"
1250+
}
1251+
],
12021252
"label.visitors": [
12031253
{
12041254
"type": 0,
12051255
"value": "Visitors"
12061256
}
12071257
],
1258+
"label.visits": [
1259+
{
1260+
"type": 0,
1261+
"value": "Visits"
1262+
}
1263+
],
12081264
"label.website": [
12091265
{
12101266
"type": 0,

0 commit comments

Comments
 (0)