Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added env var developer mode setting #7515

Merged
merged 6 commits into from
Nov 12, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
32 changes: 11 additions & 21 deletions source/configure/environment-configuration-settings.rst
Original file line number Diff line number Diff line change
Expand Up @@ -4161,28 +4161,18 @@ This setting isn't available in the System Console and can only be set in ``conf
| This feature's ``config.json`` setting is ``"EnableAPIChannelDeletion": false`` with options ``true`` and ``false``. |
+----------------------------------------------------------------------------------------------------------------------+

.. config:setting:: exp-enableapipostdeletion
:displayname: Enable API post deletion (ServiceSettings)
:systemconsole: N/A
:configjson: EnableAPIPostDeletion
:environment: N/A

- **true**: The ``api/v4/posts/{postid}?permanent=true`` API endpoint can be called by system admins (or users with appropriate permissions), or by running the mmctl post delete command, to permanently delete a message and its attachments.
- **false**: **(Default)** The API endpoint cannot be called, but ``api/v4/posts/{postid}`` can still be used to soft delete a message without removing it from the database.

Enable API post deletion
~~~~~~~~~~~~~~~~~~~~~~~~

This setting isn't available in the System Console and can only be set in ``config.json``.

**True**: The ``api/v4/posts/{postid}?permanent=true`` API endpoint can be called by system admins (or users with appropriate permissions), or by running the :ref:`mmctl post delete <manage/mmctl-command-line-tool:mmctl post delete>` command, to permanently delete a message and its attachments.
Enable desktop app developer mode
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

**False**: The API endpoint cannot be called. Note that ``api/v4/posts/{postid}`` can still be used to soft delete a channel without removing it from the database.
From Desktop App v5.10, this setting enables developer debugging options available by going to the **View > Developer Tools** menu in the Mattermost desktop app.

+----------------------------------------------------------------------------------------------------------------------+
| This feature's ``config.json`` setting is ``"EnableAPIPostDeletion": false`` with options ``true`` and ``false``. |
+----------------------------------------------------------------------------------------------------------------------+
This setting isn't available in the System Console and can only be enabled in ``config.json`` by setting the environment variable ``MM_DESKTOP_DEVELOPER_MODE`` to ``true``. This setting is disabled by default.

.. note::
**True**: Unlocks the following options in the Desktop App for the purposes of troubleshooting and debugging. You should only enable this setting if instructed to by a Mattermost developer:

This configuration setting doesn't need to be enabled when running :doc:`mmctl </manage/mmctl-command-line-tool>` in :ref:`local mode <manage/mmctl-command-line-tool:local mode>`.
* **Browser Mode Only**: Completely disables the preload script and stops web app components from knowing they're in the desktop app. This option should be the best indicator of whether a web app component is causing performance and/or memory retention issues. This option disables notifications, cross-tab navigation, unread/mentions badges, the calls widget, and breaks resizing on macOS.
* **Disable Notification Storage**: Turns off maps that hold references to unread notifications until they've been selected & read. This option is good for debugging in cases where Mattermost is holding onto too many references to unused notifications.
* **Disable User Activity Monitor**: Turns off the interval that checks whether the user is away or not. This option is good for debugging whether a user's availability status is causing unexpected desktop app behavior.
* **Disable Context Menu**: Turns off the context menu attached to the BrowserViews. This option is good as a library santity check.
* **Force Legacy Messaging API**: Forces the app to revert back to the old messaging API instead of the newer contextBridge API. This option is a good santity check to confirm whether the new API is responsible for holding onto memory.
* **Force New Messaging API**: Forces the app to use the contextBridge API and completely disables the legacy one. This option forces off listeners for the legacy API.
Loading