Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
45 commits
Select commit Hold shift + click to select a range
33a9c3d
wip - add roles & cleanup resource structure
maltesander Feb 26, 2026
84fa755
wip - cleanup
maltesander Feb 26, 2026
b4597cb
wip - more refactoring
maltesander Feb 26, 2026
3846bd7
wip - added celery test
maltesander Mar 2, 2026
d2fc6c9
improve test
maltesander Mar 2, 2026
2e9892c
wip - improve testing
maltesander Mar 2, 2026
66c8b03
add logs for worker
maltesander Mar 3, 2026
93a1726
Merge remote-tracking branch 'origin/main' into feat/enable-celery-wo…
maltesander Apr 23, 2026
07622b4
fix: remaining compile errors after merge.
maltesander Apr 23, 2026
b5c7bfe
fix: adapt celery worker test to breaking secret changes
maltesander Apr 23, 2026
a3ce2fb
fix: regenerated charts after merge
maltesander Apr 23, 2026
0969bfb
fix: adapt celery worker test to EXPERIMENTAL_FILE_FOOTER changes.
maltesander Apr 23, 2026
756f271
feat: add celery backend and broker database to crd
maltesander Apr 23, 2026
b4133f8
feat: wire backend and broker crd values
maltesander Apr 23, 2026
586c9cb
test: celery worker test successful with beat.
maltesander Apr 23, 2026
96e948e
fix: pre-commit
maltesander Apr 23, 2026
ec8dea7
fix: set beat replicas to 1 or 0 only.
maltesander Apr 24, 2026
843d1b3
docs: extend database connection for broker and results backend.
maltesander Apr 24, 2026
e9d5f6c
docs: fix missing footnotes.
maltesander Apr 24, 2026
69a7087
docs: add celery async query docs.
maltesander Apr 24, 2026
0ddf79a
Merge branch 'main' into feat/enable-celery-workers
maltesander Apr 24, 2026
b13c2f6
docs: remove outdated code comments.
maltesander Apr 24, 2026
60e89b3
fix: remove outdated comment
maltesander Apr 25, 2026
daf0884
fix: remove generic from results backend; clean up unwraps.
maltesander Apr 25, 2026
3d0b5cc
fix: remove obsolete comment
maltesander Apr 25, 2026
96cc92f
fix: increase worker memory to 4GB for version 6.0.0
maltesander Apr 25, 2026
50430eb
fix: replicas for beat
maltesander Apr 25, 2026
1a56aeb
fix: rename result_backend_* to results_backend_*
maltesander Apr 26, 2026
9fe6794
clippy: fix host lint.
maltesander Apr 26, 2026
00d603b
fix: enable proper logging for worker and beat.
maltesander Apr 27, 2026
ed93462
docs: adapt changelog.
maltesander Apr 27, 2026
6660043
fix: use database id for results backend.
maltesander Apr 28, 2026
f6bcf04
fix: error variants in statefulset & deployment
maltesander Apr 28, 2026
6ec3054
fix: optional role definition in validated config.
maltesander Apr 28, 2026
f9b0f86
docs: improve beat replica documentation
maltesander Apr 28, 2026
08a377d
docs: fix linter
maltesander Apr 28, 2026
fc62924
fix: remove obsolete logging TODOs.
maltesander Apr 28, 2026
e9f8b45
fix: remove c&p code comment
maltesander Apr 28, 2026
b2f9e60
fix: remove "missing" from celery results backend connection details.
maltesander Apr 28, 2026
234a4a3
fix: add Deployment to watch.
maltesander May 3, 2026
dfb9286
Merge remote-tracking branch 'origin/main' into feat/enable-celery-wo…
maltesander May 4, 2026
5690038
docs: consolidate statefulset method header.
maltesander May 4, 2026
d01bf14
docs: remove double heading
maltesander May 4, 2026
1d293a9
chore: add warning if beat replicas > 1.
maltesander May 4, 2026
93ef2c9
test: Use external-unstable for kuttl tests
sbernauer May 5, 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
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@

### Added

- Support for Async Queries via Celery. Two new roles, `worker` and `beat` ([#724]).
- Support for redis broker and results backend for celery workers in the CRD ([#724]).
- BREAKING: Add required CLI argument and env var to set the image repository used to construct final product image names: `IMAGE_REPOSITORY` (`--image-repository`), eg. `oci.example.org/my/namespace` ([#726]).

### Changed
Expand All @@ -25,6 +27,7 @@
[#719]: https://github.com/stackabletech/superset-operator/pull/719
[#721]: https://github.com/stackabletech/superset-operator/pull/721
[#722]: https://github.com/stackabletech/superset-operator/pull/722
[#724]: https://github.com/stackabletech/superset-operator/pull/724
[#726]: https://github.com/stackabletech/superset-operator/pull/726

## [26.3.0] - 2026-03-16
Expand Down
1 change: 1 addition & 0 deletions deploy/helm/chart_testing.yaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
---
remote: origin
target-branch: main
chart-dirs:
Expand Down
12 changes: 12 additions & 0 deletions deploy/helm/superset-operator/templates/clusterrole-operator.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,18 @@ rules:
resourceNames:
- {{ include "operator.name" . }}-clusterrole
# StatefulSet created per role group. Applied via SSA and tracked for orphan cleanup.
- apiGroups:
- apps
resources:
- deployments
verbs:
- get
- create
- delete
- list
- patch
- update
- watch
- apiGroups:
- apps
resources:
Expand Down
43 changes: 43 additions & 0 deletions docs/modules/superset/pages/usage-guide/celery-async-queries.adoc
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
= Async Queries via Celery
:description: Schedule Apache Superset SQL queries on Celery workers.

In order to support long running queries that exceed the web requests timeout, an asynchronous backend has to be configured.
This requires two more roles to be configured besides the existing `nodes`. The (celery) `workers` and a `beat` for scheduling.

The beat role is limited to `1` or `0` replicas only. Replicas greater than one are ignored and set to `1`.
This avoids multiple beat instances scheduling the same tasks at the same time.

If no beat or scheduling is required, async queries keep work without a beat instance.

The following example shows additional required settings to enable async queries:

[source,yaml]
----
spec:
clusterConfig:
celeryBroker:
redis:
host: superset-redis-master
port: 6379
credentialsSecretName: superset-redis-broker-credentials
celeryResultsBackend:
redis:
host: superset-redis-master
port: 6379
credentialsSecretName: superset-redis-results-backend-credentials
nodes:
roleGroups:
default:
replicas: 1
workers:
roleGroups:
default:
replicas: 2
beat: # optional
roleGroups:
default:
# Only 1 or 0 instances possible.
replicas: 1
----

This is not a complete example. The main `nodes` role for the webserver and e.g. the metadata database are missing.
79 changes: 77 additions & 2 deletions docs/modules/superset/pages/usage-guide/database-connections.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,11 @@

Superset requires a metadata database for storing slices, connections, tables, dashboards and other metadata.
The actual connection string is calculated by the operator so that the user does not need to remember the exact structure.
Using async queries with celery workers also requires a broker and a results backend.

== Typed connections
== Metadata database

=== PostgreSQL

[source,yaml]
----
Expand All @@ -19,7 +22,7 @@ spec:
<1> A reference to one of the supported database backends (e.g. `postgresql`).
<2> A reference to a Secret which must contain the two keys `username` and `password`.

== Generic connections
=== Generic connections

Alternatively, these connections can also be defined in full in a referenced Secret:

Expand All @@ -33,3 +36,75 @@ spec:
----

<1> A reference to a Secret which must contain the single key `connectionUrl` e.g. `postgresql://superset:superset@superset-postgresql/superset`

== Broker

The broker queue is required to schedule or pass queries on the celery workers.

=== Redis

A redis broker can be configured in the `clusterConfig`:

[source,yaml]
----
spec:
clusterConfig:
celeryBroker:
redis:
host: redis-master
port: 6379
credentialsSecretName: superset-redis-credentials
----

=== Generic connections

Alternatively, these connections can also be defined in full in a referenced Secret:

[source,yaml]
----
spec:
clusterConfig:
celeryBroker:
generic:
connectionUrlSecretName: superset-redis-broker-url # <1>
----

<1> A reference to a Secret which must contain the single key `connectionUrl` e.g. `redis://:redis@redis-master/0`

== Results Backend

Celery workers store their results in the configured results backend.

=== Redis

A redis broker can be configured in the `clusterConfig`:

[source,yaml]
----
spec:
clusterConfig:
celeryResultsBackend:
redis:
host: redis-master
port: 6379
credentialsSecretName: superset-redis-credentials
----

=== S3

Currently not supported.

=== Generic connections

Alternatively, these connections can also be defined in full in a referenced Secret:

[source,yaml]
----
spec:
clusterConfig:
celeryResultsBackend:
generic:
connectionUrlSecretName: superset-redis-results-backend-url # <1>
----

<1> A reference to a Secret which must contain the single key `connectionUrl` e.g. `redis://:redis@redis-master/0`
Loading
Loading