cdpc
Version:
child process management
29 lines (18 loc) • 543 B
JavaScript
const nps = require('../nps.js')
let pst = nps.nps()
console.log(pst.table)
for (let k in pst.table) {
console.log(pst.isChild(2, k), k)
}
console.log(pst.getAllChilds(1))
console.log('test anps...')
;(async () => {
let pst = await nps.anps()
for (let k in pst.table) {
console.log(pst.isChild(2, k), k)
}
console.log(pst.getAllChilds(3))
console.log(pst.getAllChilds(4))
console.log(pst.getChildsByCMDLine('/usr/local/pgsql-16.x/bin/postgres\x00-D\x00/usr/local/pgsql-16.x-data\x00-p\x005432'))
})();