Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
104 commits
Select commit Hold shift + click to select a range
4559587
feat: OIDC device flow
glasstiger Jun 15, 2026
c7c269f
fix: pandas 3 string dtype in test_parquet_roundtrip
glasstiger Jun 15, 2026
e394fbd
ci: keep 32-bit wheel tests on the pandas 2 / numpy 1 path
glasstiger Jun 15, 2026
ae92178
test: silence mock server tracebacks on Windows client disconnect
glasstiger Jun 15, 2026
88308d5
ci: skip readonly AZP_ENHANCED agent var in Windows wheel build
glasstiger Jun 17, 2026
d5df186
fix: harden OIDC device-flow auth; drop on-disk FileCache backend
glasstiger Jun 17, 2026
5ef892b
ci: build questdb master's -SNAPSHOT java client via local-client pro…
glasstiger Jun 18, 2026
ae8baa7
ci: build/run questdb master on JDK 25
glasstiger Jun 18, 2026
a4b41c3
ci: invoke Maven directly to build questdb master on JDK 25
glasstiger Jun 18, 2026
61abd4f
ci: pass JDK 25 module access flags to questdb master server
glasstiger Jun 18, 2026
23fb823
do not follow redirects
glasstiger Jun 18, 2026
c13cf69
fix: require IdP pin for plaintext /settings
glasstiger Jun 18, 2026
bb9147c
fix: clamp device-flow poll timing fields
glasstiger Jun 18, 2026
0edf9dc
fix: map malformed inputs to typed OidcError
glasstiger Jun 18, 2026
35c3fbb
fix: sanitize device-flow terminal output
glasstiger Jun 18, 2026
f6321c3
docs: correct questdb.auth changelog and API reference
glasstiger Jun 18, 2026
e043561
fix: make TokenSet immutable and keep tokens out of repr
glasstiger Jun 18, 2026
4e62938
style: sort questdb.auth __all__ to satisfy Ruff RUF022
glasstiger Jun 18, 2026
4a67cc5
docs: make review-pr level-0/1 Step 2.5 rules consistent
glasstiger Jun 18, 2026
124d4c2
docs: exclude Agent 10 from review-pr Step 2.5 input contract
glasstiger Jun 18, 2026
a062a0a
fix: ignore user-writable /settings preferences
glasstiger Jun 18, 2026
fe34ffa
fix: reject conf metachars in QuestDB host
glasstiger Jun 18, 2026
ae4c5ba
fix: harden questdb.auth untrusted-input handling
glasstiger Jun 19, 2026
afbd808
fix: bound IdP timeout; broaden auth edge tests
glasstiger Jun 19, 2026
63edfce
fix: address 3 minor questdb.auth review nits
glasstiger Jun 19, 2026
c869e31
fix: address 4 follow-up auth review findings
glasstiger Jun 19, 2026
bcfebd9
fix: address 4 moderate questdb.auth review findings
glasstiger Jun 19, 2026
8f61ff2
fix: make deeply-nested-JSON auth test robust on Python 3.14
glasstiger Jun 19, 2026
a9c58c8
fix: make questdb.auth clear() reliable across shared-cache instances
glasstiger Jun 19, 2026
7ed6f05
fix: tolerate non-string acl.oidc.* from QuestDB /settings and IdP di…
glasstiger Jun 19, 2026
63a3f7a
fix: keep device-flow poll alive through transient IdP errors
glasstiger Jun 21, 2026
954f8a8
fix: map malformed IdP discovery / /exec payloads to OidcError
glasstiger Jun 21, 2026
6e2970b
fix: sanitize untrusted device fields on the Jupyter prompt path
glasstiger Jun 21, 2026
c31eb0f
fix: bind discovery_url pin to the IdP origin; close auth test gaps
glasstiger Jun 21, 2026
20bf2cd
fix: classify IdP token-endpoint errors transient vs terminal
glasstiger Jun 22, 2026
dcd44bc
fix: keep the device-flow prompt visible on a non-UTF-8 terminal
glasstiger Jun 22, 2026
86cf83f
fix: close issuer-path pin bypass via encoded/backslash/;params trave…
glasstiger Jun 22, 2026
0001e4d
fix: tighten device-auth, host/port handling, and refresh audience
glasstiger Jun 22, 2026
99c05ac
docs: condense the questdb.auth comments and docstrings
glasstiger Jun 22, 2026
73e3c5f
fix: default groups_in_token to False to match the QuestDB server
glasstiger Jun 23, 2026
b23e5db
refactor(auth): replace the QuestDB session with PG-wire adapter func…
glasstiger Jun 23, 2026
c189141
refactor(auth): drop the unused `flow` parameter from from_questdb
glasstiger Jun 23, 2026
806be9c
refactor(auth): only trust absolute /settings endpoint URLs (match Java)
glasstiger Jun 23, 2026
19f46d0
feat(auth): open the verification URL in a browser by default
glasstiger Jun 23, 2026
f567e26
fix(auth): floor the device-flow poll interval at 5s (RFC 8628 default)
glasstiger Jun 23, 2026
9f5035f
fix(auth): bound the HTTP response read (size cap + wall-clock deadline)
glasstiger Jun 23, 2026
2d75e01
fix(test): drop stale REST-adapter test imports from test.py
glasstiger Jun 23, 2026
b32207f
fix(auth): clamp token lifetime to match the Java client
glasstiger Jun 23, 2026
48aae3b
refactor(auth): drop the pluggable cache; memory cache is always on
glasstiger Jun 23, 2026
0a70fa5
fix(auth): close path-pin bypass via inner-segment ;param
glasstiger Jun 23, 2026
2fed74a
fix(auth): coerce non-string IdP token fields to None
glasstiger Jun 23, 2026
deb111d
fix(auth): map truncated error body to OidcNetworkError
glasstiger Jun 23, 2026
5adb3f4
test(auth): cover proactive refresh in the skew window
glasstiger Jun 23, 2026
0c0f499
fix(auth): validate constructor arg types; redact sub from repr
glasstiger Jun 23, 2026
c7cd7f5
fix(auth): validate default_interval and timeout args
glasstiger Jun 24, 2026
02a29f2
fix(auth): propagate HTTP status on non-dict JSON body
glasstiger Jun 24, 2026
117f06a
fix(auth): honor read deadline on slow-dribble responses
glasstiger Jun 24, 2026
9e62239
fix(auth): strip terminal control chars by Unicode category
glasstiger Jun 24, 2026
bf7ea91
fix(auth): harden parsing of untrusted IdP response fields
glasstiger Jun 24, 2026
0b62d09
fix(auth): normalize empty audience; drop dead field; review cleanup
glasstiger Jun 24, 2026
c1223f2
fix(auth): evict unusable token; sanitize error output
glasstiger Jun 24, 2026
b569014
fix(auth): enforce the discovery_url pin on /settings endpoints
glasstiger Jun 24, 2026
baa4c4d
fix(auth): fail fast on a 3xx poll; normalize issuer in cache key
glasstiger Jun 24, 2026
075a01c
fix(auth): scope the issuer-origin pin to /settings; drop discovery_url
glasstiger Jun 25, 2026
5f92dcb
fix(auth): keep the Jupyter QR code visible across re-renders
glasstiger Jun 25, 2026
af721f6
fix(auth): apply the issuer-path pin after discovery
glasstiger Jun 25, 2026
899304d
fix(auth): harden the prompt renderer and error sanitizer
glasstiger Jun 25, 2026
a91c1f2
fix(auth): bound the token-cache maps; fix the /settings URL
glasstiger Jun 25, 2026
6c41d2c
fix(auth): tighten origin/path normalization edge cases
glasstiger Jun 25, 2026
4482b94
fix(auth): harden error fields and verification-link safety
glasstiger Jun 25, 2026
a053233
fix(auth): trim link whitespace and reject IPv6 zone-id host
glasstiger Jun 25, 2026
5d1421b
fix(auth): show real link host and unify the open/QR target
glasstiger Jun 25, 2026
c0d8a6e
fix(auth): validate pg_port and attach status to get_json errors
glasstiger Jun 25, 2026
6806bdf
fix(auth): guard verification_uri, real-lifetime message, Retry-After
glasstiger Jun 25, 2026
ff84625
fix(auth): reject confusable endpoint authority and inf timeout
glasstiger Jun 25, 2026
6581ad5
fix(auth): apply minor review fixes (m1-m7)
glasstiger Jun 25, 2026
623b983
fix(auth): detect non-interactive notebook executors; review nits
glasstiger Jun 25, 2026
e78de24
fix(auth): bound chunked reads and keep errors typed
glasstiger Jun 26, 2026
81f72a5
fix(auth): refuse pool-thread sign-in; floor slow_down backoff
glasstiger Jun 26, 2026
1e5a5f8
fix(auth): adopt fresh cached token; honor non-JSON Retry-After
glasstiger Jun 26, 2026
e7c208a
fix(auth): escape confusable host on display fail-open
glasstiger Jun 29, 2026
28dd619
fix(auth): apply minor review fixes (5xx backoff, cache key, re-entry)
glasstiger Jun 29, 2026
1ce9599
fix(auth): reject tab/newline/CR in endpoint host
glasstiger Jun 29, 2026
99c2d68
fix(auth): minor review fixes (link, host, return type)
glasstiger Jun 29, 2026
b37fe54
fix(auth): public doc xrefs; non-object JWT test
glasstiger Jun 29, 2026
1431df3
fix(auth): isolate renderer errors; reject % host
glasstiger Jun 29, 2026
57e522d
opt-in token persistence
glasstiger Jun 29, 2026
0b63719
fix(auth): bound the response head read by the deadline
glasstiger Jun 30, 2026
7790c4a
fix(auth): unify token identity keys; screen network tokens
glasstiger Jun 30, 2026
2a55c50
fix(auth): harden numeric, render, and issuer edge cases
glasstiger Jun 30, 2026
b0d2ce8
fix(auth): align in-memory and on-disk token keys
glasstiger Jun 30, 2026
e4744e4
fix(auth): isolate persisted tokens by issuer
glasstiger Jun 30, 2026
69b9235
fix(auth): harden retry-after, blank tokens, IPv6 keys, and store locks
glasstiger Jul 1, 2026
9912a51
fix(auth): sync persisted refresh token when adopting a cached token
glasstiger Jul 1, 2026
80cf3b7
docs(auth): export Renderer so its docstring xref resolves
glasstiger Jul 1, 2026
d4710c7
fix(auth): harden token persistence and discovery
glasstiger Jul 1, 2026
ccc400c
fix(auth): reject malformed verification-URL port so the shown link c…
glasstiger Jul 1, 2026
710843a
fix(auth): reject blank-after-strip device prompts; close test-covera…
glasstiger Jul 1, 2026
75f27bb
fix(auth): keep bad-arg errors typed and reuse a peer token before re…
glasstiger Jul 1, 2026
5aac5e8
fix(auth): sweep orphaned token temps, harden lock, tighten docs and …
glasstiger Jul 1, 2026
c393dd9
fix(auth): reject multi-host PG hosts and truncated HTTP bodies
glasstiger Jul 2, 2026
5a70301
fix(auth): close credential-routing bypass and two token-store gaps
glasstiger Jul 2, 2026
797ceae
fix(auth): keep non-string issuer typed; canonicalize endpoint confir…
glasstiger Jul 2, 2026
e50f490
fix(auth): honor slow_down on a 429, coerce groups flag, strip hidden…
glasstiger Jul 2, 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
377 changes: 377 additions & 0 deletions .claude/skills/review-pr/SKILL.md

Large diffs are not rendered by default.

74 changes: 74 additions & 0 deletions CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,80 @@ Changelog

=========

Unreleased
----------

Features
~~~~~~~~

OIDC Authentication (:mod:`questdb.auth`)
************************************************

New :mod:`questdb.auth` module to sign in interactively to OIDC-secured
QuestDB Enterprise from Python — including from **remote** kernels
(JupyterHub, SageMaker, Colab, VS Code-remote) that have no local browser.

It runs the OAuth 2.0 Device Authorization Grant (RFC 8628) client-side: you
authorize in any browser (laptop or phone), and the token is presented to
QuestDB over the auth paths it already supports (HTTP ``Bearer`` / PG-wire
``_sso``). No server change is required.

.. code-block:: python

from questdb.auth import OidcDeviceAuth, sqlalchemy_engine

# Sign in once and get a valid, auto-refreshed token:
auth = OidcDeviceAuth.from_questdb("https://questdb.example.com:9000")
token = auth.token() # use it with PG-wire, HTTP, or any client

# Or wire it into PG-wire as the _sso password:
engine = sqlalchemy_engine(auth, "https://questdb.example.com:9000")

Highlights:

* Auto-discovery of OIDC config from the QuestDB ``/settings`` endpoint, with a
fallback to the IdP ``.well-known`` document. Works with IdPs whose issuer is
on a different origin than its token / device-authorization endpoints (e.g.
Google: ``accounts.google.com`` issuer, ``oauth2.googleapis.com`` endpoints),
while still pinning endpoints advertised over an untrusted ``/settings``
channel to the issuer.
* In-process token cache with silent refresh; in-memory only by default
(nothing written to disk unless you opt into a
:class:`~questdb.auth.TokenStore` — see the next entry).
* Opt-in **token persistence** (:class:`~questdb.auth.FileTokenStore`, passed as
``token_store=``) so a restarted process resumes from a saved refresh token
instead of prompting again. The default file store keeps one owner-only
(``0600``) plaintext file per identity under ``~/.questdb/oidc-tokens/``,
written atomically and coordinated across processes with a lock file; supply a
custom :class:`~questdb.auth.TokenStore` to back it with an OS keychain. The
on-disk format is a language-neutral contract shared with the Java client. The
per-request ``timeout`` is capped at 120s (matching the Java client) so a slow
refresh held under the file store's cross-process lock can't outlast its
staleness window; a larger value raises ``OidcConfigError`` at construction.
* Convenience adapters (:func:`~questdb.auth.sqlalchemy_engine`,
:func:`~questdb.auth.psycopg_connect`) that wire the token into PG-wire as the
``_sso`` password — ``sqlalchemy_engine`` re-supplies a fresh, auto-refreshed
token on every new pooled connection, ``psycopg_connect`` captures it at
connect time.
* ``token()`` / ``headers()`` require no dependencies beyond the standard
library; ``sqlalchemy`` / ``psycopg`` / ``qrcode`` / ``IPython`` are imported
lazily.

See the :ref:`OIDC authentication guide <oidc_auth>` for details.

Breaking Changes
~~~~~~~~~~~~~~~~~

* The minimum supported Python is **3.10**. Python 3.8 (end-of-life 2024-10) and
3.9 (end-of-life 2025-10) are no longer supported, and ``pip`` will refuse to
install this release on them. This affects the whole ``questdb`` package, not
only the new :mod:`questdb.auth` module. The authoritative ``requires-python``
in ``pyproject.toml`` already declared ``>=3.10`` in 4.1.0 (so ``pip`` has
rejected 3.8 / 3.9 installs since then); this release also updates the stale
``python_requires`` in ``setup.py``, which still read ``>=3.8``, to match —
removing the inconsistency for source builds that read ``setup.py`` directly.
Users still on 3.8 / 3.9 should pin to an earlier ``questdb`` release.

4.1.0 (2025-11-28)
------------------

Expand Down
3 changes: 1 addition & 2 deletions RELEASING.rst
Original file line number Diff line number Diff line change
Expand Up @@ -59,10 +59,9 @@ From a MacOS ARM computer install UTM.
* Install MacOS X 12.4 (Monterey). See https://docs.getutm.app/guest-support/macos/
* Install Rust from https://rustup.rs/
* Install Firefox
* Install *all* OFFICIAL Python Releases from Python 3.8 onwards. Use the latest patch version for each minor release.
* Install *all* OFFICIAL Python Releases from Python 3.10 onwards. Use the latest patch version for each minor release.
* https://www.python.org/downloads/macos/
* Do NOT use Homebrew to install Python.
* Python 3.8.10 requires Rosetta, install it when prompted to do so.

* Optionally install VS Code

Expand Down
4 changes: 2 additions & 2 deletions ci/cibuildwheel.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ stages:
cmd /c "call `"$vsPath`" && set > env_vars.txt"

Get-Content env_vars.txt | ForEach-Object {
if ($_ -match "^([^=]+?)=(.*)$" -and $matches[1] -notmatch '^(SYSTEM|AGENT|BUILD|RELEASE|VSTS|TASK|USE_|FAIL_|MSDEPLOY|AZP_75787|AZP_AGENT|AZP_ENABLE|AZURE_HTTP|COPYFILESOVERSSHV0|ENABLE_ISSUE_SOURCE_VALIDATION|MODIFY_NUMBER_OF_RETRIES_IN_ROBOCOPY|MSBUILDHELPERS_ENABLE_TELEMETRY|RETIRE_AZURERM_POWERSHELL_MODULE|ROSETTA2_WARNING|AZP_PS_ENABLE)') {
if ($_ -match "^([^=]+?)=(.*)$" -and $matches[1] -notmatch '^(SYSTEM|AGENT|BUILD|RELEASE|VSTS|TASK|USE_|FAIL_|MSDEPLOY|AZP_75787|AZP_AGENT|AZP_ENABLE|AZP_ENHANCED|AZURE_HTTP|COPYFILESOVERSSHV0|ENABLE_ISSUE_SOURCE_VALIDATION|MODIFY_NUMBER_OF_RETRIES_IN_ROBOCOPY|MSBUILDHELPERS_ENABLE_TELEMETRY|RETIRE_AZURERM_POWERSHELL_MODULE|ROSETTA2_WARNING|AZP_PS_ENABLE)') {
[System.Environment]::SetEnvironmentVariable($matches[1], $matches[2], "Process")
Write-Host "##vso[task.setvariable variable=$($matches[1])]$($matches[2])"
}
Expand Down Expand Up @@ -137,7 +137,7 @@ stages:
cmd /c "call `"$vsPath`" && set > env_vars.txt"

Get-Content env_vars.txt | ForEach-Object {
if ($_ -match "^([^=]+?)=(.*)$" -and $matches[1] -notmatch '^(SYSTEM|AGENT|BUILD|RELEASE|VSTS|TASK|USE_|FAIL_|MSDEPLOY|AZP_75787|AZP_AGENT|AZP_ENABLE|AZURE_HTTP|COPYFILESOVERSSHV0|ENABLE_ISSUE_SOURCE_VALIDATION|MODIFY_NUMBER_OF_RETRIES_IN_ROBOCOPY|MSBUILDHELPERS_ENABLE_TELEMETRY|RETIRE_AZURERM_POWERSHELL_MODULE|ROSETTA2_WARNING|AZP_PS_ENABLE)') {
if ($_ -match "^([^=]+?)=(.*)$" -and $matches[1] -notmatch '^(SYSTEM|AGENT|BUILD|RELEASE|VSTS|TASK|USE_|FAIL_|MSDEPLOY|AZP_75787|AZP_AGENT|AZP_ENABLE|AZP_ENHANCED|AZURE_HTTP|COPYFILESOVERSSHV0|ENABLE_ISSUE_SOURCE_VALIDATION|MODIFY_NUMBER_OF_RETRIES_IN_ROBOCOPY|MSBUILDHELPERS_ENABLE_TELEMETRY|RETIRE_AZURERM_POWERSHELL_MODULE|ROSETTA2_WARNING|AZP_PS_ENABLE)') {
[System.Environment]::SetEnvironmentVariable($matches[1], $matches[2], "Process")
Write-Host "##vso[task.setvariable variable=$($matches[1])]$($matches[2])"
}
Expand Down
19 changes: 16 additions & 3 deletions ci/pip_install_deps.py
Original file line number Diff line number Diff line change
Expand Up @@ -77,12 +77,18 @@ def install_pandas3_and_numpy():
def should_use_pandas3(py_version=None):
if py_version is None:
py_version = sys.version_info[:2]
return py_version >= (3, 11)
# Pandas 3 ships no 32-bit wheels, so only take the pandas 3 / numpy 2
# path on 64-bit interpreters. On 32-bit (e.g. win32) the pandas 3 install
# would be silently skipped, fastparquet would then drag in a numpy-1-built
# pandas 2.0.3 alongside numpy 2, and importing pandas would crash.
is_64bits = sys.maxsize > 2 ** 32
return is_64bits and py_version >= (3, 11)


def install_default_pandas_and_numpy():
# Pandas 3 currently requires Python 3.11+, so keep 3.10 wheel tests on
# the pandas 2 / numpy 1.x-compatible path unless explicitly overridden.
# Pandas 3 requires Python 3.11+ and ships only 64-bit wheels, so keep
# 3.10 and all 32-bit wheel tests on the pandas 2 / numpy 1.x-compatible
# path unless explicitly overridden.
if should_use_pandas3():
install_pandas3_and_numpy()
else:
Expand All @@ -101,6 +107,13 @@ def main(args):

try_pip_install('fastparquet>=2023.10.1')
try_pip_install('pyarrow')
# For the questdb.auth OIDC tests: the behavioural TLS-rejection test
# (test_untrusted_server_certificate_is_rejected) generates a self-signed
# cert at runtime and skips without `cryptography`. Install it so the real
# handshake path is exercised in CI, not just the static-posture assertion.
# try_ (not required): on a platform with no wheel the test simply skips, as
# it already does locally.
try_pip_install('cryptography')

on_linux_is_glibc = (
(not platform.system() == 'Linux') or
Expand Down
36 changes: 30 additions & 6 deletions ci/run_tests_pipeline.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -63,12 +63,24 @@ stages:
git clone --depth 1 https://github.com/questdb/questdb.git
displayName: git clone questdb master
condition: eq(variables.vsQuestDbMaster, true)
- task: Maven@3
# Decide whether to build java-questdb-client from the bundled
# submodule (-P local-client, for a -SNAPSHOT client not on Maven
# Central) or resolve it from Maven Central. Sets $(CLIENT_PROFILE).
- template: templates/detect-local-client.yml
parameters:
qdbRepoPath: questdb
condition: eq(variables.vsQuestDbMaster, true)
# The Maven@3 task crashes parsing JDK 25 ("Cannot read properties of
# null (reading 'major')") since its JDK support tops out at 21, so
# invoke Maven directly on the preinstalled JDK 25 instead. Mirrors the
# task's defaults: POM questdb/pom.xml, goal "package".
- bash: |
set -eu
export JAVA_HOME="$(JAVA_HOME_25_X64)"
export PATH="$JAVA_HOME/bin:$PATH"
java -version
mvn -B -f questdb/pom.xml package -DskipTests -Pbuild-web-console $(CLIENT_PROFILE)
displayName: "Compile QuestDB master"
inputs:
mavenPOMFile: "questdb/pom.xml"
jdkVersionOption: "1.17"
options: "-DskipTests -Pbuild-web-console"
condition: eq(variables.vsQuestDbMaster, true)
- script: python3 proj.py test 1
displayName: "Test vs released"
Expand All @@ -77,8 +89,20 @@ stages:
- script: python3 proj.py test 1
displayName: "Test vs master"
env:
JAVA_HOME: $(JAVA_HOME_17_X64)
JAVA_HOME: $(JAVA_HOME_25_X64)
QDB_REPO_PATH: "./questdb"
# QuestDB master runs as the io.questdb JPMS module and needs these
# JDK 25 access flags (mirrors questdb.sh). The test fixture launches
# questdb.jar directly rather than via questdb.sh, so feed them to the
# java launcher through JDK_JAVA_OPTIONS.
JDK_JAVA_OPTIONS: >-
--sun-misc-unsafe-memory-access=allow
--enable-native-access=io.questdb
--add-opens=java.base/java.lang=io.questdb
--add-opens=java.base/java.lang.reflect=io.questdb
--add-opens=java.base/java.nio=io.questdb
--add-opens=java.base/java.time.zone=io.questdb
--add-exports=java.base/jdk.internal.vm=io.questdb
condition: eq(variables.vsQuestDbMaster, true)
- job: TestsAgainstVariousNumpyVersion1x
pool:
Expand Down
36 changes: 36 additions & 0 deletions ci/templates/detect-local-client.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
# Adapted from questdb/questdb's ci/templates/detect-local-client.yml.
#
# Decide how a cloned QuestDB checkout resolves its java-questdb-client
# dependency: a -SNAPSHOT client version is not published to Maven Central, so
# build it from the bundled java-questdb-client submodule via the `local-client`
# profile; a released version is taken from Maven Central. Sets the
# CLIENT_PROFILE pipeline variable (``-P local-client`` or empty) for the
# following Maven build, and inits the submodule only when it is needed.
#
# Unlike the upstream template, QuestDB is cloned into a subdirectory here, so
# the repo path is a parameter; ``condition`` lets the caller gate this to the
# matrix leg that builds QuestDB master.
parameters:
- name: qdbRepoPath
type: string
default: questdb
- name: condition
type: string
default: succeeded()

steps:
- bash: |
set -eu
pom="${{ parameters.qdbRepoPath }}/core/pom.xml"
CLIENT_VERSION=$(sed -n 's/.*<questdb.client.version>\(.*\)<\/questdb.client.version>.*/\1/p' "$pom" | head -1)
echo "questdb.client.version=$CLIENT_VERSION"
if echo "$CLIENT_VERSION" | grep -q '\-SNAPSHOT$'; then
echo "SNAPSHOT client detected -> build it locally (local-client profile)"
git -C "${{ parameters.qdbRepoPath }}" submodule update --init java-questdb-client
echo "##vso[task.setvariable variable=CLIENT_PROFILE]-P local-client"
else
echo "Release client detected -> resolve from Maven Central"
echo "##vso[task.setvariable variable=CLIENT_PROFILE]"
fi
displayName: "Detect QuestDB local client profile"
condition: ${{ parameters.condition }}
66 changes: 66 additions & 0 deletions docs/api.rst
Original file line number Diff line number Diff line change
Expand Up @@ -67,3 +67,69 @@ questdb.ingress
:members:
:undoc-members:
:show-inheritance:

questdb.auth
============

See the :ref:`oidc_auth` guide for an overview.

.. autoclass:: questdb.auth.OidcDeviceAuth
:members:
:undoc-members:
:show-inheritance:

.. autofunction:: questdb.auth.sqlalchemy_engine

.. autofunction:: questdb.auth.psycopg_connect

.. autoclass:: questdb.auth.OidcConfig
:members:
:undoc-members:
:show-inheritance:

.. autoclass:: questdb.auth.TokenSet
:members:
:undoc-members:
:show-inheritance:

.. autoclass:: questdb.auth.FileTokenStore
:members:
:undoc-members:
:show-inheritance:

.. autoclass:: questdb.auth.TokenStore
:members:
:undoc-members:
:show-inheritance:

.. autoclass:: questdb.auth.TokenStoreKey
:members:
:undoc-members:
:show-inheritance:

.. autoclass:: questdb.auth.PersistedToken
:members:
:undoc-members:
:show-inheritance:

.. autoclass:: questdb.auth.Renderer
:members:
:show-inheritance:

.. autoexception:: questdb.auth.OidcError
:show-inheritance:

.. autoexception:: questdb.auth.OidcConfigError
:show-inheritance:

.. autoexception:: questdb.auth.OidcNetworkError
:show-inheritance:

.. autoexception:: questdb.auth.OidcInteractionRequired
:show-inheritance:

.. autoexception:: questdb.auth.OidcDeviceFlowError
:show-inheritance:

.. autoexception:: questdb.auth.OidcTimeoutError
:show-inheritance:
Loading