Skip to content
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 pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"

[project]
name = "rda_python_dscheck"
version = "1.0.6"
version = "1.0.7"
authors = [
{ name="Zaihua Ji", email="[email protected]" },
]
Expand Down
12 changes: 4 additions & 8 deletions src/rda_python_dscheck/PgCheck.py
Original file line number Diff line number Diff line change
Expand Up @@ -367,13 +367,11 @@ def start_dschecks(cnd, logact = 0):

rcnt = 0
check_dscheck_locks(cnd, logact)
if not CHKHOST['chkhost']: email_dschecks(cnd, logact)
email_dschecks(cnd, logact)
purge_dschecks(cnd, logact)

# if 'NC' in PgOPT.params or not CHKHOST['chkhost']: return 0
if 'NC' in PgOPT.params: return 0
if CHKHOST['isbatch'] and 'CP' in PgOPT.params: check_dscheck_pends(cnd, logact)
# set_dscheck_options(CHKHOST['chkhost'], cnd, logact)
reset_process_limits()
if CHKHOST['isbatch']: rcnt = PgDBI.pgget("dscheck", "", "lockhost = '{}' AND pid > 0".format(PgLOG.PGLOG['PBSNAME']), logact)

Expand Down Expand Up @@ -927,8 +925,7 @@ def skip_dscheck_record(pgrec, host, logact = 0):
def start_dsrqsts(cnd, logact = 0):

check_dsrqst_locks(cnd, logact)
# if CHKHOST['chkhost']: return 1
if not CHKHOST['chkhost']: email_dsrqsts(cnd, logact)
email_dsrqsts(cnd, logact)
purge_dsrqsts(cnd, logact)
rcnd = cnd
rcnd += ("status = 'Q' AND rqsttype <> 'C' AND (pid = 0 OR pid < ptcount) AND " +
Expand Down Expand Up @@ -1242,9 +1239,8 @@ def start_dsupdts(cnd, logact = 0):

ctime = PgUtil.curtime(1)
check_dsupdt_locks(cnd, logact)
if not CHKHOST['chkhost']:
email_dsupdt_controls(cnd, logact)
email_dsupdts(cnd, logact)
email_dsupdt_controls(cnd, logact)
email_dsupdts(cnd, logact)

cnd += "pid = 0 and cntltime <= '{}' and action > '' AND einfo IS NULL ORDER by cntltime".format(ctime)
pgrecs = PgDBI.pgmget("dcupdt", "*", cnd, logact)
Expand Down
5 changes: 1 addition & 4 deletions src/rda_python_dscheck/dscheck.py
Original file line number Diff line number Diff line change
Expand Up @@ -602,10 +602,7 @@ def handle_dschecks():
def send_error_email():

msg = "Error message for DSCHECK on " + PgLOG.PGLOG['HOSTNAME']

PgLOG.set_email(msg, PgLOG.EMLTOP)
msg = PgLOG.send_email(msg)
PgLOG.pglog(msg, PgLOG.MSGLOG|PgLOG.FRCLOG)
PgLOG.send_email(msg)

#
# prepare a summary string for quit
Expand Down