process A
If processB not exist {
Create processB
wait for event notification that processB has been created with read named pipe
}
establish write pipe to B
loop while command to process {
send command to B using named pipe
}
process B
establish read pipe
send event notification that read pipe has beem established
loop forever {
wait for pipe data
read command from pipe
execute command
}