HPCC-8579 Running hpcc-init setup on dafilesrv takes a long time

The chown's that are performed on every startup are unnecessary and can be
painfully slow at times, resulting in problems starting thors (especially
after a drive swap).

These chowns were also masking a bug where the ownership of the config
files generated by configgen at system startup were not correct - they would
get corrected the second time the system was started.

Signed-off-by: Richard Chapman <rchapman@hpccsystems.com>
HPCC-9689 Buffered stderr mode in IPipeProcess doesn't seem to work

There are two problems:

1. In order to avoid blocking, reading from stderr (in buffered stderr mode)
are non-blocking. Any code that uses this mode needs to be aware of that.

2. Once no more reading from stdout is happening, and we are waiting for the
child process to terminate, we need to carry on reading from stderr (blocking,
now) to sensure that all data is fetched.

Signed-off-by: Richard Chapman <rchapman@hpccsystems.com>
HPCC-9765 Fetching list of possible targets is slow

Switched from TpTargetClusterQuery function to TpLogicalClusterQuery.

Fixes HPCC-9765

Signed-off-by: Gordon Smith <gordon.smith@lexisnexis.com>
Merge pull request #4674 from GordonSmith/HPCC-9765

HPCC-9765 Fetching list of possible targets is slow

Reviewed-By: Kevin Wang <kevin.wang@lexisnexis.com>
Reviewed-By: Richard Chapman <rchapman@hpccsystems.com>
HPCC-9728 Unordered multi core join helper not working

Due to a simple bug, the unordered version of the multi core
join helper output no rows.
[As enabled with ,HINT(parallel_match), HINT(unsorted_output)]

Signed-off-by: Jake Smith <jake.smith@lexisnexis.com>
Merge branch 'hpcc-9728' into candidate-4.0.2

Signed-off-by: Richard Chapman <rchapman@hpccsystems.com>
Merge pull request #4662 from richardkchapman/dafilesrv-slow

HPCC-8579 Running hpcc-init setup on dafilesrv takes a long time

Reviewed-by: Gavin Halliday <ghalliday@hpccsystems.com>
Merge pull request #4667 from richardkchapman/pipe-error

HPCC-9689 Buffered stderr mode in IPipeProcess doesn't seem to work

Reviewed-by: Gavin Halliday <ghalliday@hpccsystems.com>
HPCC-9694 - Global LOOP filter condition fails

A LOOP with a filter condition and a global loop query, will fail
if the slaves finish after a different number of iterations,
which is very likely.

Ensure that keep iterating until all have signalled finished.

Signed-off-by: Jake Smith <jake.smith@lexisnexis.com>
Merge branch 'hpcc-9694' into candidate-4.0.2

Signed-off-by: Richard Chapman <rchapman@hpccsystems.com>
HPCC-9618 - Improve distribute abort handling

Hash distribute could deadlock if an exception occurred in
the receiver or a write handler. In either case, the handling
must ensure that the sender and it's write handlers are told to
abort.

Signed-off-by: Jake Smith <jake.smith@lexisnexis.com>
Minor change following review
Merge branch 'hpcc-9618' into candidate-4.0.2

Signed-off-by: Richard Chapman <rchapman@hpccsystems.com>
Merge remote-tracking branch 'origin/candidate-4.0.2' into closedown-4.0.x

Signed-off-by: Richard Chapman <rchapman@hpccsystems.com>
Merge remote-tracking branch 'origin/closedown-4.0.x'

Signed-off-by: Richard Chapman <rchapman@hpccsystems.com>