Result Streaming (#3319)

* handle releasing data when the grid is unrendered

* update sqlops

* add complete to sqlops

* update protocol

* update protocol

* formatting

* update sqlops.d.ts

* stash

* better handling of results streaming

* formatting

* improvments to result streaming

* bump slickgrid and address a performance bottleneck

* remove unnecessary code

* formatting

* update locks

* optimize large values in the grid

* formatting

* formatting

* update yarn

* bump packages

* yarn

* bump

* yarn lock

* locking

* yarn

* fix duplicate result sets

* fix event stream versions

* yarn
This commit is contained in:
Anthony Dresser
2018-11-29 15:16:53 -08:00
committed by GitHub
parent a04a9eb5ad
commit afb1ebebd5
22 changed files with 419 additions and 191 deletions

View File

@@ -265,8 +265,11 @@ export class ExtHostDataProtocol extends ExtHostDataProtocolShape {
$onBatchComplete(handle: number, batchInfo: sqlops.QueryExecuteBatchNotificationParams): void {
this._proxy.$onBatchComplete(handle, batchInfo);
}
$onResultSetComplete(handle: number, resultSetInfo: sqlops.QueryExecuteResultSetCompleteNotificationParams): void {
this._proxy.$onResultSetComplete(handle, resultSetInfo);
$onResultSetAvailable(handle: number, resultSetInfo: sqlops.QueryExecuteResultSetNotificationParams): void {
this._proxy.$onResultSetAvailable(handle, resultSetInfo);
}
$onResultSetUpdated(handle: number, resultSetInfo: sqlops.QueryExecuteResultSetNotificationParams): void {
this._proxy.$onResultSetUpdated(handle, resultSetInfo);
}
$onQueryMessage(handle: number, message: sqlops.QueryExecuteMessageParams): void {
this._proxy.$onQueryMessage(handle, message);

View File

@@ -444,8 +444,11 @@ export class MainThreadDataProtocol implements MainThreadDataProtocolShape {
public $onBatchComplete(handle: number, batchInfo: sqlops.QueryExecuteBatchNotificationParams): void {
this._queryManagementService.onBatchComplete(batchInfo);
}
public $onResultSetComplete(handle: number, resultSetInfo: sqlops.QueryExecuteResultSetCompleteNotificationParams): void {
this._queryManagementService.onResultSetComplete(resultSetInfo);
public $onResultSetAvailable(handle: number, resultSetInfo: sqlops.QueryExecuteResultSetNotificationParams): void {
this._queryManagementService.onResultSetAvailable(resultSetInfo);
}
public $onResultSetUpdated(handle: number, resultSetInfo: sqlops.QueryExecuteResultSetNotificationParams): void {
this._queryManagementService.onResultSetUpdated(resultSetInfo);
}
public $onQueryMessage(handle: number, message: sqlops.QueryExecuteMessageParams): void {
this._queryManagementService.onMessage(message);

View File

@@ -197,8 +197,12 @@ export function createApiFactory(
extHostDataProvider.$onBatchComplete(provider.handle, batchInfo);
});
provider.registerOnResultSetComplete((resultSetInfo: sqlops.QueryExecuteResultSetCompleteNotificationParams) => {
extHostDataProvider.$onResultSetComplete(provider.handle, resultSetInfo);
provider.registerOnResultSetAvailable((resultSetInfo: sqlops.QueryExecuteResultSetNotificationParams) => {
extHostDataProvider.$onResultSetAvailable(provider.handle, resultSetInfo);
});
provider.registerOnResultSetUpdated((resultSetInfo: sqlops.QueryExecuteResultSetNotificationParams) => {
extHostDataProvider.$onResultSetUpdated(provider.handle, resultSetInfo);
});
provider.registerOnMessage((message: sqlops.QueryExecuteMessageParams) => {

View File

@@ -193,7 +193,11 @@ export abstract class ExtHostDataProtocolShape {
/**
* Callback when a result set has been returned from query execution and can be displayed
*/
$onResultSetComplete(handle: number, resultSetInfo: sqlops.QueryExecuteResultSetCompleteNotificationParams): void { throw ni(); }
$onResultSetAvailable(handle: number, resultSetInfo: sqlops.QueryExecuteResultSetNotificationParams): void { throw ni(); }
/**
* Callback when a result set has been returned from query execution and can be displayed
*/
$onResultSetUpdate(handle: number, resultSetInfo: sqlops.QueryExecuteResultSetNotificationParams): void { throw ni(); }
/**
* Callback when a message generated during query execution is issued
*/
@@ -504,7 +508,8 @@ export interface MainThreadDataProtocolShape extends IDisposable {
$onQueryComplete(handle: number, result: sqlops.QueryExecuteCompleteNotificationResult): void;
$onBatchStart(handle: number, batchInfo: sqlops.QueryExecuteBatchNotificationParams): void;
$onBatchComplete(handle: number, batchInfo: sqlops.QueryExecuteBatchNotificationParams): void;
$onResultSetComplete(handle: number, resultSetInfo: sqlops.QueryExecuteResultSetCompleteNotificationParams): void;
$onResultSetAvailable(handle: number, resultSetInfo: sqlops.QueryExecuteResultSetNotificationParams): void;
$onResultSetUpdated(handle: number, resultSetInfo: sqlops.QueryExecuteResultSetNotificationParams): void;
$onQueryMessage(handle: number, message: sqlops.QueryExecuteMessageParams): void;
$onObjectExplorerSessionCreated(handle: number, message: sqlops.ObjectExplorerSession): void;
$onObjectExplorerSessionDisconnected(handle: number, message: sqlops.ObjectExplorerSession): void;