* Set up CI with Azure Pipelines
[skip ci]
* Update publishSqlCoreProject.yml for Azure Pipelines
* Update publishSqlCoreProject.yml for Azure Pipelines
* Update publishSqlCoreProject.yml for Azure Pipelines
* Update publishSqlCoreProject.yml for Azure Pipelines
* Update publishSqlCoreProject.yml for Azure Pipelines
* Updating json rpc target framework
* Fixing packages to pack
* fixing pattern
* Fixing project pattern
* adding versioning schema
* fixing versioning scheme
* fixing nuget package name
* adding name
* removing var
* Fixing stuff
* Fixing stuff
* Fixing stuff
* Fixing build name
* removing build name
* fixing name
* fixing stuff
* fix pattern
* Fixing stuff
* Fixing feed
* Fix stuff
* Fixing feed
* fixing proj name
* Fixing stuff
* Fixing netframework version
* Fixing target framework
* Adding target framework to dependency
* Fixing frameworks
* adding net7.0
* adding flag
* Fixing target frameworks and making code compatible with lang version
* fixed flag
* Fixing assembly name
* Adding hosting in nuget package
* Fixing tests
* Moving steps to its main pipeline
* only releasing when release is true
* Fixing build scripts
* Adding version to csproj for packaging
* adding version
* Fix dirs
* Adding version number to right prop group
* Adding necessary dis
* Fixing build number
* fixing datatype
* Using different var
* Removing unused yml
* Adding back nullables to hosting
* Adding back more nullables
* adding back more nullables
* moving some props to dir level
* Fixing tests
* Removing dup properties
* Supporting different target frameworks in hosting
* Removing additional setting in csproj
* signing sql core dll in publish
* Fixing version setting
* Adding to build
* Added signing and packaging flag
* Fixing file pattern
* init
* More fixes
* moving filters from contracts to core OE classes
* Fixing some tests
* More fixes and added doc comments
* Fixing tests
* Quick refactoring
* more cleanups
* cleanup
* Adding stateless OE
* Adding null checks
* Making group by schema independent of settings
* Fixing tests
* Removing node info from core oe code
* Fixing tests and moving OE code to its own project
* moving oe to own project
* Removing changes to Kusto
* Removing azure access token from service layer
* Fixing project description and title
* Fixing file name typo
* Removing unused strings from service layer
* Fixing localized strings in tests
Adding comments to stateless OE
* Fixing stuff
* Update src/Microsoft.SqlTools.SqlCore/Microsoft.SqlTools.SqlCore.csproj
Co-authored-by: Charles Gagnon <chgagnon@microsoft.com>
* Fixing project nesting
* Fixing more stuff and removing OE class
* Cleanup
* Code cleanup
* fixing oe service provider
* Fixing test name
* Remove using
* Update src/Microsoft.SqlTools.SqlCore/ObjectExplorer/SmoModel/SmoQueryContext.cs
Co-authored-by: Charles Gagnon <chgagnon@microsoft.com>
* Fixing syntax error
* Adding project to locproject
* Fixing stuff
* Fixing errors
* sorting usings
---------
Co-authored-by: Charles Gagnon <chgagnon@microsoft.com>
* Open XEL file changes
* placeholders for openxel
* add observable xe reader
* md format tweaks
* implement localfile as a new session type
* add ErrorMessage to session stopped notice
* fix flaky test
* handle already running session
* fix stopped session event send on file completion
* fix flaky unit test
* Update XElite and dependent versions
* Fix errors after merge and remove failing tests for now
* Fix main merge mess-up.
Address comments.
Add one more relevant test.
* Remove extra namespace.
* Remove unnecessary import
* Fix build error
* Address comments.
* Remove disabiling JSON002 compiler warning
* Address comments and update json handling
* Fix build error
* Fix integration test (emerged due to Main merge mess up)
* Clean up code (no functional changes)
---------
Co-authored-by: Karl Burtram <karlb@microsoft.com>
Co-authored-by: shueybubbles <david.shiflet@microsoft.com>
* Initial user management code
* WIP
* Fix whitespace
* WIP user objects
* WIP user objects
* Cleanup ported code
* WIP
* WIP
* Update the User contracts
* Additional cleanups
* Remove warning silencing which isn't intended for this PR
* Fix some warnings as error in CI
* Bump to SDK 7.0 and related updates
* More net 7 updates
* Install SDK 2.0 for ESRP
* Fix typo
* Address comment and update integration test script
* Disable new warnings from SDK update
* Renames ShowPlan directories along with corresponding namespaces
* Renames ShowPlanGraphUtils to ExecutionPlanGraphUtils
* Revert "Renames ShowPlanGraphUtils to ExecutionPlanGraphUtils"
This reverts commit 5dc2696ae906598447eed7360a3f342218432b83.
* Reverts show plan tests name change.
* Renames show plan test XML files.
* Renames ported directory to ShowPlan and updates namespace accordingly
* Adding recommendations
* Adding raw graph type in execution plan graph contracts
* Fixing function name and concising string formatting
* Converting localized string to a function
* Using better names in contract props
Formatting names in a better way
* Getting rid of unnecessary getter, setters and private props
* Fixing localized strings, comments and imports
* Fixing some contracts
* Fixing csproj formatting
* Fixing var names
* Fixing xml comments
* Remove xunit dependency from testdriver
* swap expected/actual as needed
* Convert Test.Common to nunit
* port hosting unit tests to nunit
* port batchparser integration tests to nunit
* port testdriver.tests to nunit
* fix target to copy dependency
* port servicelayer unittests to nunit
* more unit test fixes
* port integration tests to nunit
* fix test method type
* try using latest windows build for PRs
* reduce test memory use
* 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
* 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
* Switch to the unified SMO NuGet so all binaries are strong named and signed.
* use one AssemblyLoader instance for all loads
* Revert "use one AssemblyLoader instance for all loads"
This reverts commit 48c59ffd5c57152de281c87acdbcad7ddf7ab760.
* Stop creating multiple AssemblyLoadContext objects during composition, per https://github.com/dotnet/coreclr/issues/19632
* restore high entropyva property
* Improve the comment
* Update SMO to 150 and fix scripting for objects with a single quote in their name.
* restore newtonsoft reference
* Revert "fixed perf tests and added more scenarios (#683)"
This reverts commit aa2b30f486.
* Revert "Switch to the unified SMO NuGet so all binaries are strong named and signed. (#682)"
This reverts commit 69961992bb.
* Upgrade SMO packages to fix issue with scripting tables when Script Dependencies is true on the script options.
* use linux style import with case matching file name
* WIP
* This code makes it work!
* Adding similar exception hanling behavior to saving result sets
* Adding unit tests for new extension methods
Auto-cleanup of proj file whitespace
* Implementing changes as per code review comments
Implementation of the resource provider APIs in order to support Create Firewall Rule. Provides definition for a ResourceProvider and Authentication service. The ResourceProvider supports firewall rules for now, and since authentication is routed through that method it will call into the auth service to set up the current account to be used.
Additional notes:
- Fixed deserialization by adding an Accept header. This shouldn't be necessary, but for some reason the firewall rule defaults to XML without this
- Use generic server list and parse the ID to get the resource group, avoiding a large number of extra calls for each RG
- Errors now include error message from the API
Porting of the vast majority of Azure-related code from SSDT. This is very large, so I want to put this out as one large "lift and shift" PR before I do the tools-service specific JSON-RPC service handlers, connect a new account handler (as the code to get necessary info from accounts and subscriptions isn't fully complete) and add tests over these
**What's in this PR**:
- Created 3 new projects:
- Microsoft.SqlTools.ResourceProvider will host the executable that accepts requests for Azure-related actions over the JSON-RPC protocol. This must be separate from other DLLs since a direct dependency on the Azure SDK DLLs fails (they're NetStandard 1.4 and you can't reference them if you have RuntimeIdentifiers in your .csproj file)
- Microsoft.SqlTools.ResourceProvider.Core is where all the main business logic is, including definitions and logic on how to navigate over resources and create firewall rules, etc.
- Microsoft.SqlTools.ResourceProvider.DefaultImpl is the actual Azure implementation of the resource provider APIs. The reason for separating this is to support eventual integration back into other tools (since their Azure and Identity services will be different).
- Implemented the AzureResourceManager that connects to Azure via ARM APIs and handles creating firewall rule and querying databases. The dependent DLLs have had major breaking changes, so will need additional verification to ensure this works as expected
- Ported the unit tests for all code that was not a viewmodel. Viewmodel test code will be ported in a future update as we plumb through a service-equivalent to these. Also, the DependencyManager code which has overlap with our service provider code is commented out. Will work to uncomment in a future update as it has value to test some scenarios
**What's not in this PR**:
- Identity Services. We currently just have a stub for the interface, and even that will likely change a little
- anything JSON-RPC or registered service related. These will be adapted from the viewmodels and added in a separate PR
* scripting working with race conditions
* new service works with no race conditions
* use new scripting service and commented out tests
* refactored peek definition to use mssql-scripter
* fixed peek definition tests
* removed auto gen comment
* fixed peek definition highlighting bug
* made scripting async and fixed event handlers
* fixed tests (without cancel and plan notifs)
* removed dead code
* added nuget package
* CR comments + select script service implementation
* minor fixes and added test
* CR comments and script select
* added unit tests
* code review comments and cleanup
* Bump SMO to 140.2.5 to pick-up private XEvent binaries
* Pick up SMO binaries from the build lab
* Add ProfilerService class placeholder
* Update SMO nuget package to include DB Scoped XEvents
* Stage changes
* Stage changes
* Update SMO to use RTM dependencies and remove separate SqlScript package
* Stage changes
* Iterate on profiler service
* Fix post-merge break in localization
* More refactoring
* Continue iterating on profiler
* Add test profiler listener
* Address a couple of the code review feedback
* Fix AppVeyor build break
* Use self-cleaning test file
* Initial .net core 2.0 conversion
* Convert a few more projects to .net core 2.0
* Convert a few more projects to .net core 2.0
* Fix build.cmd errors
* Add mising nuget package
* Remove dead code
* Add checked in references to workaround nuget package issues
* Update SLN file to refer to correct csproj files
* Rename applications to workaround .net core tooling bug
* Update nuget package with SQL Parser changes
* Add PreserveCompliationContext to avoid MEF bug
* Update smo version to pickup .net core 2 changes
* Pickup latest SMO changes to fix merge break
* Actually pickup correct SMO binaries
* Add support for SLES 12.2
* Fix break running archiving on Linux
* Revert "Add support for SLES 12.2"
This reverts commit 95cdb6d0e35a425be5c0081345d214079cbdc3db.
* Update to latest SMO build
* Install .Net Core 2 during install phase
* Move .Net Core install
* Try to reference dotnet.exe directly
* Fix code coverage script for CSPROJ instead of project.json
* Turn off test that is unreliable in AppVeyor builds.
* Fix appveyor.yml line feed.
* Turn off another flaky test failing in AppVeyor