commit | 454ba3e2bc275c5ee32958a1c9bc18f87717cca8 | [log] [tgz] |
---|---|---|
author | Lasse R.H. Nielsen <lrn@google.com> | Tue Jun 08 15:48:34 2021 +0200 |
committer | GitHub <noreply@github.com> | Tue Jun 08 15:48:34 2021 +0200 |
tree | 3c9be5f84730469130506e3380314d7041d08fc1 | |
parent | 57c80c9fde44af5a3cea9958e7d5b0c05bab0b07 [diff] |
Tweak null safety (#54) * Tweak the Null Safety migrated APIs and implementation. * Revert depending on a separate priority queue. Update the existing code be tailored for this particular use-case, which also avoids the nullability issues leading to changing it in the first place. * Update changelog and some documentation. * Add tests for load_balancer. Fix bugs found by tests. Change type of LoadBalancer.runMultiple back to List<Future<R>>. * Use `package:lints` for linting. Ignore misfiring lints.
Helps with isolates and isolate communication in Dart. Requires the dart:isolate
library being available. Isolates are not available for Dart on the web.
The package contains individual libraries with different purposes.
The “ports.dart” sub-library contains functionality for creating SendPort
s and reacting to values sent to those ports.
The “isolate_runner.dart” sub-library introduces an IsolateRunner
class that gives easy access to the Isolate
functionality, and also gives a way to run new functions in the isolate repeatedly, instead of just on the initial spawn
call.
The “registry.dart” sub-library provides a way to create an object registry, and give access to it across different isolates.
The “load_balancer.dart” sub-library can manage multiple Runner
objects, including IsolateRunner
, and run functions on the currently least loaded runner.
Please file feature requests and bugs at the issue tracker.