Batch Start Notification (#169)

This change is part of the progressive results code. It will submit a notification from the service layer to indicate when execution of a batch has completed. This notification will contain the selection for batch, execution start time, and its ID. This will enable the extension to produce a header for the batch before the batch completes, in order to make it more clear to the user that execution is going on.

* Adding new event for batch start

* Unit tests

* Fixing comments as per @kevcunnane
This commit is contained in:
Benjamin Russell
2016-12-08 11:23:08 -08:00
committed by GitHub
parent ab97948005
commit 54f30887cc
7 changed files with 293 additions and 104 deletions

View File

@@ -10,7 +10,7 @@ namespace Microsoft.SqlTools.ServiceLayer.QueryExecution.Contracts
/// Parameters to be sent back as part of a QueryExecuteBatchCompleteEvent to indicate that a
/// batch of a query completed.
/// </summary>
public class QueryExecuteBatchCompleteParams
public class QueryExecuteBatchNotificationParams
{
/// <summary>
/// Summary of the batch that just completed
@@ -26,7 +26,14 @@ namespace Microsoft.SqlTools.ServiceLayer.QueryExecution.Contracts
public class QueryExecuteBatchCompleteEvent
{
public static readonly
EventType<QueryExecuteBatchCompleteParams> Type =
EventType<QueryExecuteBatchCompleteParams>.Create("query/batchComplete");
EventType<QueryExecuteBatchNotificationParams> Type =
EventType<QueryExecuteBatchNotificationParams>.Create("query/batchComplete");
}
public class QueryExecuteBatchStartEvent
{
public static readonly
EventType<QueryExecuteBatchNotificationParams> Type =
EventType<QueryExecuteBatchNotificationParams>.Create("query/batchStart");
}
}