Logging from an out of process server hook on windows does not work

Description

Note to developer of this ticket: Please modify pbspro/.appveyor.yml once this get fixed

Logging from hooks like "provisioning" or "periodic " does not work.
I tried testing it, below are the results.

------------------------------------

$ cat test.py
import pbs
import time
import os
import sys

f = open("testfile","a")
dat = "Current time: " + time.strftime("%X")+"\n"
f.write(dat)
f.close()
pbs.logmsg(2, "event is %s" % "SERVER_PROVISIONING")
pbs.logmsg(pbs.LOG_ERROR, "error event is %s" % "SERVER_PROVISIONING")
pbs.logmsg(pbs.LOG_WARNING, "warning event is %s" % "SERVER_PROVISIONING")
pbs.logmsg(pbs.LOG_DEBUG, "debug event is %s" % "SERVER_PROVISIONING")
pbs.logjobmsg("job1", "job event is %s" % "SERVER_PROVISIONING")
time.sleep(20)
pbs.event().accept("SERVER_PROVISIONING HOOK RAN SUCCESSFULLY")

-----------------------------------

01/12/2017 13:46:15;0100;Server@x34-64-win8;Req;;Type 0 request received from pbsadmin31@x34-64-win8.test3.pbspro.com, sock=916
01/12/2017 13:46:15;0100;Server@x34-64-win8;Req;;Type 49 request received from pbsadmin31@x34-64-win8.test3.pbspro.com, sock=788
01/12/2017 13:46:15;0100;Server@x34-64-win8;Req;;Type 15 request received from pbsadmin31@x34-64-win8.test3.pbspro.com, sock=916
01/12/2017 13:46:15;0100;Server@x34-64-win8;Job;0.x34-64-win8;Provisioning vnode x33-64-2k12 with AOE aoe1 started successfully
01/12/2017 13:46:36;0086;Server@x34-64-win8;Fil;;found pid_handles[0]=1060 to have exited
01/12/2017 13:46:36;0086;Server@x34-64-win8;Fil;;status=0

01/12/2017 13:46:45;0100;Server@x34-64-win8;Svr;Server@x34-64-win8;Provisioning of x33-64-2k12 with aoe1 for 0.x34-64-win8 timed out
01/12/2017 13:46:45;0080;Server@x34-64-win8;Node;Server@x34-64-win8;Vnode x33-64-2k12: Vnode offlined since it failed provisioning
01/12/2017 13:46:45;0080;Server@x34-64-win8;Job;0.x34-64-win8;Provisioning for job 0.x34-64-win8 failed, job queued
01/12/2017 13:46:46;0100;Server@x34-64-win8;Req;;Type 0 request received from pbsadmin31@x34-64-win8.test3.pbspro.com, sock=1080
01/12/2017 13:46:46;0100;Server@x34-64-win8;Req;;Type 49 request received from pbsadmin31@x34-64-win8.test3.pbspro.com, sock=788
01/12/2017 13:46:46;0100;Server@x34-64-win8;Req;;Type 15 request received from pbsadmin31@x34-64-win8.test3.pbspro.com, sock=1080
01/12/2017 13:46:46;0100;Server@x34-64-win8;Job;0.x34-64-win8;Provisioning vnode x33-64-2k12 with AOE aoe1 started successfully
01/12/2017 13:47:06;0086;Server@x34-64-win8;Fil;;found pid_handles[0]=788 to have exited
01/12/2017 13:47:06;0086;Server@x34-64-win8;Fil;;status=0

Acceptance Criteria

None

Status

Assignee

Unassigned

Reporter

Mohammad Riyaz M Hakki

Severity

None

OS

None

Start Date

None

Pull Request URL

None

Story Points

1

Components

Priority

Low
Configure