From afa73853ca08f159f35bab577e5133d3e7beb4cc Mon Sep 17 00:00:00 2001 From: richvdh Date: Tue, 17 Aug 2021 20:19:39 +0000 Subject: deploy: 430241a1e9fd4fbb82d83958b61bbd66c9ba3505 --- develop/print.html | 117 ++++++----------------------------------------------- 1 file changed, 13 insertions(+), 104 deletions(-) (limited to 'develop/print.html') diff --git a/develop/print.html b/develop/print.html index 150dc0f29c..f7caf14965 100644 --- a/develop/print.html +++ b/develop/print.html @@ -101,7 +101,7 @@ @@ -1546,6 +1546,16 @@ dpkg -i matrix-synapse-py3_1.3.0+stretch1_amd64.deb

Upgrading to v1.xx.0

+

Removal of old Room Admin API

+

The following admin APIs were deprecated in Synapse 1.25 +(released on 2021-01-13) and have now been removed:

+ +

Any scripts still using the above APIs should be converted to use the +Delete Room API.

+

Upgrading to v1.xx.0

Add support for routing outbound HTTP requests via a proxy for federation

Since Synapse 1.6.0 (2019-11-26) you can set a proxy for outbound HTTP requests via http_proxy/https_proxy environment variables. This proxy was set for:

@@ -9025,19 +9035,6 @@ server admin.

To reclaim the disk space and return it to the operating system, you need to run VACUUM FULL; on the database.

https://www.postgresql.org/docs/current/sql-vacuum.html

-

Deprecated: Purge room API

-

The old Purge room API is deprecated and will be removed in a future release. -See the new Delete Room API for more details.

-

This API will remove all trace of a room from your database.

-

All local users must have left the room before it can be removed.

-

The API is:

-
POST /_synapse/admin/v1/purge_room
-
-{
-    "room_id": "!room:id"
-}
-
-

You must authenticate using the access token of an admin user.

Shared-Secret Registration

This API allows for the creation of users in an administrative and non-interactive way. This is generally used for bootstrapping a Synapse @@ -9764,94 +9761,6 @@ ignored in the same way as with PUT /_matrix/client/r0/rooms/{roomId}/send

Note that server notices must be enabled in homeserver.yaml before this API can be used. See the server notices documentation for more information.

-

Deprecated: Shutdown room API

-

The old Shutdown room API is deprecated and will be removed in a future release. -See the new Delete Room API for more details.

-

Shuts down a room, preventing new joins and moves local users and room aliases automatically -to a new room. The new room will be created with the user specified by the -new_room_user_id parameter as room administrator and will contain a message -explaining what happened. Users invited to the new room will have power level --10 by default, and thus be unable to speak. The old room's power levels will be changed to -disallow any further invites or joins.

-

The local server will only have the power to move local user and room aliases to -the new room. Users on other servers will be unaffected.

-

API

-

You will need to authenticate with an access token for an admin user.

-

URL

-

POST /_synapse/admin/v1/shutdown_room/{room_id}

-

URL Parameters

- -

JSON Body Parameters

- -

If not specified, the default value of room_name is "Content Violation -Notification". The default value of message is "Sharing illegal content on -othis server is not permitted and rooms in violation will be blocked."

-

Response Parameters

- -

Example

-

Request:

-
POST /_synapse/admin/v1/shutdown_room/!somebadroom%3Aexample.com
-
-{
-    "new_room_user_id": "@someuser:example.com",
-    "room_name": "Content Violation Notification",
-    "message": "Bad Room has been shutdown due to content violations on this server. Please review our Terms of Service."
-}
-
-

Response:

-
{
-    "kicked_users": 5,
-    "failed_to_kick_users": 0,
-    "local_aliases": ["#badroom:example.com", "#evilsaloon:example.com],
-    "new_room_id": "!newroomid:example.com",
-},
-
-

Undoing room shutdowns

-

Note: This guide may be outdated by the time you read it. By nature of room shutdowns being performed at the database level, -the structure can and does change without notice.

-

First, it's important to understand that a room shutdown is very destructive. Undoing a shutdown is not as simple as pretending it -never happened - work has to be done to move forward instead of resetting the past. In fact, in some cases it might not be possible -to recover at all:

- -

With all that being said, if you still want to try and recover the room:

-
    -
  1. For safety reasons, shut down Synapse.
  2. -
  3. In the database, run DELETE FROM blocked_rooms WHERE room_id = '!example:example.org'; -
      -
    • For caution: it's recommended to run this in a transaction: BEGIN; DELETE ...;, verify you got 1 result, then COMMIT;.
    • -
    • The room ID is the same one supplied to the shutdown room API, not the Content Violation room.
    • -
    -
  4. -
  5. Restart Synapse.
  6. -
-

You will have to manually handle, if you so choose, the following:

-

Users' media usage statistics

Returns information about all local media usage of users. Gives the possibility to filter them by time and user.

@@ -12448,7 +12357,7 @@ connection errors.

received for each stream so that on reconneciton it can start streaming from the correct place. Note: not all RDATA have valid tokens due to batching. See RdataCommand for more details.

-

Example

+

Example

An example iteraction is shown below. Each line is prefixed with '>' or '<' to indicate which side is sending, these are not included on the wire:

@@ -12744,7 +12653,7 @@ graph), and one where we remove redundant links (the transitive reduction of the links graph) e.g. if we have chains C3 -> C2 -> C1 then the link C3 -> C1 would not be stored. Synapse uses the former implementations so that it doesn't need to recurse to test reachability between chains.

-

Example

+

Example

An example auth graph would look like the following, where chains have been formed based on type/state_key and are denoted by colour and are labelled with (chain ID, sequence number). Links are denoted by the arrows (links in grey -- cgit 1.5.1