Skip to content

Commit 87a247a

Browse files
authored
feat: add support for regex_parser_limit (#86)
* feat: add support for regex_parser_limit * add support for more properties
1 parent 0d7d4f9 commit 87a247a

4 files changed

Lines changed: 18 additions & 4 deletions

File tree

Chart.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
apiVersion: v1
22
name: pgdog
3-
version: v0.50
4-
appVersion: "0.1.36"
3+
version: v0.51
4+
appVersion: "0.1.37"

templates/config.yaml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,9 @@ data:
5858
{{- if .Values.queryParserEngine }}
5959
query_parser_engine = {{ .Values.queryParserEngine | quote }}
6060
{{- end }}
61+
{{- if .Values.regexParserLimit }}
62+
regex_parser_limit = {{ include "pgdog.intval" .Values.regexParserLimit }}
63+
{{- end }}
6164
{{- if .Values.preparedStatementsLimit }}
6265
prepared_statements_limit = {{ include "pgdog.intval" .Values.preparedStatementsLimit }}
6366
{{- end}}
@@ -91,6 +94,9 @@ data:
9194
{{- if .Values.reshardingCopyFormat }}
9295
resharding_copy_format = {{ .Values.reshardingCopyFormat | quote }}
9396
{{- end }}
97+
{{- if .Values.reshardingParallelCopies }}
98+
resharding_parallel_copies = {{ include "pgdog.intval" .Values.reshardingParallelCopies }}
99+
{{- end }}
94100
{{- if hasKey .Values "reloadSchemaOnDdl" }}
95101
reload_schema_on_ddl = {{ .Values.reloadSchemaOnDdl }}
96102
{{- end }}
@@ -121,6 +127,8 @@ data:
121127
server_lifetime = {{ include "pgdog.intval" (.Values.serverLifetime | default 86400000) }}
122128
log_connections = {{ .Values.logConnections | default "true" }}
123129
log_disconnections = {{ .Values.logDisconnections | default "true" }}
130+
log_dedup_threshold = {{ include "pgdog.intval" (.Values.logDedupThreshold | default 0) }}
131+
log_dedup_window = {{ include "pgdog.intval" (.Values.logDedupWindow | default 0) }}
124132
{{- if .Values.statsPeriod }}
125133
stats_period = {{ include "pgdog.intval" .Values.statsPeriod }}
126134
{{- end }}

test/values-full.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,13 +5,15 @@ env:
55
- name: RUST_LOG
66
value: trace
77
queryParserEngine: "pg_query_raw"
8+
regexParserLimit: 1000
89

910
# Sharding settings
1011
twoPhaseCommit: true
1112
twoPhaseCommitAuto: false
1213
systemCatalogs: omnisharded_sticky
1314
omnishardedSticky: true
1415
reshardingCopyFormat: binary
16+
reshardingParallelCopies: 1
1517
reloadSchemaOnDdl: true
1618

1719
memoryNetBuffer: 8192

values.yaml

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -535,8 +535,8 @@ control:
535535
# memoryStackSize: 2097152
536536

537537
# Query parser configuration
538-
# queryParser controls whether the query parser is enabled
539-
# Valid values: "auto", "on", "off"
538+
# queryParser controls whether the query parser and which features are enabled
539+
# Valid values: "auto", "on", "off", "session_control", "session_control_and_locks"
540540
# queryParser: "auto"
541541

542542
# queryParserEngine specifies which query parser engine to use
@@ -545,6 +545,10 @@ control:
545545
# queryParserEnabled is DEPRECATED - use queryParser instead
546546
# queryParserEnabled: true
547547

548+
# regexParserLimit specifies the maximum number of characters in a query that the regex parser
549+
# will inspect. Only applies when queryParser is "session_control" or "session_control_and_locks"
550+
# regexParserLimit: 1000
551+
548552
# Prometheus Collector configuration
549553
# Deploys a standalone Prometheus instance that collects metrics from all pgdog pods
550554
prometheusCollector:

0 commit comments

Comments
 (0)