Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions src/VisualStudio/Core/Def/RoslynPackage.cs
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ protected override void RegisterInitializeAsyncWork(PackageLoadTasks packageInit

Task PackageInitializationBackgroundThreadAsync(PackageLoadTasks packageInitializationTasks, CancellationToken cancellationToken)
{
return ProfferServiceBrokerServicesAsync();
return ProfferServiceBrokerServicesAsync(cancellationToken);
}

Task PackageInitializationMainThreadAsync(PackageLoadTasks packageInitializationTasks, CancellationToken cancellationToken)
Expand Down Expand Up @@ -130,12 +130,12 @@ Task OnAfterPackageLoadedMainThreadAsync(PackageLoadTasks afterPackageLoadedTask
}
}

private async Task ProfferServiceBrokerServicesAsync()
private async Task ProfferServiceBrokerServicesAsync(CancellationToken cancellationToken)
{
// Proffer in-process service broker services
var serviceBrokerContainer = await this.GetServiceAsync<SVsBrokeredServiceContainer, IBrokeredServiceContainer>(this.JoinableTaskFactory).ConfigureAwait(false);
var serviceBrokerContainer = await this.GetServiceAsync<SVsBrokeredServiceContainer, IBrokeredServiceContainer>(throwOnFailure: true, cancellationToken).ConfigureAwait(false);

serviceBrokerContainer.Proffer(
serviceBrokerContainer!.Proffer(
WorkspaceProjectFactoryServiceDescriptor.ServiceDescriptor,
(_, _, _, _) => ValueTaskFactory.FromResult<object?>(new WorkspaceProjectFactoryService(this.ComponentModel.GetService<IWorkspaceProjectContextFactory>())));

Expand Down
Loading