Skip to content

Commit

Permalink
Revert "Revert "US-386386:Changes to support zdt upgrades""
Browse files Browse the repository at this point in the history
This reverts commit 1d00594
  • Loading branch information
arvas committed Feb 9, 2021
1 parent 1d00594 commit 0cc67b8
Show file tree
Hide file tree
Showing 9 changed files with 65 additions and 36 deletions.
11 changes: 11 additions & 0 deletions charts/pega/charts/installer/templates/_helpers.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,17 @@
{{- end -}}
{{- end }}

{{- define "validateAndExposeCustomUpgradeTypeSteps" }}
{{ if eq "" .Values.upgrade.upgradeStepsToRun }}
{{- $error := printf "upgradeStepsToRun must be configured in case of custom upgrade type" -}}
{{ required $error nil }}
{{- end }}
{{- $parts := splitList "," .Values.upgrade.upgradeStepsToRun }}
{{- range $parts }}
{{ . | upper }}: {{ true | quote }}
{{- end }}
{{- end }}

{{- define "performOnlyUpgrade" }}
{{- if (eq .Values.global.actions.execute "upgrade") -}}
true
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,17 @@ data:
# Specify the workload manager to load UDFs into db2zos
DB2ZOS_UDF_WLM: {{ .Values.zos.db2zosUdfWlm}}
{{- end }}
# Type of Upgrade
UPGRADE_TYPE: {{ .Values.upgrade.upgradeType }}

# If upgrade type is "custom" then exposing upgrade steps as env variables
{{ if eq "custom" .Values.upgrade.upgradeType }}
{{- $parts := splitList "," .Values.upgrade.upgradeStepsToRun }}
{{- range $parts }}
{{ . | upper }}: {{ true | quote }}
{{- end }}
{{- end }}

# Specify Database Type
DB_TYPE: {{ .Values.global.jdbc.dbType}}
# Action to be performed by installer image
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{{- if (eq (include "performUpgrade" .) "true") }}
{{- $validUpgradeType := list "in-place" "out-of-place" }}
{{- $validUpgradeType := list "in-place" "out-of-place-rules-upgrade" "out-of-place-data-upgrade" "zero-downtime-patch" "custom" }}
{{- if not (has .Values.upgrade.upgradeType $validUpgradeType) }}
{{- fail "Upgrade Type value is not correct. The valid values are 'in-place' 'out-of-place'" }}
{{- fail "Upgrade Type value is not correct. The valid values are 'in-place' 'out-of-place-rules-upgrade' 'out-of-place-data-upgrade' 'zero-downtime-patch' 'custom' " }}
{{- end }}
{{- end }}
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,12 @@ data:
{{- end }}
# Type of Upgrade
UPGRADE_TYPE: {{ .Values.upgrade.upgradeType }}

# If upgrade type is "custom" then exposing upgrade steps as env variables
{{ if eq "custom" .Values.upgrade.upgradeType }}
{{ include "validateAndExposeCustomUpgradeTypeSteps" . }}
{{- end }}

# Whether this is a Multitenant System ('true' if yes, 'false' if no)
MULTITENANT_SYSTEM: {{ .Values.multitenantSystem | quote}}
# UDF generation will be skipped if this property is set to true
Expand All @@ -40,6 +46,10 @@ data:
# Target Rules Schema name
TARGET_RULES_SCHEMA: {{ .Values.upgrade.targetRulesSchema }}
{{- end }}
{{- if .Values.upgrade.targetRulesSchema }}
# Temporary Data Schema name
TEMP_DATA_SCHEMA: {{ .Values.upgrade.tempDataSchema }}
{{- end }}
{{- if .Values.zos.zosProperties }}
# The location of the db2zos site specific properties file. Only used if the target system is a db2zos database
TARGET_ZOS_PROPERTIES: {{ .Values.zos.zosProperties }}
Expand Down
18 changes: 13 additions & 5 deletions charts/pega/charts/installer/values.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
---
image: "YOUR_IMAGE_NAME"
image: "arvasrikanth/pega-installer:bug86-1"
#image: "scrumteamwhitewalkers/installer:8.3.2"
# Creates a new System and replaces this with default system.Default is pega
systemName: "pega"
# During installations, the system name above is generated with the following production level.Default is 2
Expand All @@ -15,7 +16,7 @@ multitenantSystem: "false"
# UDF generation will be skipped if this property is set to true
bypassUdfGeneration: "true"
# Temporary password for administrator@pega.com that is used to install Pega Platform
adminPassword: ""
adminPassword: "install"
# Run the Static Assembler ('true' to run, 'false' to not run)
assembler: ""
# Bypass automatically truncating PR_SYS_UPDATESCACHE . Default is false.
Expand Down Expand Up @@ -49,10 +50,17 @@ zos:
# Upgrade specific properties
upgrade:
# Type of upgrade
# Valid values are 'in-place' , 'out-of-place'
upgradeType: ""
# Valid values are 'in-place', 'out-of-place-rules-upgrade', 'out-of-place-data-upgrade', "zero-downtime-patch", "custom"
upgradeType: "zero-downtime-patch"
#valid upgrade steps : disable_rule_creation, rules_migration, rules_upgrade, Data_upgrade,enable_rule_creation
#Pass the upgrade steps you want to run as a comma seperated list.
#Ex: upgradeStepsToRun: "disable_rule_creation,rules_migration,rules_upgrade,data_upgrade,enable_rule_creation"
upgradeStepsToRun: ""
# Specify target rules schema for migration and upgrade
targetRulesSchema: ""
targetRulesSchema: "rules123"
# Specify temp data schema for migration and upgrade
tempDataSchema: "data123"

# The commit count to use when loading database tables
dbLoadCommitRate: 100
# Update existing application will be run if this property is set to true
Expand Down
1 change: 1 addition & 0 deletions charts/pega/values-large.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -256,3 +256,4 @@ installer:
upgradeType: "in-place"
# Specify target rules schema for migration and upgrade
targetRulesSchema: ""
tempDataSchema: ""
44 changes: 16 additions & 28 deletions charts/pega/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,11 @@ global:
# each configuration option, see the project readme.

# Enter your Kubernetes provider.
provider: "YOUR_KUBERNETES_PROVIDER"
provider: "eks"

# Deploy Pega nodes
actions:
execute: "deploy"
execute: "upgrade"

# Provide JDBC connection information to the Pega relational database
# If you are installing or upgrading on IBM DB2, update the udb.conf file in the /charts/pega/charts/installer/config/udb directory with any additional connection properties.
Expand All @@ -21,37 +21,39 @@ global:
# progressiveStreaming=2;useJDBC4ColumnNameAndLabelSemantics=2;
# SQL Server jdbc:sqlserver://localhost:1433;databaseName=dbName;selectMethod=cursor;sendStringParametersAsUnicode=false
# PostgreSQL jdbc:postgresql://localhost:5432/dbName
url: "YOUR_JDBC_URL"
url: "jdbc:postgresql://ravens-eks.cyy9df92ztvl.us-east-1.rds.amazonaws.com:5432/dev"
# driverClass -- jdbc class. Valid values are:
#
# Oracle oracle.jdbc.OracleDriver
# IBM DB/2 com.ibm.db2.jcc.DB2Driver
# SQL Server com.microsoft.sqlserver.jdbc.SQLServerDriver
# PostgreSQL org.postgresql.Driver
driverClass: "YOUR_JDBC_DRIVER_CLASS"
driverClass: "org.postgresql.Driver"
# pega.database.type Valid values are: mssql, oracledate, udb, db2zos, postgres
dbType: "YOUR_DATABASE_TYPE"
dbType: "postgres"
# For databases that use multiple JDBC driver files (such as DB2), specify comma separated values for 'driverUri'
driverUri: "YOUR_JDBC_DRIVER_URI"
username: "YOUR_JDBC_USERNAME"
password: "YOUR_JDBC_PASSWORD"
driverUri: "https://jdbc.postgresql.org/download/postgresql-42.2.5.jar"
username: "postgres"
password: "postgres"
# CUSTOM CONNECTION PROPERTIES
# Add a list of ; delimited connections properties. The list must end with ;
# For example: connectionProperties=user=usr;password=pwd;
connectionProperties: ""
rulesSchema: "YOUR_RULES_SCHEMA"
dataSchema: "YOUR_DATA_SCHEMA"
rulesSchema: "rules832"
dataSchema: "data832"
customerDataSchema: ""

# If using a custom Docker registry, supply the credentials here to pull Docker images.
docker:
registry:
url: "YOUR_DOCKER_REGISTRY"
username: "YOUR_DOCKER_REGISTRY_USERNAME"
password: "YOUR_DOCKER_REGISTRY_PASSWORD"
url: "https://index.docker.io/v1/"
username: "arvasrikanth"
password: "12345pega"
#username: "scrumteamwhitewalkers"
#password: "RaWw@2019"
# Docker image information for the Pega docker image, containing the application server.
pega:
image: "pegasystems/pega"
image: "scrumteamwhitewalkers/installer:8.3.2"

# Upgrade specific properties
upgrade:
Expand Down Expand Up @@ -205,17 +207,3 @@ pegasearch:
image: "pegasystems/search"
memLimit: "3Gi"
replicas: 1

# Pega Installer settings.
installer:
image: "YOUR_INSTALLER_IMAGE:TAG"
# Set the initial administrator@pega.com password for your installation. This will need to be changed at first login.
# The adminPassword value cannot start with "@".
adminPassword: "ADMIN_PASSWORD"
# Upgrade specific properties
upgrade:
# Type of upgrade
# Valid values are 'in-place' , 'out-of-place'
upgradeType: "in-place"
# Specify target rules schema for migration and upgrade
targetRulesSchema: ""
Original file line number Diff line number Diff line change
Expand Up @@ -220,3 +220,4 @@ installer:
upgradeType: "in-place"
# Specify target rules schema for migration and upgrade
targetRulesSchema: ""
tempDataSchema: ""
1 change: 0 additions & 1 deletion terratest/src/test/pega/pega-gke-backend-config_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ package pega
import (
"github.com/gruntwork-io/terratest/modules/helm"
"github.com/stretchr/testify/require"
"k8s.io/ingress-gce/pkg/apis/backendconfig/v1beta1"
"path/filepath"
"testing"
)
Expand Down

0 comments on commit 0cc67b8

Please sign in to comment.