* The ServerType of SQL OD in SMO is being changed to cloud. This is a minimal set of changes needed in sqltoolservice in order to keep everything working within ADS.
* SMO version update
* 3278 Moved functions related to Metadata from DataSourceFactory to MetadataFactory.cs
* 3278 Refactored DataSourceFactory to not be static. Added IDataSourceFactory interface.
* 3278 Refactored IKustoIntellisenseHelper.cs to not be static. Added IKustoIntellisenseHelper.cs interface.
* 3278 Removed unused functions from Scripter and deleted ScripterCore.cs because it was unused. Refactored Scripter.cs methods to not be static and created IScripter.cs
* 3278 Refactored datsasourceConnectionFactory in ConnectionService to use MEF through the InitializeService function
* 3278 Refactored IAutoCompleteHelper to not be static and added IAutoCompleteHelper interface.
* 3278 Removed unused classes DatabaseFullAccessException and FeatureWithFullDbAccess. Refactored ObjectExplorerService to use ImportingConstructor attribute. Removed commented out in KustoResultsReader. Removed unused functions from DatabaseLocksManager. Removed unused IDataSourceConnectionFactory from ConnectionService
* 3278 Moved SqlConnectionOpener class to new file. Added new interfaces IConnectedBindingQueue.cs and ISqlConnectionOpener.cs Added sqlConnectionOpener to dependency in ConnectedBindingQueue.
* 3278 Removed needsMetadata param from ConnectedBindingQueue. Added param to AddConnectionContext where it's used
* 3278 Refactored ConnectedBindingQueue to use MEF. Refactored usages to run against interface.
* 3278 Corrected ServiceHost namespace. Removed unused dependency to sqlToolsContext in LanguageService. Updated dependency in MetadataService and LanguageService to IProtocolEndpoint instead of ServiceHost
* 3278 Added back NextResult function and summary to KustoResultsReader. Renamed instance to _instance in ConnectionService and DatabaseLocksManager to stay consistent. Changed OpenDataSourceConnection to private in ConnectionService
* 3278 Converted helper methods back to static and removed backing interfaces
* 3278 Reverted AdminService > InitializeService to use ServiceHost as param
* Update form .NET Core 2.2 to .NET Core 3.1
- Global variable for projects
- Change TFMs from netcoreapp2.2 to netcoreapp3.1
- Update global.json
- Update build.json
- Remove direct framework cake TestCore task
- Update travis dotnet version
- Update azure pipline file
- Update vscode launch.json
* Add Central Package Management
* Fix xUnit Breaking Change for MemberData type
* Fix xUnit breaking change for duplicate test method name
* Fix Rang/Index type conflict with System.Rang/Index
* Update vscode tasks.json
* Change serviceHostExecutable path in ServiceTestDriver.cs
* Downgrade SDK version (https://github.com/appveyor/ci/issues/3440)
- Appveyor hasn't installed latest SDK therefore I downgrade it until they install it.
* Dump Microsoft.SqlServer.DACFx
* Revert "Update SMO (#875)"
This reverts commit 96593d66e3.
* Revert "Switch Tools Service to new SMO and Microsoft.Data.SqlClient driver (#865)"
This reverts commit 9d140b53f3.
* Bump SMO to 160.1910315.0-preview
* Adding Support for SqlOnDemand
* Updating unit test per comment
* Resolving comments. Enabling external table for sqlondemand
* Resolving comments. Enabling External tables for sqlondemand
* Enabling external tables for sqlondemand
* switch to ambient props and targets files
* build against Microsoft.Data.SqlClient
* build tests
* fix test bug
* temporarily add SMO nuget to the repo
* update to released Microsoft.Data package
* Added the query to get big data cluster endpoints
Added bigDataClusterEndpoints to ObjectExplorerSession
Added bigDataClusterEndpoints to ServerInfo
Fixes some tests.
* Removed bigDataClusterEndpoints from session
* Since server property to get IsBigDataCluster is not implemented yet, use query of sys.asseblies instead to unblock us. Need to use server property when it is available
Add options to ServerInfo, so no need to change the contract in the further when adding new properties. Will move the existing properties to option later
* Undo changes not needed
* Resolved PR comments.
* Fixed node is null exception when can't find NodePath.
* Added comments
* Removed not used using
* Catch sqlException for the reader of BDC endpoints and set empty list to the option.
* Added comments for returning empty nodes.
This changes adds the following two notifications from the results processing within a batch. These new notifications allows a consumer to stream results from a resultset instead of getting them all at once after the entire resultset has been fetched.
ResultsAvailable
This is issued after at least 1 row has been fetched for this resultset.
ResultsUpdated
This is issued periodically as more rows are available on this resultset. The final send of this notification when all rows have been fetched has the property 'Complete' set to true in the ResultSummary object.
Detailed Change Log:
* Initial completed implementation of QueryResults stream feature. 3 unittests still need fixing
* Fix for the 3 failing test. I will look into making MockBehavior strict again for the three tests later
* Making GetReader/GetWriter use filestream objects in FileShare.ReadWrite mode so the file can be concurrently read and written
* Changing resultsAvailable also to fire off on a timer instead of after 1st row
* adding a project for clr TableValuedFunction to produce result set with delays after each row. This is helpful in end to end testing.
* Fixing up some tests and simplifying implementation of result update timer
* Address review comments
* Some test fixes
* Disabled flaky test verification
This change modifies the logging framework within sqltoolservice.
Moves away from custom Logger object to start using .Net tracing framework. It supports for the static Trace and TraceSource way of logging. For all new code it is recommend that we log the log messages using the existing static Logger class, while the code changes will continue to route the older Trace.Write* calls from the process to same log listeners (and thus the log targets) as used by the Logger class. Thus tracing in SMO code that uses Trace.Write* methods gets routed to the same file as the messages from rest of SQLTools Service code.
Make changes to start using .Net Frameworks codebase for all logging to unify our logging story.
Allows parameter to set tracingLevel filters that controls what kinds of message make it to the log file.
Allows a parameter to set a specific log file name so if these gets set by external code (the UI code using the tools service for example) then the external code is aware of the current log file in use.
Adding unittests to test out the existing and improved logging capabilities.
Sequences of checkins in development branch:
* Saving v1 of logging to prepare for code review. Minor cleanup and some end to end testing still remains
* Removing local launchSettings.json files
* added support for lazy listener to sqltoolsloglistener and removed incorrect changes to comments across files in previous checkin
* Converting time to local time when writing entries to the log
* move the hosting.v2 to new .net based logging code
* removing *.dgml files and addding them to .gitignore
* fixing typo of defaultTraceSource
* Addressing pull request feedback
* Adding a test to verify logging from SMO codebase
* propogating changes to v1 sqltools.hosting commandoptions.cs to the v2 version
* Fixing comments on start and stop callstack methods and whitespaces
* Commenting a test that got uncommented by mistake
* addding .gitattributes file as .sql file was observed to be misconstrued as a binary file
* Differentiate External and FileTable types in object explorer list
- Add (External) and (File Table) to the labels
- Pre-fetch these properties to avoid perf hit
Note on testing: These are both quite hard to initialize, so adding tests to the integration tests would require always having a server with Polybase enabled / FileTable enabled. Given this I feel it should be OK to use manual testing. Long term, we should have unit-level tests that cover the functionality or figure out how to have a perfect pre-configured server and a set of tests to run the breadth of this logic against it.
* Fix handling of vNext servers to default to latest known version
- Default uplevel / unknown versions to the latest version
- In the IsValidFor check also just see if the server version registers as "All" since this is the default for unknown servers. This is a backup handler, the 1st fix is the primary one