private void addNonCachedItems(@NotNull CompletionParameters parameters, @NotNull String prefix, @NotNull CompletionResultSet result) {
    final ProgressManager progressManager = ProgressManager.getInstance();
    ProgressIndicator mainIndicator = progressManager.getProgressIndicator();
    final ProgressIndicator indicator = mainIndicator != null ? new SensitiveProgressWrapper(mainIndicator) : new EmptyProgressIndicator();
    Future<Collection<T>> future = ApplicationManager
      .getApplication()
      .executeOnPooledThread(() -> progressManager.runProcess(() -> getItems(prefix, false, parameters), indicator));

    try {
      Collection<T> tasks = ProgressIndicatorUtils.awaitWithCheckCanceled(future, indicator);
      if (tasks != null) {
        addCompletionElements(result, this, tasks, 0);
      }
    }
    catch (CancellationException e) {
      throw e;
    }
    catch (Exception e) {
      LOG.error(e);
    }
  }
private void addNonCachedItems(@NotNull CompletionParameters parameters, @NotNull String prefix, @NotNull CompletionResultSet result)