Dendrite is a second-generation Matrix homeserver written in Go! https://element-hq.github.io/dendrite/
Find a file
dependabot[bot] 4643eb89e1
Some checks are pending
Dendrite / WASM build test (push) Waiting to run
Dendrite / Linting (push) Waiting to run
Dendrite / Unit tests (push) Waiting to run
Dendrite / Build for Linux (push) Waiting to run
Dendrite / Build for Windows (push) Waiting to run
Dendrite / Initial tests passed (push) Blocked by required conditions
Dendrite / Integration tests (push) Blocked by required conditions
Dendrite / Upgrade tests (push) Blocked by required conditions
Dendrite / Upgrade tests from HEAD-2 (push) Blocked by required conditions
Dendrite / Sytest (SQLite Cgo) (push) Blocked by required conditions
Dendrite / Sytest (PostgreSQL) (push) Blocked by required conditions
Dendrite / Sytest (SQLite native) (push) Blocked by required conditions
Dendrite / Complement (PostgreSQL) (push) Blocked by required conditions
Dendrite / Complement (SQLite native) (push) Blocked by required conditions
Dendrite / Complement (SQLite Cgo) (push) Blocked by required conditions
Dendrite / Integration tests passed (push) Blocked by required conditions
Dendrite / Update Docker images (push) Blocked by required conditions
Bump github.com/nats-io/nats.go from 1.42.0 to 1.44.0 (#3621)
Bumps [github.com/nats-io/nats.go](https://github.com/nats-io/nats.go)
from 1.42.0 to 1.44.0.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/nats-io/nats.go/releases">github.com/nats-io/nats.go's
releases</a>.</em></p>
<blockquote>
<h2>Release v1.44.0</h2>
<h2>Changelog</h2>
<h2>Overview</h2>
<p>This PR adds a <code>PushConsumer</code> implementation to
<code>jetstream</code>, allowing easier migration to new API while
maintaining usage of push consumers. For now it only supports the
callback-based <code>Consume()</code>, more consuming options will be
added in future releases.</p>
<h3>ADDED</h3>
<ul>
<li>Core NATS:
<ul>
<li><code>UserCredentialBytes()</code> <code>Conn</code> option (<a
href="https://redirect.github.com/nats-io/nats.go/issues/1877">#1877</a>)</li>
</ul>
</li>
<li>JetStream:
<ul>
<li><code>PushConsumer</code> implementation in <code>jetstream</code>
package</li>
<li>Expose <code>ClientTrace</code> in <code>JetStreamOptions</code> (<a
href="https://redirect.github.com/nats-io/nats.go/issues/1886">#1886</a>)</li>
</ul>
</li>
<li>Service API:
<ul>
<li>Expose <code>WithEndpointPendingLimits</code> option (<a
href="https://redirect.github.com/nats-io/nats.go/issues/1899">#1899</a>)</li>
</ul>
</li>
<li>Legacy KeyValue:
<ul>
<li><code>Error()</code> method to <code>KeyLister</code> and
<code>KeyWatcher</code> interfaces (<a
href="https://redirect.github.com/nats-io/nats.go/issues/1889">#1889</a>)</li>
</ul>
</li>
</ul>
<h3>FIXED</h3>
<ul>
<li>Core NATS:
<ul>
<li>Fix timeoutWriter not recovering after first error (<a
href="https://redirect.github.com/nats-io/nats.go/issues/1896">#1896</a>)</li>
</ul>
</li>
<li>JetStream:
<ul>
<li><code>Consumer.Next()</code> hangs after connection is closed (<a
href="https://redirect.github.com/nats-io/nats.go/issues/1883">#1883</a>)</li>
<li>Fixed stream info request for strict mode (<a
href="https://redirect.github.com/nats-io/nats.go/issues/1887">#1887</a>)</li>
<li>Ordered consumer not closing on connection close (<a
href="https://redirect.github.com/nats-io/nats.go/issues/1885">#1885</a>)</li>
<li>Return a more appropriate error when Subject Transform is not
supported (<a
href="https://redirect.github.com/nats-io/nats.go/issues/1416">#1416</a>)</li>
<li>Fix subject transform comparison. Thanks <a
href="https://github.com/erikmansson"><code>@​erikmansson</code></a> for
the contribution (<a
href="https://redirect.github.com/nats-io/nats.go/issues/1907">#1907</a>)</li>
</ul>
</li>
<li>Legacy JetStream:
<ul>
<li>Use timeout from <code>JetStreamContext</code> if no deadline is set
on ctx (<a
href="https://redirect.github.com/nats-io/nats.go/issues/1909">#1909</a>)</li>
</ul>
</li>
<li>KeyValue:
<ul>
<li><code>Keys()</code> and <code>ListKeys()</code> returning duplicates
(<a
href="https://redirect.github.com/nats-io/nats.go/issues/1884">#1884</a>)</li>
<li>Fix subject prefix for the Create/Update operation in KV store.
Thanks <a
href="https://github.com/SalvaChiLlo"><code>@​SalvaChiLlo</code></a> for
the contribution (<a
href="https://redirect.github.com/nats-io/nats.go/issues/1903">#1903</a>)</li>
</ul>
</li>
</ul>
<h3>CHANGED</h3>
<ul>
<li>Change <code>DefaultSubPendingMsgsLimit</code> (<a
href="https://redirect.github.com/nats-io/nats.go/issues/998">#998</a>)</li>
</ul>
<h3>Complete Changes</h3>
<p><a
href="https://github.com/nats-io/nats.go/compare/v1.43.0...v1.44.0">https://github.com/nats-io/nats.go/compare/v1.43.0...v1.44.0</a></p>
<h2>Release v1.43.0</h2>
<h2>Changelog</h2>
<h3>ADDED</h3>
<ul>
<li>Core NATS:
<ul>
<li>Add <code>nc.LocalAddr</code>, similar to
<code>nc.ConnectedAddr</code> (<a
href="https://redirect.github.com/nats-io/nats.go/issues/1877">#1877</a>)</li>
</ul>
</li>
</ul>
<h3>FIXED</h3>
<ul>
<li>Service API:
<ul>
<li>Fix stopping service not unsubscribing from all endpoints. Thanks <a
href="https://github.com/arunsworld"><code>@​arunsworld</code></a> for
the contribution (<a
href="https://redirect.github.com/nats-io/nats.go/issues/1872">#1872</a>)</li>
</ul>
</li>
</ul>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="7a260b8b93"><code>7a260b8</code></a>
Release v1.44.0 (<a
href="https://redirect.github.com/nats-io/nats.go/issues/1910">#1910</a>)</li>
<li><a
href="dfcb02dcdc"><code>dfcb02d</code></a>
[FIXED] Use mirror-aware prefix when updating KV key (<a
href="https://redirect.github.com/nats-io/nats.go/issues/1903">#1903</a>)</li>
<li><a
href="0bba2a9842"><code>0bba2a9</code></a>
[ADDED] PushConsumer implementation in jetstream package (<a
href="https://redirect.github.com/nats-io/nats.go/issues/1785">#1785</a>)</li>
<li><a
href="627a9f63c2"><code>627a9f6</code></a>
[FIXED] KeyValue Keys() and ListKeys() returning duplicates (<a
href="https://redirect.github.com/nats-io/nats.go/issues/1884">#1884</a>)</li>
<li><a
href="9743171c2a"><code>9743171</code></a>
Merge pull request <a
href="https://redirect.github.com/nats-io/nats.go/issues/1909">#1909</a>
from nats-io/fix-watcher-timeout</li>
<li><a
href="3bd15a8026"><code>3bd15a8</code></a>
[FIXED] Use timeout from JetStreamContext if no deadline is set on
ctx</li>
<li><a
href="0fc96b1daa"><code>0fc96b1</code></a>
[FIXED] Fix subject transform comparison (<a
href="https://redirect.github.com/nats-io/nats.go/issues/1907">#1907</a>)</li>
<li><a
href="ea3ef92823"><code>ea3ef92</code></a>
[IMPROVED] Change DefaultSubPendingMsgsLimit comment to reflect actual
value ...</li>
<li><a
href="f038fb4bee"><code>f038fb4</code></a>
[FIXED] Return a more appropriate error when subject transforms are not
suppo...</li>
<li><a
href="ad6e34e1ae"><code>ad6e34e</code></a>
[FIXED] Ordered consumer not closing on connection close (<a
href="https://redirect.github.com/nats-io/nats.go/issues/1885">#1885</a>)</li>
<li>Additional commits viewable in <a
href="https://github.com/nats-io/nats.go/compare/v1.42.0...v1.44.0">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=github.com/nats-io/nats.go&package-manager=go_modules&previous-version=1.42.0&new-version=1.44.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-12 12:01:54 +01:00
.github Bump cypress-io/github-action from 6.7.10 to 6.10.0 (#3591) 2025-06-05 22:00:12 +02:00
appservice Update the license headers to mention the commercial license 2024-10-18 16:14:08 +02:00
build Fix building Pinecone and Yggrasil docker images (#3592) 2025-06-05 20:45:15 +02:00
clientapi Room version 12 (#3623) 2025-08-11 20:59:47 +01:00
cmd Bump go in docker images (#3582) 2025-05-17 21:05:45 +02:00
contrib Merge commit from fork 2025-01-16 19:35:50 +01:00
docs Update Gemfile for docs (#3615) 2025-07-28 14:38:35 +00:00
federationapi Demote wakeQueueIfEventsPending and thumbnailer log lines to debug (#3520) 2025-01-29 19:39:29 +01:00
helm Version v0.14.1 (#3501) 2025-01-16 19:42:51 +01:00
internal Room version 12 (#3623) 2025-08-11 20:59:47 +01:00
mediaapi Remove bimg thumbnailer (#3522) 2025-02-03 13:18:52 +01:00
relayapi Fix linting 2024-11-14 16:40:08 +01:00
roomserver Room version 12 (#3623) 2025-08-11 20:59:47 +01:00
setup Tweak NATS startup and readiness checking (#3523) 2025-02-03 22:01:56 +01:00
syncapi Room version 12 (#3623) 2025-08-11 20:59:47 +01:00
test Room version 12 (#3623) 2025-08-11 20:59:47 +01:00
userapi Room version 12 (#3623) 2025-08-11 20:59:47 +01:00
.dockerignore Add revision to version string (#3147) 2023-07-11 13:56:25 +02:00
.gitignore [helm] Update postgresql chart to 14.2.3 (#3292) 2024-02-29 08:46:40 +01:00
.golangci.yml Fix ordering issues in requesting backfill (#3530) 2025-05-16 17:11:29 +02:00
are-we-synapse-yet.list Support for room version v11 (#3204) 2023-09-27 08:27:08 +02:00
are-we-synapse-yet.py Add Are We Synapse Yet to GHA (#2321) 2022-04-05 15:32:30 +02:00
build-dendritejs.sh Add startup testing for Wasm Pinecone build (#1910) 2021-07-20 12:14:58 +01:00
CHANGES.md Version v0.14.1 (#3501) 2025-01-16 19:42:51 +01:00
CONTRIBUTING.md add DCO (#3395) 2024-07-25 15:24:35 +00:00
dendrite-sample.yaml Merge commit from fork 2025-01-16 19:35:50 +01:00
Dockerfile Bump go in docker images (#3582) 2025-05-17 21:05:45 +02:00
go.mod Bump github.com/nats-io/nats.go from 1.42.0 to 1.44.0 (#3621) 2025-08-12 12:01:54 +01:00
go.sum Bump github.com/nats-io/nats.go from 1.42.0 to 1.44.0 (#3621) 2025-08-12 12:01:54 +01:00
LICENSE Update license file 2024-10-17 17:21:06 +02:00
LICENSE-COMMERCIAL Add commercial license 2024-10-18 15:06:26 +02:00
README.md Update documentation links for new domain (#3545) 2025-06-05 20:51:38 +02:00
run-sytest.sh Use /usr/bin/env bash in shebangs to make them universal (#2735) 2022-09-27 09:42:08 +01:00
show-expected-fail-tests.sh Use /usr/bin/env bash in shebangs to make them universal (#2735) 2022-09-27 09:42:08 +01:00
sytest-blacklist Various fixes in fetchAuthEvents (#3447) 2024-12-17 19:18:05 +01:00
sytest-whitelist Support for fallback keys (#3451) 2024-12-17 19:19:15 +01:00
test-dendritejs.sh Add startup testing for Wasm Pinecone build (#1910) 2021-07-20 12:14:58 +01:00

Dendrite

Build status Dendrite Dendrite Dev

Dendrite is a second-generation Matrix homeserver written in Go. It intends to provide an efficient, reliable and scalable alternative to Synapse:

  • Efficient: A small memory footprint with better baseline performance than an out-of-the-box Synapse.
  • Reliable: Implements the Matrix specification as written, using the same test suite as Synapse as well as a brand new Go test suite.
  • Scalable: can run on multiple machines and eventually scale to massive homeserver deployments.

Dendrite is beta software, which means:

  • Dendrite is ready for early adopters. We recommend running Dendrite with a PostgreSQL database.
  • Dendrite has periodic releases. We intend to release new versions as we fix bugs and land significant features.
  • Dendrite supports database schema upgrades between releases. This means you should never lose your messages when upgrading Dendrite.

This does not mean:

  • Dendrite is bug-free. It has not yet been battle-tested in the real world and so will be error prone initially.
  • Dendrite is feature-complete. There may be client or federation APIs that are not implemented.
  • Dendrite is ready for massive homeserver deployments. There is no high-availability/clustering support.

Currently, we expect Dendrite to function well for small (10s/100s of users) homeserver deployments as well as P2P Matrix nodes in-browser or on mobile devices.

If you have further questions, please take a look at our FAQ or join us in:

Requirements

See the Planning your Installation page for more information on requirements.

To build Dendrite, you will need Go 1.21 or later.

For a usable federating Dendrite deployment, you will also need:

  • A domain name (or subdomain)
  • A valid TLS certificate issued by a trusted authority for that domain
  • SRV records or a well-known file pointing to your deployment

Also recommended are:

  • A PostgreSQL database engine, which will perform better than SQLite with many users and/or larger rooms
  • A reverse proxy server, such as nginx, configured like this sample

The Federation Tester can be used to verify your deployment.

Get started

If you wish to build a fully-federating Dendrite instance, see the Installation documentation. For running in Docker, see build/docker.

The following instructions are enough to get Dendrite started as a non-federating test deployment using self-signed certificates and SQLite databases:

$ git clone https://github.com/element-hq/dendrite
$ cd dendrite
$ go build -o bin/ ./cmd/...

# Generate a Matrix signing key for federation (required)
$ ./bin/generate-keys --private-key matrix_key.pem

# Generate a self-signed certificate (optional, but a valid TLS certificate is normally
# needed for Matrix federation/clients to work properly!)
$ ./bin/generate-keys --tls-cert server.crt --tls-key server.key

# Copy and modify the config file - you'll need to set a server name and paths to the keys
# at the very least, along with setting up the database connection strings.
$ cp dendrite-sample.yaml dendrite.yaml

# Build and run the server:
$ ./bin/dendrite --tls-cert server.crt --tls-key server.key --config dendrite.yaml

# Create an user account (add -admin for an admin user).
# Specify the localpart only, e.g. 'alice' for '@alice:domain.com'
$ ./bin/create-account --config dendrite.yaml --username alice

Then point your favourite Matrix client at http://localhost:8008 or https://localhost:8448.

Progress

We use a script called "Are We Synapse Yet" which checks Sytest compliance rates. Sytest is a black-box homeserver test rig with around 900 tests. The script works out how many of these tests are passing on Dendrite and it updates with CI. As of January 2023, we have 100% server-server parity with Synapse, and the client-server parity is at 93% , though check CI for the latest numbers. In practice, this means you can communicate locally and via federation with Synapse servers such as matrix.org reasonably well, although there are still some missing features (like SSO and Third-party ID APIs).

We are prioritising features that will benefit single-user homeservers first (e.g Receipts, E2E) rather than features that massive deployments may be interested in (OpenID, Guests, Admin APIs, AS API). This means Dendrite supports amongst others:

  • Core room functionality (creating rooms, invites, auth rules)
  • Room versions 1 to 10 supported
  • Backfilling locally and via federation
  • Accounts, profiles and devices
  • Published room lists
  • Typing
  • Media APIs
  • Redaction
  • Tagging
  • Context
  • E2E keys and device lists
  • Receipts
  • Push
  • Guests
  • User Directory
  • Presence
  • Fulltext search

Contributing

We would be grateful for any help on issues marked as Are We Synapse Yet. These issues all have related Sytests which need to pass in order for the issue to be closed. Once you've written your code, you can quickly run Sytest to ensure that the test names are now passing.

If you're new to the project, see our Contributing page to get up to speed, then look for Good First Issues. If you're familiar with the project, look for Help Wanted issues.

Copyright 2017 OpenMarket Ltd Copyright 2017 Vector Creations Ltd Copyright 2017-2025 New Vector Ltd

This software is dual-licensed by New Vector Ltd (Element). It can be used either:

(1) for free under the terms of the GNU Affero General Public License (as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version); OR

(2) under the terms of a paid-for Element Commercial License agreement between you and Element (the terms of which may vary depending on what you and Element have agreed to). Unless required by applicable law or agreed to in writing, software distributed under the Licenses is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the Licenses for the specific language governing permissions and limitations under the Licenses.