Commit Graph

497 Commits

Author SHA1 Message Date
udeeshagautam
9551022fff Feature/cms backend (#776)
* First cut of CMS get Server Api - returns only names

* Adding Proper naming and some more functions

* Adding add remove Server and tests for it

* Changing relative path to derive from KeyChain.Urn and Nuget update

* Adding async thread for requests

* Addressing CR comments and adding one more test

* Adressed PR comments around naming
2019-03-01 11:55:19 -08:00
Karl Burtram
022282800a Move managed parser into its own project (test code coverage) (#774)
* Created New ManagedBatchParser project in .NetStandard

* Addressing PR Comments

* Resolve 'No Repository' warning.

* Move batch parser tests to integrations test project

* Fix SLN file
2019-02-07 20:13:03 -08:00
kisantia
0a172f3c8e Add DacFx Generate Deploy Plan Operation (#768)
* initial adding upgrade plan

* upgrade plan request from ADS works

* now data loss operations are returned

* fixes after rebasing

* refactoring to use GenerateDeployPlan instead of UpgradePlan

* improving test

* Addressing comments

* changing abstract execute to virtual

* changed GenerateDeployPlanOepration to use Execute()

* addressing comments

* simplyfing deploy options

* adding deploy options to deploy and generate script operations
2019-02-06 17:22:20 -08:00
kisantia
1917100bfb Add DacFx Generate Deploy Script operation (#759)
* Adding DacFx Generate Deploy Script operation
2019-01-25 11:34:28 -08:00
Arvind Ranasaria
5f6d500977 This change ensures that we send back only one 'isComplete=true' message for a given result set (#763)
Fixes:
The streaming protocol is now tightened to ensure that only the last message for a result set contain isCompleted=true. Now isCompleted=true is never sent in isAvailable message.
Tightened logic in sending messages to make sure that no duplicate messages get sent out due to concurrent processing.
Made a fix to a null reference exception when processing special action which was a pre-existing benign bug.
Testing: Added 1 more new test that runs existing tests concurrently 1000 times to make sure no random timing issues are observed and tightened verifications to existing tests to ensure no duplicate messages and only one isComplete=true message is sent across.

* tightening the protocal to ensure only one message (the last one) with completed=true is sent back for a single result set within a query batch
2019-01-11 10:21:52 -08:00
Karl Burtram
0fd98df79b Update SqlClient to 4.6.0 (#761) 2019-01-07 16:22:35 -08:00
Arvind Ranasaria
e4808c12aa Feat/result streaming - Fix for issue #746 in toolsservice and issue Microsoft/azuredatastudio#3348 (#753)
* fix for issues 746 & azuredatastudio issue 3348

* test coverage improvement for results streaming

* addressed minor review comments

* adding generated file test/CodeCoverage/package-lock.json to workaround code coverage issue.
2018-12-04 20:49:05 -08:00
Matt Irvine
1a9a750fa8 Fix CodePages version issue (#752) 2018-11-29 16:37:59 -08:00
kisantia
d5fd968b3c DacFx import/export (#728)
Adding DacFx import/export/deploy/extract functionality
2018-11-27 16:10:46 -08:00
Arvind Ranasaria
6dd9a4b5f1 Feat/result streaming (#721)
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
2018-11-26 10:24:54 -08:00
Matt Irvine
7f28f249de Add support for Azure Active Directory connections (#727) 2018-11-13 11:50:30 -08:00
Karl Burtram
6153279840 Update broken BindingQueue test from previous commit (#725) 2018-10-31 15:24:02 -07:00
Karl Burtram
df023da0ba Revert "Rollback SMO to latest 14.0 version (#722)" (#723)
This reverts commit 407e9feb40.
2018-10-30 17:20:25 -07:00
Karl Burtram
407e9feb40 Rollback SMO to latest 14.0 version (#722)
* Rollback SMO to latest 14.0 version

* Add back nunit package reference
2018-10-30 12:13:23 -07:00
Karl Burtram
2b6eeb19ab Update references to use non preview references (#718) 2018-10-24 17:23:23 -07:00
2966a53b70 Fix: DATETIMEOFFSET data types should be ISO formatted (#714) 2018-10-22 16:46:02 -07:00
Karl Burtram
a241a4510b Bump .Net Core SDK to 2.2.100 Preview (#715)
* Bump .Net Core SDK to 2.2

* Update travis file

* Try to fix broken AppVeyor code coverage
2018-10-22 15:54:17 -07:00
Arvind Ranasaria
1ef70ef259 Bug fix for https://github.com/Microsoft/azuredatastudio/issues/2923 and misc other fixes (#711) 2018-10-19 13:25:18 -07:00
Aditya Bist
0efed221ee Agent/improve steps (#710)
* added stepInfo for editing jobs/steps

* added schedules to history requests

* added alerts and schedules to history

* formatting

* code review comments

* removed smo import

* changed and optimized histories, steps, alerts and operators
2018-10-16 13:24:32 -07:00
Karl Burtram
7c1710d396 Reopen connections prior to creating query execution data readers (#704)
* Reopen connections prior to creating query execution data readers

* Reopen connection if an exception was rasied executing the query

* Fix unit tests
2018-10-08 12:41:04 -07:00
Matt Irvine
f45155aa4a Fix OE and Binding Queue reliability bugs (#702) 2018-10-05 14:14:36 -07:00
David Shiflet
f99061866c Upgrade SMO to 150 preview (#701)
* 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
2018-10-03 18:33:40 -04:00
ranasaria
335e9fb38c Logging for ga (#698)
Adding a robustness change to call close on logger before process exit.
Also adding a designer.cs file needed by a script csproj that got missed out in previous checkin due to .gitignore entry.
2018-09-25 17:26:22 -07:00
AlexFsmn
41d0ef1814 Fixed correct value types when saving columns to a json file (#691) 2018-09-25 14:24:39 -07:00
Karl Burtram
d31ce985ce Check that connection is open in ReliableConnectionHelperTest (#694) 2018-09-25 14:23:29 -07:00
ranasaria
09652cccd1 Enhanced Logging for sqltoolsservice (#695)
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
2018-09-24 23:55:59 -07:00
Leila Lali
0c1648b1c4 fixed couple of issues in the perf tests (#693) 2018-09-18 14:35:47 -07:00
Mustafa Sadedil
98018c5292 Save as XML feature added (#684)
Similar approach used like Save as JSON or Save as CSV.
2018-09-10 12:11:51 -07:00
Alan Ren
d0e06ff55a Exclude the preview features from code coverage (#688) 2018-09-06 13:34:59 -07:00
Karl Burtram
066be2f46f Revert "Switch to the unified SMO NuGet" (#686)
* 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.
2018-09-04 11:01:44 -07:00
Leila Lali
aa2b30f486 fixed perf tests and added more scenarios (#683)
* fixed perf tests and added more scenarios
2018-08-27 10:57:41 -07:00
David Shiflet
69961992bb Switch to the unified SMO NuGet so all binaries are strong named and signed. (#682) 2018-08-20 08:27:52 -04:00
Anthony Dresser
3c0a282333 Serialize Connection String (#680)
* add string serialization

* add unadded file

* changed code to be testable, added test

* moved test to correct location

* change to send undefined rather than error if the serialization fails

* update request name
2018-08-16 13:10:14 -07:00
David Shiflet
5cdab53da8 Upgrade SMO packages to fix issue with scripting tables (#678)
* 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
2018-08-09 08:11:18 -04:00
Kevin Cunnane
f0b85bab3c Fix failing Loc lookups in hosting service (#679)
* Remove XUnit warnings which clogged up output

* Use default namespace to fix loc lookup errors
- Fixed errors due to localization change
- Also removed internals visible attribute that could cause subtle issues where the hosting service doesn't work for other apps if things change

* Add CI build and test for new projects

* Up version number so we can pick up fix in nuget packages
2018-08-08 16:21:21 -07:00
Kevin Cunnane
71195869e1 Add v2 of the Hosting Service and build nuget packages for it (#675)
* Port v2 of Hosting service to SqlToolsService
- Renamed project to .v2 so that existing hosted service isn't impacted
- Copied over the CoreServices project which contains ConnectionServiceCore and other reusable services for anything interacting with MSSQL
- Ported unit test project across and verified tests run.

* Nuget package support for reusable DLLs

* Use 1.1 version per Karl's suggestion

* Use correct license URL and project URL

* Use new SMO packages
2018-08-07 12:59:57 -07:00
Madeline MacDonald
4b9807f0cf Add ability to create sessions from templates, and list existing sessions (#671)
* Initial changes to connect to existing sessions

* Creating new profiler sessions

* Some session template changes

* Fixing errors

* Cleaning up comments, string constants, and formatting

* Removing commented code
2018-08-02 12:50:26 -07:00
Karl Burtram
38cf5414ce Add IncludePassword parameter to Get Connection String request (#670)
* Add IncludePassword flag to get connection string method

* Override connection application name

* Fix typo

* Fix test break

* Use ****** as password placeholder
2018-08-01 15:16:01 -04:00
Sebastian Pfliegel
84f62a3e85 Added more options to SaveResultsAsCsvRequestParams (#669)
Fixes Microsoft/sqlopsstudio#203
Options:
LineSeperator
TextIdentifier
Encoding
2018-08-01 15:15:11 -04:00
David Shiflet
0b4228a7d9 Update Sql Management Objects to latest version (#666) 2018-07-27 17:25:16 -04:00
Aditya Bist
f293a54af7 Multiple batch execution time (#664)
* fixed bug where execution time was wrong for multiple batches

* fixed bug where multiple execution would show wrong execution time

* simplified logic
2018-07-25 16:45:26 -07:00
Karl Burtram
7c96ceb501 Get Connection String request handler (#665) 2018-07-25 15:03:00 -04:00
Matt Irvine
c7ac3aeaae Fix bug where strings that looked like dates were transformed when reading messages (#663)
* Do not try to parse dates when reading messages

* Add test
2018-07-24 12:37:08 -04:00
Chirag Rupani
77a08b4bdd Added support for specifying delimiter while exporting query results as CSV (#653) 2018-07-12 10:39:23 -07:00
Karl Burtram
704b25f082 Add Get Alerts and Get Operators handlers (#648)
* Stage changes

* stage changes 2

* WIP 3

* Add Get Alerts and Get Operators handlers

* Add Get Proxy request handler
2018-06-28 21:12:10 -07:00
Karl Burtram
c6906c3b66 Add Get Schedules request handler (#646) 2018-06-27 08:25:19 -07:00
Karl Burtram
539d579a9b Add Agent Job Defaults request handler (#644)
* Add Agent Job Defaults request handler

* Fix a couple bugs
2018-06-26 13:57:47 -07:00
Madeline MacDonald
838a7e4fab Profiler notifications (#640)
* Initial changes for adding lost event notifications

* Handling polling errors by notifying listeners

* Restructuring lost events & testing

* Minor fixes to tests

* Add back in filtering

* Changing how lost events are found

* Cleaning up tests
2018-06-18 17:43:22 -07:00
Leila Lali
7322854c7b fixed the bug with view triggers in object explorer (#639) 2018-06-18 11:36:24 -07:00
Karl Burtram
29fb715ad5 Add initial schedule request handlers (#638) 2018-06-18 10:18:23 -07:00