edge_vars #4

  • //
  • guest/
  • perforce_software/
  • sdp/
  • main/
  • Server/
  • Unix/
  • p4/
  • common/
  • bin/
  • edge_vars
  • View
  • Commits
  • Open Download .zip Download (2 KB)
# This file is sourced by scripts that work with edge servers.

# It sets the correct list db.* files that are edge-specific in the
# federated architecture.  This version is dependent on the version of
# p4d in use.
#
# See: https://www.perforce.com/perforce/doc.current/manuals/p4sag/Content/P4SAG/commit-edge-start.html

# Note: $P4D_VERSION looks something like "2020.2.2202902."  In comparisons
# below, a lexigraphical rather than numeric comparison operator is used.
# The greater-than symbol '>' can be thought of as "greater to or equal to"
# in this context, because a version string like "2020.2.2292902" is
# lexigraphically greater than the string "2020.2", so checking
# '> "2020.2"' can be interpreted as "If the p4d major version is greater
# than or equal to 2020.2.
if [[ "${P4D_VERSION:-1970.1}" > "2020.2" ]]; then
   ExcludedTables=db.have,db.working,db.locks,db.resolve,db.revsh,db.workingx,db.resolvex,db.stash,db.haveg,db.workingg,db.locksg,db.resolveg,db.storagesh,db.storagesx
elif [[ "${P4D_VERSION:-1970.1}" > "2019.0" ]]; then
   ExcludedTables=db.have,db.working,db.locks,db.resolve,db.revsh,db.workingx,db.resolvex,db.stash,db.haveg,db.workingg,db.locksg,db.resolveg,db.storagesh
elif [[ "${P4D_VERSION:-1970.1}" > "2018.2" ]]; then
   ExcludedTables=db.have,db.working,db.locks,db.resolve,db.revsh,db.workingx,db.resolvex,db.stash,db.haveg,db.workingg,db.locksg,db.resolveg
elif [[ "${P4D_VERSION:-1970.1}" > "2015.1" ]]; then
   ExcludedTables=db.have,db.working,db.locks,db.resolve,db.revsh,db.workingx,db.resolvex,db.stash,db.haveg,db.workingg,db.locksg,db.resolveg
else
   ExcludedTables=db.have,db.working,db.locks,db.resolve,db.revsh,db.workingx,db.resolvex,db.stash
fi

if [[ "${P4D_VERSION:-1970.1}" > "2019.0" ]]; then
   CheckpointTables=$ExcludedTables,db.view,db.label,db.revsx,db.revux,db.storage
else
   CheckpointTables=$ExcludedTables,db.view,db.label,db.revsx,db.revux
fi
# Change User Description Committed
#4 31369 C. Thomas Tyler Released SDP 2024.2.31367 (2025/03/23).
Copy Up using 'p4 copy -r -b perforce_software-sdp-dev'.
#3 29701 C. Thomas Tyler Released SDP 2023.1.29699 (2023/07/11).
Copy Up using 'p4 copy -r -b perforce_software-sdp-dev'.
#2 27822 C. Thomas Tyler Released SDP 2020.1.27820 (2021/06/19).
Copy Up using 'p4 copy -r -b perforce_software-sdp-dev'.
#1 25933 C. Thomas Tyler Released SDP 2019.2.25923 (2019/08/05).
Copy Up using 'p4 copy -r -b perforce_software-sdp-dev'.
//guest/perforce_software/sdp/dev/Server/Unix/p4/common/bin/edge_vars
#1 25920 C. Thomas Tyler Added new 'edge_vars' file to dynamically set list of edge-specific
db tables based on current P4D version.

Updated edge_dump.sh, recover_edge.sh, and load_checkpoint.sh
to use the new edge_vars file.

Made edge_dump.sh and recover_edge.sh shellcheck v0.6.0 compliant,
along with load_checkpoint.sh.