Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
123 commits
Select commit Hold shift + click to select a range
841625e
fix: runtime setup error (#1520)
filipecabaco Sep 2, 2025
1b63b4f
fix: use primary instead of replica on rename_settings_field (#1521)
edgurgel Sep 3, 2025
da3404a
feat: upgrade cowboy & ranch (#1523)
edgurgel Sep 4, 2025
bd2c141
fix: Fix GenRpc to not try to connect to nodes that are not alive (#1…
edgurgel Sep 8, 2025
6cfe6e1
fix: enable presence on track message (#1527)
filipecabaco Sep 8, 2025
b13bb21
fix: set cowboy active_n=100 as cowboy 2.12.0 (#1530)
edgurgel Sep 10, 2025
a17ce3e
fix: provide error_code metadata on RealtimeChannel.Logging (#1531)
edgurgel Sep 12, 2025
eeba306
feat: disable UTF8 validation on websocket frames (#1532)
edgurgel Sep 14, 2025
70339c7
fix: move DB setup to happen after Connect.init (#1533)
edgurgel Sep 15, 2025
50891cd
fix: handle wal bloat (#1528)
filipecabaco Sep 15, 2025
5ccea17
feat: replay realtime.messages (#1526)
edgurgel Sep 16, 2025
c4ba2aa
feat: gen_rpc pub sub adapter (#1529)
edgurgel Sep 16, 2025
e8a343a
fix: ensure message id doesn't raise on non-map payloads (#1534)
edgurgel Sep 17, 2025
380b882
fix: match error on Connect (#1536)
filipecabaco Sep 18, 2025
4ba956f
feat: websocket max heap size configuration (#1538)
edgurgel Sep 22, 2025
1df809e
fix: update gen_rpc to fix gen_rpc_dispatcher issues (#1537)
edgurgel Sep 22, 2025
9a21897
fix: improve ErlSysMon logging for processes (#1540)
edgurgel Sep 22, 2025
54cd3f7
fix: make pubsub adapter configurable (#1539)
edgurgel Sep 22, 2025
e4ee7c8
fix: specify that only private channels are allowed when replaying (#…
edgurgel Sep 25, 2025
d4565df
fix: rate limit connect module (#1541)
filipecabaco Sep 26, 2025
d309c55
build: automatically cancel old tests/build on new push (#1545)
kevcodez Sep 27, 2025
a72a835
fix: move message queue data to off-heap for gen_rpc pub sub workers …
edgurgel Sep 30, 2025
353c142
fix: rate limit Connect.lookup_or_start_connection on error only (#1549)
edgurgel Oct 1, 2025
748398c
fix: increase connect error rate window to 30 seconds (#1550)
edgurgel Oct 1, 2025
92e7b59
fix: set a lower fullsweep_after flag for GenRpcPubSub workers (#1551)
edgurgel Oct 1, 2025
6248e2b
fix: hardcode presence limit (#1552)
filipecabaco Oct 2, 2025
e84ac08
fix: further decrease limit on presence events (#1553)
filipecabaco Oct 2, 2025
13052aa
fix: bump up realtime (#1554)
filipecabaco Oct 2, 2025
6e650f0
fix: lower rate limit to 100 events per second (#1556)
filipecabaco Oct 2, 2025
05ac93e
fix: move connect rate limit to socket (#1555)
filipecabaco Oct 2, 2025
e9eaf9f
fix: collect global metrics without tenant tagging (#1557)
edgurgel Oct 2, 2025
16bd44d
feat: presence payload size (#1559)
edgurgel Oct 5, 2025
07de665
fix: use GenRpc for Realtime.Latency pings (#1560)
edgurgel Oct 6, 2025
ecac071
Fastlane for phoenix presence_diff (#1558)
edgurgel Oct 6, 2025
058be58
fix: limit db events (#1562)
edgurgel Oct 7, 2025
d5658ad
chore: split tests and lint workflows (#1564)
edgurgel Oct 8, 2025
8b621bd
fix: use LiveView stream for status page (#1565)
chasers Oct 8, 2025
aeafab6
fix: refine join payload checking (#1567)
filipecabaco Oct 10, 2025
cbcbbfd
fix: shard user scopes in syn (#1566)
filipecabaco Oct 10, 2025
05ec589
chore: migrate workflows to Blacksmith runners (#1569)
blacksmith-sh[bot] Oct 13, 2025
b8dd5f3
feat: selective broadcast for postgres changes (#1573)
edgurgel Oct 14, 2025
c11f0a4
fix: set max_heap_size to RealtimeChannel the same as the websocket t…
edgurgel Oct 14, 2025
fc46833
fix: use gen_rpc on Postgres Changes (#1577)
edgurgel Oct 15, 2025
28d8609
chore: more async tests (#1578)
edgurgel Oct 15, 2025
c9ced7c
fix: validate size of track message (#1574)
filipecabaco Oct 15, 2025
617afae
fix: set sane defaults for presence event limit (#1544)
filipecabaco Oct 16, 2025
a125ba1
feat: bump up to 1.18 and otp28 (#1582)
filipecabaco Oct 20, 2025
9541666
fix: update gen_rpc with fullsweep_after=20 (#1581)
edgurgel Oct 20, 2025
0ffb34b
fix: on ReplicationPoller send only subscription IDs relevant to the …
edgurgel Oct 20, 2025
f44287e
feat: regional broadcasting (#1580)
edgurgel Oct 20, 2025
9adde30
chore: remove demo (old multiplayer.dev) (#1586)
edgurgel Oct 21, 2025
53c98c6
fix: use better key for node selection on regional broadcasting (#1585)
edgurgel Oct 21, 2025
5290aa1
fix: change CdcRls.WorkerSupervisor to be temporary instead of transi…
edgurgel Oct 22, 2025
c7ebd3f
fix: use node & name on syn conflict resolution (#1589)
edgurgel Oct 26, 2025
881b03f
fix: set realtime_subscription_{manager,checker} to 1 (#1590)
edgurgel Oct 26, 2025
7f28e0f
fix: change Node.all_node_regions to use syn (#1592)
edgurgel Oct 27, 2025
469f56d
feat: limit broadcast payload size (#1588)
filipecabaco Oct 27, 2025
0423825
fix: malformed PG changes subscriptions should not retry (#1593)
edgurgel Oct 27, 2025
b80da2d
fix: invalid PG changes subscriptions should not retry (#1595)
edgurgel Oct 28, 2025
dec8f0c
fix: multiple valid subscriptions (#1596)
edgurgel Oct 28, 2025
85e8120
chore: misc fixes (#1597)
edgurgel Oct 29, 2025
4653393
fix: scope postgres cdc syn registry (#1594)
filipecabaco Oct 29, 2025
35023f8
fix: add tenant_id tag to GenRpc calls from CdcRls (#1598)
edgurgel Oct 29, 2025
edfd830
fix: invalidate cache on any Tenant update (#1591)
edgurgel Oct 29, 2025
8e4d3e6
feat: measure replay latency (#1599)
edgurgel Oct 29, 2025
d7bacb8
fix: increment rate counter from ReplicationPoller only (#1584)
edgurgel Oct 31, 2025
ee66783
fix: subscriptions error rate limit (#1600)
edgurgel Oct 31, 2025
c8d6063
feat: encode PG change payload only once (#1601)
edgurgel Oct 31, 2025
60adbd8
fix: balance gen_rpc clients properly on GenRpcPubSub (#1603)
edgurgel Nov 2, 2025
9ee7c7e
feat: speed up poller by not re-encoding user data (#1605)
edgurgel Nov 3, 2025
ced9ca3
chore: several test fixes (#1604)
edgurgel Nov 3, 2025
7c0b073
feat: speed up messages replication by avoiding re-encoding JSON (#1602)
edgurgel Nov 4, 2025
cdee480
fix: set db events rate as tenant.max_events_per_second (#1608)
edgurgel Nov 6, 2025
2dee051
chore: speed up Realtime.Api tests + async: true (#1610)
edgurgel Nov 7, 2025
9120f89
feat: add cluster log metadata (#1609)
edgurgel Nov 9, 2025
6a220e7
feat: realtime v2 serializer (#1606)
edgurgel Nov 9, 2025
30abb49
chore: fix flaky tests (#1611)
edgurgel Nov 11, 2025
ef3ae47
chore: force RateCounter tick during tests (#1613)
edgurgel Nov 11, 2025
3413b25
chore: update README.md (#1612)
edgurgel Nov 11, 2025
db2415b
fix: improve boolean handling (#1614)
filipecabaco Nov 11, 2025
1eaca76
fix: message dispatcher cache (#1615)
edgurgel Nov 12, 2025
97f85f0
fix: provide microsecond granularity by using binary pgoutput mode (#…
filipecabaco Nov 12, 2025
37ff451
feat: collect serializer on phoenix socket connected metric (#1616)
edgurgel Nov 18, 2025
0de9c16
chore: fix flaky test due to timing (#1619)
edgurgel Nov 18, 2025
9c1dcba
chore: fix flaky gen rpc pub sub test (#1621)
edgurgel Nov 19, 2025
d266b54
chore: use supabase-js@latest on integration tests (#1622)
edgurgel Nov 19, 2025
55bac25
feat: tenant crud operations are region aware (#1620)
filipecabaco Nov 20, 2025
d412b66
fix: replica module startup (#1626)
filipecabaco Nov 24, 2025
253b6cc
fix: remove Realtime.Repo requirements (#1627)
filipecabaco Nov 24, 2025
c41c4fe
fix: replicate pg_output issue (#1625)
filipecabaco Nov 25, 2025
25a40df
feat: v2 user broadcast push metadata (#1629)
edgurgel Nov 26, 2025
118dfc5
fix: no-op when presence track is issued with the same payload (#1631)
edgurgel Nov 27, 2025
6bd29b8
chore: fix integration test expectation (#1630)
edgurgel Nov 27, 2025
1cd0319
chore: fix test telemetry attaching to only expected tenant (#1635)
edgurgel Nov 28, 2025
6830a19
fix: improve crud remote calls (#1633)
filipecabaco Nov 28, 2025
ac87c47
fix: change ReplicationConnection to ignore unknown tables (#1639)
edgurgel Dec 3, 2025
40bf817
fix: gather connected metrics for all tenants (#1637)
edgurgel Dec 3, 2025
395a097
feat: peep storage for PromEx (#1636)
edgurgel Dec 3, 2025
46f2f0c
chore: use lifo on poolboy for tests (#1640)
edgurgel Dec 3, 2025
f081221
chore: fix promex tenant plugin test timing issue (#1641)
edgurgel Dec 3, 2025
f4cf403
fix: measure traffic at the websocket level (#1632)
filipecabaco Dec 3, 2025
72c339b
fix: master region does not start read replica (#1642)
filipecabaco Dec 3, 2025
ffe5366
chore: run docker build on PRs (#1644)
filipecabaco Dec 5, 2025
acd9ee5
chore: add a link to the license badge on README.md (#1647)
Olexandr88 Dec 7, 2025
8f664f7
fix: update nodejs to latest (#1645)
filipecabaco Dec 8, 2025
e1acf33
chore: use RateCounterHelper.tick! to avoid waiting on tests (#1650)
edgurgel Dec 8, 2025
03e2f71
fix: use default storage for peep (#1651)
edgurgel Dec 8, 2025
5eca638
fix: speed up tenant connected metrics (#1652)
edgurgel Dec 9, 2025
2994d65
fix: Repo.Replica returns main Repo if master region (#1653)
edgurgel Dec 9, 2025
6a1d77a
fix: improve metrics handling (#1654)
edgurgel Dec 10, 2025
4588af5
fix: remove tenant tag on RPC metrics (#1655)
edgurgel Dec 10, 2025
93ce90a
feat: add /metrics/:region endpoint (#1656)
edgurgel Dec 10, 2025
79da9b6
fix: stream metrics data (#1658)
edgurgel Dec 10, 2025
5817c10
fix: coalesce wal data if not available on list_changes function (#1649)
edgurgel Dec 10, 2025
75e5f99
fix: ensure replication connection publication only has correct table…
filipecabaco Dec 11, 2025
ad36f07
fix: allow nullable jwt secret (#1646)
filipecabaco Dec 11, 2025
95fe3ac
fix: bump max heap size to 2500MB (#1660)
edgurgel Dec 15, 2025
0754846
fix: use custom Prometheus exporter (#1661)
edgurgel Dec 16, 2025
2249c06
fix: jwt secret migration (#1662)
edgurgel Dec 18, 2025
05df771
feat: use custom peep partitions (#1663)
edgurgel Dec 18, 2025
5017618
fix: run migrations on tenants nearest region (#1659)
filipecabaco Dec 29, 2025
bb1c2b6
fix: fix tenant cache handling (#1665)
edgurgel Jan 4, 2026
bdadcec
feat: beacon (#1664)
edgurgel Jan 15, 2026
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
46 changes: 46 additions & 0 deletions .github/workflows/beacon_tests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
name: Beacon Tests
defaults:
run:
shell: bash
working-directory: ./beacon
on:
pull_request:
paths:
- "beacon/**"

push:
branches:
- main

concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true

env:
MIX_ENV: test

jobs:
tests:
name: Tests & Lint
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
- name: Setup elixir
id: beam
uses: erlef/setup-beam@v1
with:
otp-version: 27.x # Define the OTP version [required]
elixir-version: 1.18.x # Define the elixir version [required]
- name: Install dependencies
run: mix deps.get
- name: Start epmd
run: epmd -daemon
- name: Run tests
run: MIX_ENV=test mix test
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Check for warnings
run: mix compile --force --warnings-as-errors
- name: Run format check
run: mix format --check-formatted
20 changes: 20 additions & 0 deletions .github/workflows/docker-build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
name: Docker Build

on:
pull_request:
branches:
- main

jobs:
build:
runs-on: ubuntu-latest

steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3

- name: Build Docker image
run: docker build .
33 changes: 33 additions & 0 deletions .github/workflows/integration_tests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
name: Integration Tests
on:
pull_request:
paths:
- "lib/**"
- "test/**"
- "config/**"
- "priv/**"
- "assets/**"
- "rel/**"
- "mix.exs"
- "Dockerfile"
- "run.sh"
- "docker-compose.test.yml"

push:
branches:
- main

concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true

jobs:
tests:
name: Tests
runs-on: blacksmith-8vcpu-ubuntu-2404

steps:
- uses: actions/checkout@v2
- name: Run integration test
run: docker compose -f docker-compose.tests.yml up --abort-on-container-exit --exit-code-from test-runner

80 changes: 80 additions & 0 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,80 @@
name: Lint
on:
pull_request:
paths:
- "lib/**"
- "test/**"
- "config/**"
- "priv/**"
- "assets/**"
- "rel/**"
- "mix.exs"
- "Dockerfile"
- "run.sh"

push:
branches:
- main

concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true

jobs:
tests:
name: Lint
runs-on: blacksmith-4vcpu-ubuntu-2404

steps:
- uses: actions/checkout@v2
- name: Setup elixir
id: beam
uses: erlef/setup-beam@v1
with:
otp-version: 27.x # Define the OTP version [required]
elixir-version: 1.18.x # Define the elixir version [required]
- name: Cache Mix
uses: actions/cache@v4
with:
path: |
deps
_build
key: ${{ github.workflow }}-${{ runner.os }}-mix-${{ env.elixir }}-${{ env.otp }}-${{ hashFiles('**/mix.lock') }}
restore-keys: |
${{ github.workflow }}-${{ runner.os }}-mix-${{ env.elixir }}-${{ env.otp }}-

- name: Install dependencies
run: mix deps.get
- name: Set up Postgres
run: docker compose -f docker-compose.dbs.yml up -d
- name: Run main database migrations
run: mix ecto.migrate --log-migrator-sql
- name: Run database tenant migrations
run: mix ecto.migrate --migrations-path lib/realtime/tenants/repo/migrations
- name: Check for warnings
run: mix compile --force --warnings-as-errors
- name: Run format check
run: mix format --check-formatted
- name: Credo checks
run: mix credo
- name: Run hex audit
run: mix hex.audit
- name: Run mix_audit
run: mix deps.audit
- name: Run sobelow
run: mix sobelow --config .sobelow-conf
- name: Retrieve PLT Cache
uses: actions/cache@v4
id: plt-cache
with:
path: priv/plts
key: ${{ runner.os }}-${{ steps.beam.outputs.otp-version }}-${{ steps.beam.outputs.elixir-version }}-plts-${{ hashFiles(format('{0}{1}', github.workspace, '/mix.lock')) }}
- name: Create PLTs
if: steps.plt-cache.outputs.cache-hit != 'true'
run: |
mkdir -p priv/plts
mix dialyzer.build
- name: Run dialyzer
run: mix dialyzer
- name: Run dev seeds
run: DB_ENC_KEY="1234567890123456" mix ecto.setup
24 changes: 10 additions & 14 deletions .github/workflows/manual_prod_build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ on:
required: true
jobs:
docker_x86_release:
runs-on: ubuntu-latest
runs-on: blacksmith-4vcpu-ubuntu-2404
timeout-minutes: 120
env:
arch: amd64
Expand All @@ -25,21 +25,20 @@ jobs:
tags: |
type=raw,value=v${{ github.event.inputs.docker_tag }}_${{ env.arch }}

- uses: docker/setup-buildx-action@v2
- name: Setup Blacksmith Builder
uses: useblacksmith/setup-docker-builder@v1

- uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}

- id: build
uses: docker/build-push-action@v3
uses: useblacksmith/build-push-action@v2
with:
push: true
tags: ${{ steps.meta.outputs.tags }}
platforms: linux/${{ env.arch }}
cache-from: type=gha
cache-to: type=gha,mode=max

docker_arm_release:
runs-on: arm-runner
Expand All @@ -64,15 +63,11 @@ jobs:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}

- uses: docker/setup-buildx-action@v2
with:
driver: docker
driver-opts: |
image=moby/buildkit:master
network=host
- name: Setup Blacksmith Builder
uses: useblacksmith/setup-docker-builder@v1

- id: build
uses: docker/build-push-action@v3
uses: useblacksmith/build-push-action@v2
with:
context: .
push: true
Expand All @@ -82,13 +77,14 @@ jobs:

merge_manifest:
needs: [docker_x86_release, docker_arm_release]
runs-on: ubuntu-latest
runs-on: blacksmith-4vcpu-ubuntu-2404
permissions:
contents: read
packages: write
id-token: write
steps:
- uses: docker/setup-buildx-action@v2
- name: Setup Blacksmith Builder
uses: useblacksmith/setup-docker-builder@v1

- uses: docker/login-action@v2
with:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/mirror.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ on:

jobs:
mirror:
runs-on: ubuntu-latest
runs-on: blacksmith-4vcpu-ubuntu-2404
permissions:
contents: read
packages: write
Expand Down
28 changes: 12 additions & 16 deletions .github/workflows/prod_build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ on:

jobs:
release:
runs-on: ubuntu-latest
runs-on: blacksmith-4vcpu-ubuntu-2404
outputs:
published: ${{ steps.semantic.outputs.new_release_published }}
version: ${{ steps.semantic.outputs.new_release_version }}
Expand All @@ -30,7 +30,7 @@ jobs:

docker_x86_release:
needs: release
runs-on: ubuntu-latest
runs-on: blacksmith-4vcpu-ubuntu-2404
if: needs.release.outputs.published == 'true'
timeout-minutes: 120
env:
Expand All @@ -47,21 +47,20 @@ jobs:
type=raw,value=v${{ needs.release.outputs.version }}_${{ env.arch }}
type=raw,value=latest_${{ env.arch }}

- uses: docker/setup-buildx-action@v2
- name: Setup Blacksmith Builder
uses: useblacksmith/setup-docker-builder@v1

- uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}

- id: build
uses: docker/build-push-action@v3
uses: useblacksmith/build-push-action@v2
with:
push: true
tags: ${{ steps.meta.outputs.tags }}
platforms: linux/${{ env.arch }}
cache-from: type=gha
cache-to: type=gha,mode=max

docker_arm_release:
needs: release
Expand Down Expand Up @@ -89,15 +88,11 @@ jobs:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}

- uses: docker/setup-buildx-action@v2
with:
driver: docker
driver-opts: |
image=moby/buildkit:master
network=host
- name: Setup Blacksmith Builder
uses: useblacksmith/setup-docker-builder@v1

- id: build
uses: docker/build-push-action@v3
uses: useblacksmith/build-push-action@v2
with:
context: .
push: true
Expand All @@ -107,13 +102,14 @@ jobs:

merge_manifest:
needs: [release, docker_x86_release, docker_arm_release]
runs-on: ubuntu-latest
runs-on: blacksmith-4vcpu-ubuntu-2404
permissions:
contents: read
packages: write
id-token: write
steps:
- uses: docker/setup-buildx-action@v2
- name: Setup Blacksmith Builder
uses: useblacksmith/setup-docker-builder@v1

- uses: docker/login-action@v2
with:
Expand Down Expand Up @@ -160,7 +156,7 @@ jobs:

update-branch-name:
needs: [release, docker_x86_release, docker_arm_release, merge_manifest]
runs-on: ubuntu-latest
runs-on: blacksmith-4vcpu-ubuntu-2404
steps:
- name: Checkout branch
uses: actions/checkout@v2
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/prod_linter.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,16 +7,16 @@ on:
jobs:
format:
name: Formatting Checks
runs-on: ubuntu-latest
runs-on: blacksmith-4vcpu-ubuntu-2404

steps:
- uses: actions/checkout@v2
- name: Setup elixir
id: beam
uses: erlef/setup-beam@v1
with:
otp-version: 26.x # Define the OTP version [required]
elixir-version: 1.16.x # Define the elixir version [required]
otp-version: 27.x # Define the OTP version [required]
elixir-version: 1.18.x # Define the elixir version [required]
- name: Cache Mix
uses: actions/cache@v4
with:
Expand Down
Loading