code: private List<RunState> readRunStateBatch(List<WorkflowInstance> instances) throws IOException {
      assert instances.size() <= MAX_NUMBER_OF_ENTITIES_IN_ONE_BATCH_READ;
      final List<RunState> runStates = new ArrayList<>();
      var keyFactory = datastore.newKeyFactory();
      var keys = instances.stream().map(wfi -> activeWorkflowInstanceKey(keyFactory, wfi)).collect(toList());
      datastore.get(keys, entity ->
          runStates.add(entityToRunState(entity, parseWorkflowInstance(entity))));
      return runStates;
    }
docs: Strongly consistently read a batch of {@link RunState}s.