Commit Graph

353 Commits

Author SHA1 Message Date
Alexander Ivanov
0f598dd30b Add sqlproj property to trace the origin of the project. (#18670)
* Add sqlproj property to trace the origin of the project.

As part of the database migration process (schema conversion, in particular) we want to be able to tell when converted schemas are being built/deployed to the actual database server. Given that we rely on the SQL Database Projects ADS extension for the compilation/deployment, we don't have too many options other than updating the said extension.

The suggested approach is to make the following changes:
1) Add new property to the sqlproj file (called `DatabaseSource`), which will maintain the origin(s) of the project. The property can contain multiple values (separated by semicolon), in case same project contains objects produced by multiple sources (extract schema, convert from another database, etc.).
2) During build and deploy actions, send the well-known values from the newly added property to the telemetry. We don't want to send any random value of the property, as it may raise some privacy concerns. Instead we define a list of the well-known values that we know do not carry any personal information and send those, if they are specified.

This change adds all necessary APIs to the SQl Database projects extension which will be consumed by our migration extensions to populate new `DatabaseSource` property.

* Use `undefined` instead of `null`

Co-authored-by: Kim Santiago <kisantia@microsoft.com>
2022-04-18 11:38:10 -07:00
Kim Santiago
794daa3440 add SDK option to create project from db quickpick (#19100)
* Add SDK option to create project from db quickpick

* cleanup
2022-04-15 09:57:48 -07:00
Udeesha Gautam
02f859ac92 fix for sensitive text in output message (#19071) 2022-04-14 09:54:06 -07:00
Kim Santiago
379b24d78c Add confirmation before converting to SDK-style project (#18893)
* Add confirmation before updating to SDK-style project

* update string

* update string

* update other learn more url
2022-04-07 15:48:05 -07:00
Kim Santiago
d6dab3dd18 Remove build and folder includes when converting to SDK-style project (#18889)
* remove Build and Folder Includes

* add tests

* cleanup

* rollback if there was an error during the conversion
2022-04-01 21:04:18 -04:00
Kim Santiago
b65a6bd741 update DW target platform name in sql projects (#18843)
* update DW target platform name

* remove Microsoft from target platform names

* fix merge conflict
2022-03-31 15:30:30 -07:00
Kim Santiago
8537a30996 fix project not getting updated after schema cmopare (#18850) 2022-03-29 11:55:12 -07:00
Kim Santiago
f002a26fe4 Add convert to SDK style project to context menu (#18847)
* differentiate between sdk and legacy style projects in tree

* switch to legacy

* add to context menu

* add function call
2022-03-29 10:15:36 -07:00
Leila Lali
459fab256e Sql Proj: Adding a new sqlproj template for SQL dbs (#18636) 2022-03-29 09:06:56 -07:00
Kim Santiago
2f825f8a97 add initial SDK-style project migration (#18827)
* add initial SDK-style project migration

* addressing comments
2022-03-28 16:29:14 -07:00
Leila Lali
aad20bc338 Chaning the name of server in deploy option if target is Azure (#18828) 2022-03-28 15:07:09 -07:00
Nemanja Milovančević
5e68ff1dfe Make mssql extension a module (#18804)
* Rebase from main branch

* import from module

* Add mssql module ref

Co-authored-by: Charles Gagnon <chgagnon@microsoft.com>
2022-03-24 11:09:55 -07:00
Kim Santiago
5a87e552bc move system dbs to bottom of the list in update project from db dialog (#18791) 2022-03-22 18:12:19 -07:00
Charles Gagnon
a6d442bb3b Consolidate extension typings files (#18765)
* Consolidate extension typings files

* fix
2022-03-18 09:24:22 -07:00
Kim Santiago
3071a7b710 Add more telemetry for sql database projects (#18751)
* add more telemetry for sql database projects

* add publishToContainer events

* send target platform when publishing

* add duration for createProjectFromDb and updateProjectFromDb
2022-03-17 16:44:10 -07:00
Vasu Bhog
80007a72cc Remove sql-bindings logic from sql-database-projects (#18754)
* remove sql-bindings logic from sql-database-projects
2022-03-17 11:36:28 -07:00
Kim Santiago
023e10b496 Add preview and bump versions (#18749) 2022-03-17 10:47:50 -07:00
Kim Santiago
7181d4c79e Make SDK-style project a checkbox option instead of separate template (#18698)
* switch to using a checkbox instead of separate template for new SDK style project

* let project provider provide sdk learn more url

* Reorder
2022-03-11 16:54:53 -08:00
Kim Santiago
5f2d8b2bd5 remove sql server 2005 and 2008 as options for sql database projects (#18664)
* remove sql server 2005 and 2008 from target platforms

* also remove 2005 and 2008 from SqlTargetPlatform enum

* fix a windows test
2022-03-10 18:11:49 -08:00
Kim Santiago
5bb35d4eed update Microsoft.Build.Sql version to 0.1.3-preview in templates (#18659) 2022-03-07 17:34:30 -08:00
Leila Lali
8e9957adbe SQLProj: No docker image build needed for deploying a database to docker (#18629) 2022-03-04 14:32:43 -08:00
Kim Santiago
9e3d678536 add learn more link for sdk style in create project from db dialog (#18637) 2022-03-04 13:00:21 -08:00
Benjin Dubishar
c64655ae71 Benjin/project update bug (#18532)
* correct result.success

* shifting success message to actually check success

* keying on errorMessage rather than success
2022-02-25 16:59:28 -08:00
Kim Santiago
7b92c9eb65 only show confirmation message for apply all changes, not for view changes in schema compare (#18520) 2022-02-22 13:33:24 -08:00
Kim Santiago
b33afe3efb add back SDK style project template (#18448) 2022-02-18 09:54:10 -08:00
Vasu Bhog
0f385b386f Add SQL Binding Disconnected Scenario (#18440)
* disconnected scenario

* match parameters in mssql
2022-02-17 14:20:13 -08:00
Kim Santiago
d24a289af5 fix SDK style projects not being able to find system dacpacs (#18218)
* fix SDK style projects not being able to find system dacpacs

* fix tests
2022-02-16 09:36:01 -08:00
Z Chen
9e574ae602 Database Projects - Add existing file (#18066)
* Add existing file to sqlproj

* Address PR comments

* Fix failing test

* Add convertSlashesForSqlProj to test failure
2022-02-14 15:04:57 -08:00
Kim Santiago
7078b9ea33 hide sdk style project template (#18308) 2022-02-10 15:50:37 -08:00
Kim Santiago
fa4161d9a1 Add SDK style project option to create project from db dialog (#18243)
* add sdk style project template

* update description and order

* add SDK style project option to create project from db dialog

* fix test

* switch to checkbox

* remove not used string

* fix test
2022-02-10 10:49:46 -08:00
Vasu Bhog
9b3dd4247c Add SQL Binding Password Prompts (#18241)
* add password warning

* password prompts
2022-02-09 00:42:27 -08:00
Vasu Bhog
b7fe4c09e2 vBump STS to 1.9.5 & add optional application name parameter for connection string (#18201)
* include application name optional parameter

* vBump STS to 1.9.5
2022-02-04 17:56:59 -08:00
Kim Santiago
243afc9f54 add confirmation message to update project from db dialog (#18199) 2022-02-02 17:04:12 -08:00
Charles Gagnon
8e1e9a95c3 Move to MS vscodetestcover and update lodash (#18192) 2022-02-01 14:09:10 -08:00
Charles Gagnon
1c9ba64ee0 check-param-names (#18189) 2022-01-31 12:39:22 -08:00
Charles Gagnon
aff161b344 Have sql db proj publish command return publishing promise (#18139) 2022-01-25 14:11:30 -08:00
Kim Santiago
f0dd31c457 fix excluding pre/post/none deploy scripts in sdk style projects (#18117) 2022-01-25 11:49:52 -08:00
Charles Gagnon
7509188764 Fix sql db project string (#18046)
* Fix string

* Update string
2022-01-21 13:39:55 -08:00
Benjin Dubishar
251901fee7 Disabling failing test pending investigation (#18130) 2022-01-20 09:29:53 -08:00
Charles Gagnon
aaffbc6b25 Fix azdata api loading in sql proj for VS Code (#18122) 2022-01-19 11:01:20 -08:00
Kim Santiago
967cd2b102 Add SDK sql project template (#18058)
* add sdk style project template

* update description and order

* update template

* update template and add link

* remove ToolsVersion and xmlns from project node

* update template name to SQL Database (SDK)
2022-01-19 10:08:47 -08:00
Kim Santiago
6a288dcaa5 add types instead of using any in project.ts (#18091) 2022-01-14 12:53:57 -08:00
Vasu Bhog
d4534f875f Add Connection String Enhancement for SQL Bindings (#18011)
* sql database work to prompt users to choose connections

* add test
2022-01-13 17:54:46 -08:00
Charles Gagnon
19039c8fc7 Update VS Code MSSQL typings (#18055)
* Update VS Code MSSQL typings

* fix compile
2022-01-12 11:31:01 -08:00
Benjin Dubishar
292e60a767 Apply changes from remote database to sqlproj - sql-database-projects changes (#17738)
* update project from database

* update project from database

* Leftover merge update

* Slight refactor to add vscode entrypoints

* Re-adding leftover schemacompare bits that reference database project changes

* Removing unnecessary function

* Addiung GetDSP command to package.json

* tests and a race condition fix

* remove custom UUID generation code

* swapping awaits for voids on promises

* PR feedback

* PR feedback

* Hide update project command from vscode

* Swapping cross-extension commands for bound extension contract

* Re-adding schema compare radio buttons for sqlproj

* Adding refresh after project update

* Populating list of project scripts just before comparison to avoid missing script errors of project was separately edited

* Adding missing await for okay button enable check

* Correcting schema compare source when populated from a project

* Rename UpdateDataModel to be more clear

* Fix incorrectly changed type

* Added new runComparison schema compare command, hooked up to sqlproj extension

* Added progress indicator for "apply now" option

* moved string literal to constant

* Added missing await

* Setting missing "saveScmpButton" state to fix test

* Revert "Setting missing "saveScmpButton" state to fix test"

This reverts commit 55612c9def24ac9e3398f5bbd153d21d9d3ca37f.

* Removing preemptive resetWindow() call

* general cleanup

* PR feedback

* property renames

* Reverting rename; requires Tools Service change first

* Adding header to updateProject

* Adding missing header

* PR feedback

* adding missing await

* Handing race condition for UI enable

* Fixing broken okay enable case

* Fixing enum comparison wonk

Co-authored-by: Noureldine Yehia <t-nyehia@microsoft.com>
2022-01-11 16:52:09 -08:00
Kim Santiago
4fa2b50077 load name and options from publish profile for vscode publish quickpick (#18044)
* load name and options from publihs profile for vscode publish quickpick

* fix when a publish profile doesn't have the target db name

* update condition

* simplify
2022-01-11 15:05:58 -08:00
Charles Gagnon
7940814e8d Add GenerateProjectFromOpenApiSpecOptions (#18045)
* wip

* Undo string change

* more changes
2022-01-11 11:57:21 -08:00
Kim Santiago
cd6b39ffee add a project guid if a sql project doesn't have one (#18009) 2022-01-07 16:01:39 -08:00
Charles Gagnon
2bc6a0cd01 VS Code merge to df8fe74bd55313de0dd2303bc47a4aab0ca56b0e (#17979)
* Merge from vscode 504f934659740e9d41501cad9f162b54d7745ad9

* delete unused folders

* distro

* Bump build node version

* update chokidar

* FIx hygiene errors

* distro

* Fix extension lint issues

* Remove strict-vscode

* Add copyright header exemptions

* Bump vscode-extension-telemetry to fix webpacking issue with zone.js

* distro

* Fix failing tests (revert marked.js back to current one until we decide to update)

* Skip searchmodel test

* Fix mac build

* temp debug script loading

* Try disabling coverage

* log error too

* Revert "log error too"

This reverts commit af0183e5d4ab458fdf44b88fbfab9908d090526f.

* Revert "temp debug script loading"

This reverts commit 3d687d541c76db2c5b55626c78ae448d3c25089c.

* Add comments explaining coverage disabling

* Fix ansi_up loading issue

* Merge latest from ads

* Use newer option

* Fix compile

* add debug logging warn

* Always log stack

* log more

* undo debug

* Update to use correct base path (+cleanup)

* distro

* fix compile errors

* Remove strict-vscode

* Fix sql editors not showing

* Show db dropdown input & fix styling

* Fix more info in gallery

* Fix gallery asset requests

* Delete unused workflow

* Fix tapable resolutions for smoke test compile error

* Fix smoke compile

* Disable crash reporting

* Disable interactive

Co-authored-by: ADS Merger <karlb@microsoft.com>
2022-01-06 09:06:56 -08:00
Kim Santiago
e11b1ed2a3 update sql projects test (#17987) 2022-01-05 10:03:24 -08:00