[roll] Roll fuchsia [setui][jobs] Make Manager's job_futures unordered

This CL changes the type of job::Manager::job_futures to
FuturesUnordered from FuturesOrdered. job_futures maintains a collection
of futures which are representing streams from external fidl
connections. When job_futures is FuturesOrdered, this adds a constraint
that the futures will only be recognized as completed in the order they
were added to the collection. This causes a problem when multiple
clients connect to the service and the first one to connect performs a
hanging get. Its stream of requests is pending when the second client
connects. The second client's stream will be added to job_futures, and
it may have a request ready but it cannot be processed because
job_futures is still waiting for the next request from the first client,
which might never come. By switching to FuturesUnordered, we can pick up
work as it becomes available. The ordering of requests from a client is
still maintained because we process those from the stream, which
maintains the order. It is only the requests across clients which become
unordered.

This CL also fixes issues with the existing test and adds a new test
case to handle the above scenario. An unbounded channel was used in
place of the FuturesOrdered (separate from the one discussed above)
because they have different behavior when the end is reached. When the
last item in FuturesOrdered is reached, the source is considered closed
and not placed back onto the job_futures collection. When a channel is
used, it's still considered open and so is put back onto the job_futures
collection.

Original-Fixed: 78623
Tests: fx test -o setui_service_tests
Multiply: setui_service_tests
Original-Reviewed-on: https://fuchsia-review.googlesource.com/c/fuchsia/+/542401
Original-Revision: dab6b213610d96279ce916cc205bddcda0b7fccd
GitOrigin-RevId: 88d3ce2fe5753daa635a015dd92ed7f50f3e7b13
Change-Id: I8a5cdb7059144cf260fea2477da8f2563a8f0675
1 file changed
tree: 05c14677969ab4f6161c81944f982c2777bf761c
  1. garnet/
  2. infra/
  3. peridot/
  4. third_party/
  5. topaz/
  6. zircon/
  7. firmware
  8. flower
  9. jiri.lock
  10. minimal
  11. prebuilts
  12. README.md
  13. stem
  14. test_durations
README.md

Integration

This repository contains Fuchsia's Global Integration manifest files.

Making changes

All changes should be made to the internal version of this repository. Our infrastructure automatically updates this version when the internal one changes.

Currently all changes must be made by a Google employee. Non-Google employees wishing to make a change can ask for assistance via the IRC channel #fuchsia on Freenode.

Obtaining the source

First install Jiri.

Next run:

$ jiri init
$ jiri import minimal https://fuchsia.googlesource.com/integration
$ jiri update

Third party

Third party projects should have their own subdirectory in ./third_party.