Skip to content

Commit 8980e17

Browse files
committed
Add 26.01 upgrade notes
1 parent 5824f05 commit 8980e17

2 files changed

Lines changed: 123 additions & 0 deletions

File tree

content/admin/upgrade/index.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -101,6 +101,7 @@ of the new ejabberd version if you need to update those tables yourself manually
101101
The corresponsing ugprade notes are available in the release notes of each release,
102102
and also available in the [Archive](../../archive/index.md) section:
103103

104+
- [Upgrading from ejabberd 25.10 to 26.01](../../archive/26.01/upgrade.md)
104105
- [Upgrading from ejabberd 25.08 to 25.10](../../archive/25.10/upgrade.md)
105106
- [Upgrading from ejabberd 25.07 to 25.08](../../archive/25.08/upgrade.md)
106107
- [Upgrading from ejabberd 25.04 to 25.07](../../archive/25.07/upgrade.md)

content/archive/26.01/upgrade.md

Lines changed: 122 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,122 @@
1+
# Upgrade to ejabberd 26.01
2+
3+
If you upgrade ejabberd from a previous release to [26.01](../../archive/26.01/index.md),
4+
please check the proposed changes in SQL schema below.
5+
6+
There are no mandatory changes in SQL schemas, configuration, API commands or hooks.
7+
8+
## <a name="sql"></a>SQL table for `mod_invites`
9+
10+
There is a new table `invite_token` in SQL schemas, used by the new `mod_invites`.
11+
If you want to use this module,
12+
there are two methods to update the SQL schema of your existing database:
13+
14+
If using MySQL or PosgreSQL, you can enable the option [`update_sql_schema`](../../admin/configuration/toplevel.md#update_sql_schema) and ejabberd will take care to update the SQL schema when needed: add in your ejabberd configuration file the line `update_sql_schema: true`
15+
16+
Notice that support for MSSQL in `mod_invites` has not yet been implemented or tested.
17+
18+
If you are using other database, or prefer to update manually the SQL schema:
19+
20+
* MySQL singlehost schema:
21+
22+
``` sql
23+
CREATE TABLE invite_token (
24+
token text NOT NULL,
25+
username text NOT NULL,
26+
invitee text NOT NULL DEFAULT (''),
27+
created_at timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
28+
expires timestamp NOT NULL,
29+
type character(1) NOT NULL,
30+
account_name text NOT NULL,
31+
PRIMARY KEY (token(191))
32+
) ENGINE=InnoDB CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci;
33+
34+
CREATE INDEX i_invite_token_username USING BTREE ON invite_token(username(191));
35+
```
36+
37+
* MySQL multihost schema:
38+
39+
``` sql
40+
CREATE TABLE invite_token (
41+
token text NOT NULL,
42+
username text NOT NULL,
43+
server_host varchar(191) NOT NULL,
44+
invitee text NOT NULL DEFAULT '',
45+
created_at timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
46+
expires timestamp NOT NULL,
47+
type character(1) NOT NULL,
48+
account_name text NOT NULL,
49+
PRIMARY KEY (token(191)),
50+
) ENGINE=InnoDB CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci;
51+
52+
CREATE INDEX i_invite_token_username USING BTREE ON invite_token(username(191));
53+
```
54+
55+
* PostgreSQL singlehost schema:
56+
57+
``` sql
58+
CREATE TABLE invite_token (
59+
token text NOT NULL,
60+
username text NOT NULL,
61+
invitee text NOT NULL DEFAULT '',
62+
created_at timestamp NOT NULL DEFAULT now(),
63+
expires timestamp NOT NULL,
64+
"type" character(1) NOT NULL,
65+
account_name text NOT NULL,
66+
PRIMARY KEY (token)
67+
);
68+
CREATE INDEX i_invite_token_username ON invite_token USING btree (username);
69+
```
70+
71+
* PostgreSQL multihost schema:
72+
73+
``` sql
74+
CREATE TABLE invite_token (
75+
token text NOT NULL,
76+
username text NOT NULL,
77+
server_host text NOT NULL,
78+
invitee text NOT NULL DEFAULT '',
79+
created_at timestamp NOT NULL DEFAULT now(),
80+
expires timestamp NOT NULL,
81+
"type" character(1) NOT NULL,
82+
account_name text NOT NULL,
83+
PRIMARY KEY (token)
84+
);
85+
86+
CREATE INDEX i_invite_token_username_server_host ON invite_token USING btree (username, server_host);
87+
```
88+
89+
* SQLite singlehost schema:
90+
91+
``` sql
92+
CREATE TABLE invite_token (
93+
token text NOT NULL,
94+
username text NOT NULL,
95+
invitee text NOT NULL DEFAULT '',
96+
created_at timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
97+
expires timestamp NOT NULL,
98+
type character(1) NOT NULL,
99+
account_name text NOT NULL,
100+
PRIMARY KEY (token)
101+
);
102+
103+
CREATE INDEX i_invite_token_username ON invite_token(username);
104+
```
105+
106+
* SQLite multihost schema:
107+
108+
``` sql
109+
CREATE TABLE invite_token (
110+
token text NOT NULL,
111+
username text NOT NULL,
112+
server_host text NOT NULL,
113+
invitee text NOT NULL DEFAULT '',
114+
created_at timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
115+
expires timestamp NOT NULL,
116+
type character(1) NOT NULL,
117+
account_name text NOT NULL,
118+
PRIMARY KEY (token)
119+
);
120+
121+
CREATE INDEX i_invite_token_username_server_host ON invite_token(username, server_host);
122+
```

0 commit comments

Comments
 (0)