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

chore(core): add config hot-reload subsystem and implementation for pgwire credential changes #4168

Open
wants to merge 198 commits into
base: master
Choose a base branch
from

Conversation

sklarsa
Copy link
Contributor

@sklarsa sklarsa commented Jan 27, 2024

This swaps out PropServerConfiguration usage with ReloadingPropServerConfiguration. It should be a no-op, in preparation for hot-reloading config

Instead of inheriting from PropServerConfiguration, I decided to wrap it in a new class to avoid moving code around too much, since the validation logic is in the PropServerConfiguration constructor

@sklarsa sklarsa changed the title chore(core): Replaces PropServerConfiguration with ReloadingPropServerConfiguration chore(core): replaces PropServerConfiguration with ReloadingPropServerConfiguration Jan 29, 2024
@sklarsa sklarsa changed the title chore(core): replaces PropServerConfiguration with ReloadingPropServerConfiguration chore(core): replace PropServerConfiguration with ReloadingPropServerConfiguration Jan 29, 2024
bluestreak01 and others added 16 commits June 6, 2024 08:33
… missing

to be done - behaviour when the file is deleted after server startup:

Current logs:
```
Loading DEV CXX library: /io/questdb/bin-local/libquestdb.dylib
Reading log configuration from /tmp/dbroot-fixes/conf/log.conf
2024-06-06T07:52:14.406089Z A server-main unknown [DEVELOPMENT]. Copyright (C) 2014-2024, all rights reserved.
2024-06-06T07:52:14.589491Z A server-main darwin-aarch64 [Vanilla,0, 64 bits, 8 processors]
2024-06-06T07:52:14.598472Z I server-main Web Console is up to date
2024-06-06T07:52:14.599733Z A server-main Server config: /tmp/dbroot-fixes/conf/server.conf
Server configuration file does not exist! /tmp/dbroot-fixes/conf/server.conf
```
we do not disable hot-reload if it was started with hot-reload enabled
@sklarsa sklarsa marked this pull request as ready for review June 7, 2024 14:38
@sklarsa sklarsa requested a review from jerrinot June 7, 2024 14:39
GitHub Actions - Rebuild Native Libraries and others added 2 commits June 7, 2024 14:41
@ideoma
Copy link
Collaborator

ideoma commented Jun 7, 2024

[PR Coverage check]

😍 pass : 299 / 476 (62.82%)

file detail

path covered line new line coverage
🔵 io/questdb/std/filewatch/WindowsAccessorImpl.java 0 15 00.00%
🔵 io/questdb/KqueueFileWatcher.java 0 71 00.00%
🔵 io/questdb/ServerConfiguration.java 0 1 00.00%
🔵 io/questdb/std/filewatch/FileWatcherWindows.java 0 24 00.00%
🔵 io/questdb/KqueueAccessor.java 0 21 00.00%
🔵 io/questdb/ServerMain.java 7 13 53.85%
🔵 io/questdb/std/filewatch/FileWatcherFactory.java 5 8 62.50%
🔵 io/questdb/Bootstrap.java 11 17 64.71%
🔵 io/questdb/std/str/Utf8s.java 2 3 66.67%
🔵 io/questdb/network/Epoll.java 2 3 66.67%
🔵 io/questdb/std/filewatch/LinuxAccessor.java 5 6 83.33%
🔵 io/questdb/std/filewatch/LinuxAccessorFacadeImpl.java 7 8 87.50%
🔵 io/questdb/DynamicPropServerConfiguration.java 85 96 88.54%
🔵 io/questdb/std/filewatch/FileWatcher.java 65 73 89.04%
🔵 io/questdb/std/filewatch/LinuxFileWatcher.java 67 73 91.78%
🔵 io/questdb/DynamicUsernamePasswordMatcher.java 28 29 96.55%
🔵 io/questdb/PropServerConfiguration.java 5 5 100.00%
🔵 io/questdb/PropBootstrapConfiguration.java 1 1 100.00%
🔵 io/questdb/cutlass/pgwire/DefaultPgWireAuthenticatorFactory.java 5 5 100.00%
🔵 io/questdb/FactoryProviderImpl.java 2 2 100.00%
🔵 io/questdb/PropertyKey.java 1 1 100.00%
🔵 io/questdb/std/Os.java 1 1 100.00%

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants