Skip to content
Draft
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
6 changes: 6 additions & 0 deletions applications/ssotap/values-idfdev.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,10 @@
cadc-tap:
config:
pg:
image:
pullPolicy: "Always"
tag: "tickets-DM-54118"

cloudsql:
enabled: true
instanceConnectionName: "science-platform-dev-7696:us-central1:science-platform-dev-e9e11de2"
Expand Down
5 changes: 5 additions & 0 deletions applications/tap/values-idfdev.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
cadc-tap:
config:
qserv:
image:
pullPolicy: "Always"
tag: "tickets-DM-54118"

kafka:
enabled: true

Expand Down
14 changes: 8 additions & 6 deletions charts/cadc-tap/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ IVOA TAP service
| config.bigquery.dataset | string | None, must be set if backend is `bigquery` | BigQuery dataset name |
| config.bigquery.image.pullPolicy | string | `"IfNotPresent"` | Pull policy for the TAP image |
| config.bigquery.image.repository | string | `"ghcr.io/lsst-sqre/lsst-tap-service"` | TAP image to use |
| config.bigquery.image.tag | string | `"3.16.0"` | Tag of TAP image to use |
| config.bigquery.image.tag | string | `"3.17.0"` | Tag of TAP image to use |
| config.bigquery.project | string | None, must be set if backend is `bigquery` | BigQuery project ID |
| config.bigquery.schema | string | `""` | Schema name for table mappings (optional) |
| config.database | string | `"dp02"` | Data Database name |
Expand All @@ -45,13 +45,13 @@ IVOA TAP service
| config.pg.database | string | None, must be set if backend is `pg` | Database to connect to |
| config.pg.host | string | None, must be set if backend is `pg` | Host to connect to |
| config.pg.image.pullPolicy | string | `"IfNotPresent"` | Pull policy for the TAP image |
| config.pg.image.repository | string | `"ghcr.io/lsst-sqre/tap-postgres-service"` | TAP image to use |
| config.pg.image.tag | string | `"1.26.0"` | Tag of TAP image to use |
| config.pg.image.repository | string | `"ghcr.io/lsst-sqre/lsst-tap-service"` | TAP image to use |
| config.pg.image.tag | string | `"3.17.0"` | Tag of TAP image to use |
| config.pg.username | string | None, must be set if backend is `pg` | Username to connect with |
| config.qserv.host | string | `"mock-db:3306"` (the mock QServ) | QServ hostname:port to connect to |
| config.qserv.image.pullPolicy | string | `"IfNotPresent"` | Pull policy for the TAP image |
| config.qserv.image.repository | string | `"ghcr.io/lsst-sqre/lsst-tap-service"` | TAP image to use |
| config.qserv.image.tag | string | `"3.16.0"` | Tag of TAP image to use |
| config.qserv.image.tag | string | `"3.17.0"` | Tag of TAP image to use |
| config.qserv.jdbcParams | string | `""` | Extra JDBC connection parameters |
| config.qserv.passwordEnabled | bool | false | Whether the Qserv database is password protected |
| config.sentryEnabled | bool | `false` | Whether Sentry is enabled in this environment |
Expand Down Expand Up @@ -101,7 +101,9 @@ IVOA TAP service
| tapSchema.resources | object | See `values.yaml` | Resource limits and requests for the TAP schema database pod |
| tapSchema.tapadm | object | `{"maxActive":2}` | Connection pool configuration for jdbc/tapadm |
| tapSchema.tapadm.maxActive | int | `2` | Maximum active connections (maxIdle will be set to this value) |
| tapSchema.tapuser | object | `{"maxActive":3}` | Connection pool configuration for jdbc/tapuser (query planning and tap_upload) |
| tapSchema.tapschemauser | object | `{"maxActive":3}` | Connection pool configuration for jdbc/tapschemauser (tap_schema reads for pg backend) |
| tapSchema.tapschemauser.maxActive | int | `3` | Maximum active connections (maxIdle will be set to this value) |
| tapSchema.tapuser | object | `{"maxActive":3}` | Connection pool configuration for jdbc/tapuser (data queries for pg; tap_schema reads for qserv/bigquery) |
| tapSchema.tapuser.maxActive | int | `3` | Maximum active connections (maxIdle will be set to this value) |
| tapSchema.tolerations | list | Tolerate GKE arm64 taint | Tolerations for the TAP schema database pod |
| tapSchema.type | string | "containerized" | Database backend type: "containerized", "cloudsql", or "external" |
Expand All @@ -115,7 +117,7 @@ IVOA TAP service
| uws.external.port | int | `5432` | Port of external PostgreSQL server |
| uws.image.pullPolicy | string | `"IfNotPresent"` | Pull policy for the UWS database image |
| uws.image.repository | string | `"ghcr.io/lsst-sqre/lsst-tap-uws-db"` | UWS database image to use |
| uws.image.tag | string | `"3.16.0"` | Tag of UWS database image to use |
| uws.image.tag | string | `"3.17.0"` | Tag of UWS database image to use |
| uws.maxActive | int | `5` | Maximum active connections (maxIdle will be set to this value) |
| uws.nodeSelector | object | `{}` | Node selection rules for the UWS database pod |
| uws.podAnnotations | object | `{}` | Annotations for the UWS databse pod |
Expand Down
32 changes: 29 additions & 3 deletions charts/cadc-tap/templates/tap-deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,14 @@ spec:
echo "Using BigQuery PluginFactory.properties in $dir"
fi
done
{{- else if eq .Values.config.backend "pg" }}
# Swap to PostgreSQL PluginFactory
for dir in /var/lib/tomcat/webapps/*/; do
if [ -f "${dir}WEB-INF/classes/PluginFactory-pg.properties" ]; then
cp "${dir}WEB-INF/classes/PluginFactory-pg.properties" "${dir}WEB-INF/classes/PluginFactory.properties"
echo "Using pg PluginFactory.properties in $dir"
fi
done
{{- end }}

echo "org.apache.catalina.startup.VersionLoggerListener.level = OFF" >> /var/lib/tomcat/conf/logging.properties
Expand Down Expand Up @@ -124,10 +132,9 @@ spec:
-Dtapschemauser.driverClassName=org.postgresql.Driver
-Dtapschemauser.url=jdbc:postgresql://localhost:5432/{{ .Values.tapSchema.database }}
{{- end }}
-Dtapschemauser.maxActive={{ .Values.tapSchema.tapuser.maxActive }}
-Dtapschemauser.maxActive={{ .Values.tapSchema.tapschemauser.maxActive }}
-Dtapuser.maxActive={{ .Values.tapSchema.tapuser.maxActive }}
-Dtapadm.maxActive={{ .Values.tapSchema.tapadm.maxActive }}
-Dtapuser.maxActive={{ .Values.tapSchema.tapuser.maxActive }}
-Duws.username={{ .Values.uws.username }}
{{- if or (eq .Values.uws.type "cloudsql") (eq .Values.uws.type "external") }}
-Duws.password=$UWS_DB_PASSWORD
Expand All @@ -144,14 +151,30 @@ spec:
{{- if eq .Values.config.backend "pg" }}
-Dtap.username={{ .Values.config.pg.username }}
-Dtap.password=$TAP_DB_PASSWORD
-Dtap.driverClassName=org.postgresql.Driver
-Dtap.url=jdbc:postgresql://{{ .Values.config.pg.host }}/{{ .Values.config.pg.database }}
-Dtap.maxActive=100
-Dqservuser.username=unused
-Dqservuser.password=unused
-Dqservuser.driverClassName=com.mysql.cj.jdbc.Driver
-Dqservuser.url=jdbc:mysql://localhost:3306/unused
-Dqservuser.maxActive=1
{{- else if eq .Values.config.backend "bigquery" }}
{{- else }}
{{- /* qserv and bigquery: jdbc/tapuser points at tap_schema (for VOSI-tables queries) */}}
-Dtap.username={{ .Values.tapSchema.username }}
-Dtap.password=$TAP_SCHEMA_PASSWORD
{{- if eq .Values.tapSchema.type "containerized" }}
-Dtap.driverClassName=com.mysql.cj.jdbc.Driver
-Dtap.url=jdbc:mysql://{{ template "cadc-tap.fullname" . }}-schema-db:3306/
{{- else if eq .Values.tapSchema.type "external" }}
-Dtap.driverClassName=org.postgresql.Driver
-Dtap.url=jdbc:postgresql://{{ .Values.tapSchema.external.host }}:{{ .Values.tapSchema.external.port }}/{{ .Values.tapSchema.database }}
{{- else }}
-Dtap.driverClassName=org.postgresql.Driver
-Dtap.url=jdbc:postgresql://localhost:5432/{{ .Values.tapSchema.database }}
{{- end }}
-Dtap.maxActive={{ .Values.tapSchema.tapuser.maxActive }}
{{- if eq .Values.config.backend "bigquery" }}
-Dtap.bigquery.project={{ .Values.config.bigquery.project }}
-Dtap.bigquery.dataset={{ .Values.config.bigquery.dataset }}
{{- if .Values.config.bigquery.schema }}
Expand All @@ -169,6 +192,7 @@ spec:
-Dqservuser.url=jdbc:mysql://{{ .Values.config.qserv.host }}/{{ .Values.config.qserv.jdbcParams }}
-Dqservuser.maxActive=100
{{- end }}
{{- end }}
-Dgafaelfawr_url={{ .Values.global.baseUrl }}/auth/api/v1/user-info
-Dgcs_bucket={{ .Values.config.gcsBucket }}
-Dgcs_bucket_url={{ .Values.config.gcsBucketUrl }}
Expand All @@ -188,6 +212,8 @@ spec:
-Durl.rewrite.enabled={{ .Values.config.urlRewrite.enabled | default true }}
-Durl.rewrite.rules="{{ .Values.config.urlRewrite.rules | default "ivoa.ObsCore:access_url" }}"
-Xmx{{ .Values.config.jvmMaxHeapSize }}
- name: "BACKEND"
value: {{ .Values.config.backend | quote }}
- name: "CATALINA_BASE"
value: "/var/lib/tomcat"
- name: "CATALINA_HOME"
Expand Down
17 changes: 11 additions & 6 deletions charts/cadc-tap/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -70,13 +70,13 @@ config:

image:
# -- TAP image to use
repository: "ghcr.io/lsst-sqre/tap-postgres-service"
repository: "ghcr.io/lsst-sqre/lsst-tap-service"

# -- Pull policy for the TAP image
pullPolicy: "IfNotPresent"

# -- Tag of TAP image to use
tag: "1.26.0"
tag: "3.17.0"

qserv:
# -- QServ hostname:port to connect to
Expand All @@ -94,7 +94,7 @@ config:
pullPolicy: "IfNotPresent"

# -- Tag of TAP image to use
tag: "3.16.0"
tag: "3.17.0"

# -- Whether the Qserv database is password protected
# @default -- false
Expand All @@ -120,7 +120,7 @@ config:
pullPolicy: "IfNotPresent"

# -- Tag of TAP image to use
tag: "3.16.0"
tag: "3.17.0"

# -- Address to a MySQL database containing TAP schema data
tapSchemaAddress: "cadc-tap-schema-db:3306"
Expand Down Expand Up @@ -255,7 +255,12 @@ tapSchema:
# -- Maximum active connections (maxIdle will be set to this value)
maxActive: 2

# -- Connection pool configuration for jdbc/tapuser (query planning and tap_upload)
# -- Connection pool configuration for jdbc/tapschemauser (tap_schema reads for pg backend)
tapschemauser:
# -- Maximum active connections (maxIdle will be set to this value)
maxActive: 3

# -- Connection pool configuration for jdbc/tapuser (data queries for pg; tap_schema reads for qserv/bigquery)
tapuser:
# -- Maximum active connections (maxIdle will be set to this value)
maxActive: 3
Expand Down Expand Up @@ -343,7 +348,7 @@ uws:
pullPolicy: "IfNotPresent"

# -- Tag of UWS database image to use
tag: "3.16.0"
tag: "3.17.0"

# -- Resource limits and requests for the UWS database pod
# @default -- See `values.yaml`
Expand Down
Loading