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

Update gatewayd appVersion to v0.9.7 and refactor configuration #15

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
2 changes: 1 addition & 1 deletion Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name: gatewayd
description: Cloud-native database gateway and framework for building data-driven applications, Like API gateways, for databases.
type: application
version: 0.1.0
appVersion: v0.9.6
appVersion: v0.9.7
home: https://www.gatewayd.io
icon: https://github.com/gatewayd-io/docs/blob/main/assets/gatewayd-logotype-light.png
sources:
Expand Down
47 changes: 31 additions & 16 deletions files/gatewayd.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -31,28 +31,31 @@ metrics:

clients:
default:
network: tcp
address: psql-postgresql.default.svc.cluster.local:5432
tcpKeepAlive: False
tcpKeepAlivePeriod: 30s # duration
receiveChunkSize: 8192
receiveDeadline: 0s # duration, 0ms/0s means no deadline
receiveTimeout: 0s # duration, 0ms/0s means no timeout
sendDeadline: 0s # duration, 0ms/0s means no deadline
dialTimeout: 60s # duration
# Retry configuration
retries: 3 # 0 means no retry and fail immediately on the first attempt
backoff: 1s # duration
backoffMultiplier: 2.0 # 0 means no backoff
disableBackoffCaps: false
writes:
network: tcp
address: psql-postgresql.default.svc.cluster.local:5432
tcpKeepAlive: False
tcpKeepAlivePeriod: 30s # duration
receiveChunkSize: 8192
receiveDeadline: 0s # duration, 0ms/0s means no deadline
receiveTimeout: 0s # duration, 0ms/0s means no timeout
sendDeadline: 0s # duration, 0ms/0s means no deadline
dialTimeout: 60s # duration
# Retry configuration
retries: 3 # 0 means no retry and fail immediately on the first attempt
backoff: 1s # duration
backoffMultiplier: 2.0 # 0 means no backoff
disableBackoffCaps: false

pools:
default:
size: 10
writes:
size: 10

proxies:
default:
healthCheckPeriod: 60s # duration
writes:
healthCheckPeriod: 60s # duration

servers:
default:
Expand All @@ -64,6 +67,18 @@ servers:
certFile: ""
keyFile: ""
handshakeTimeout: 5s # duration
loadBalancer:
strategy: ROUND_ROBIN # ROUND_ROBIN, RANDOM, WEIGHTED_ROUND_ROBIN
consistentHash:
useSourceIp: false
# Optional configuration for strategies that support rules (e.g., WEIGHTED_ROUND_ROBIN)
# loadBalancingRules:
# - condition: "DEFAULT" # Currently, only the "DEFAULT" condition is supported
# distribution:
# - proxyName: "writes"
# weight: 70
# - proxyName: "reads"
# weight: 30

api:
enabled: True
Expand Down
2 changes: 1 addition & 1 deletion files/gatewayd_plugins.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -27,4 +27,4 @@ plugins:
- EXIT_ON_STARTUP_ERROR=False
- SENTRY_DSN=https://70eb1abcd32e41acbdfc17bc3407a543@o4504550475038720.ingest.sentry.io/4505342961123328
- CACHE_CHANNEL_BUFFER_SIZE=100
checksum: b153242dfb81dcd63b4444118252be5917b8a1b0f0f775c474946224d2a297eb
checksum: 7a882a6d82105373feb5d2e428d928efd379c240d994b4167a5799d77af3d938
2 changes: 1 addition & 1 deletion templates/configmap.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,5 @@ metadata:
labels:
app: gatewayd
data:
GATEWAYD_CLIENTS_DEFAULT_ADDRESS: {{ .Values.gatewayd.clients.default.address }}
GATEWAYD_CLIENTS_DEFAULT_WRITES_ADDRESS: {{ .Values.gatewayd.clients.default.writes.address }}
GATEWAYD_LOGGERS_DEFAULT_LEVEL: {{ .Values.gatewayd.loggers.default.level }}
7 changes: 4 additions & 3 deletions values.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
gatewayd:
clients:
default:
address: "psql-postgresql:5432"
writes:
address: "psql-postgresql:5432"
loggers:
default:
# For production, use info
Expand Down Expand Up @@ -96,7 +97,7 @@ podDisruptionBudget:
# maxUnavailable: 1

gatewaydPluginsConfig:
enabled: false
enabled: true

gatewaydConfig:
enabled: false
enabled: true