Skip to content
This repository was archived by the owner on May 7, 2024. It is now read-only.

Use SqlToolsService built on .NET Core 2.0 and a build script updates #131

Merged
merged 10 commits into from
Aug 17, 2017

Conversation

pensivebrian
Copy link
Member

@pensivebrian pensivebrian commented Aug 14, 2017

This pull updates the SqlToolsService to a version that uses .NET Core 2.0, which provides a number of benifits:

  1. Add ability to use Windows authentication when connecting to SQL Server from Mac/Linux
  2. One Linux platform distribution instead of a per distribution
  3. Enables us to support more Linux distros: Ubuntu 17 and Debian 9

To make consuming developer/nightly builds easier, also including a build.py script that can upload mssql-scripter pip packages to azure blob storage. To install a developer/nightly build, use the following command:

pip install --pre mssql-scripter --extra-index-url https://mssqlscripter.blob.core.windows.net/simple

To upgrade, use command

pip install --upgrade --pre mssql-scripter --extra-index-url https://mssqlscripter.blob.core.windows.net/simple

@msftclas
Copy link

@pensivebrian,
Thanks for your contribution as a Microsoft full-time employee or intern. You do not need to sign a CLA.
Thanks,
Microsoft Pull Request Bot

@MrMeemus
Copy link
Contributor

@pensivebrian, can you take a look at the build failures?

@pensivebrian
Copy link
Member Author

@MrMeemus - look like the cryptography package failed to install for Python 3.3 on Windows. This package doesn't seem to be supported on 3.3.
https://pypi.python.org/pypi/cryptography

It's being pulled in by the azure-storage package. To align with azure-cli, I think we should drop support for 3.3.


In reply to: 322294583 [](ancestors = 322294583)

@codecov-io
Copy link

codecov-io commented Aug 14, 2017

Codecov Report

Merging #131 into dev will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##              dev     #131   +/-   ##
=======================================
  Coverage   83.26%   83.26%           
=======================================
  Files          15       15           
  Lines        1046     1046           
=======================================
  Hits          871      871           
  Misses        175      175
Impacted Files Coverage Δ
mssqltoolsservice/mssqltoolsservice/__init__.py 100% <ø> (ø) ⬆️
...scripter/jsonrpc/contracts/tests/test_scripting.py 89.62% <ø> (ø) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update ca49239...f1c17ce. Read the comment docs.

@borgdylan
Copy link

borgdylan commented Aug 17, 2017

@pensivebrian I'd remove --no-cache from the install instructions. It makes pip choke with a red error message.

@pensivebrian
Copy link
Member Author

Updated. Thanks for the catch @borgdylan.

@pensivebrian pensivebrian merged commit 24a5dc8 into dev Aug 17, 2017
@pensivebrian pensivebrian deleted the feature/netcore20 branch August 17, 2017 20:27
MrMeemus added a commit that referenced this pull request Sep 1, 2017
* Use SqlToolsService built on .NET Core 2.0 and a build script updates (#131)

* Bump version to 1.0.0a19

* Use .NET Core 2.0 RTM built sqltoolsservice

* Add build script to upload to azure blob storage

* Upgrade to VS 2017

* Remove 3.3 as supported Python version

* Fix perf issue where main event loop takes 100% of CPU (#132)

Fix perf issue where main event loop takes 100% of CPU

We have a 2 threads:
Thread #1 runs in a loop polling the response queue
Thread #2 runs in a loop decoding responses from the sqltoolsservice over stdout and posting them to the response queue

Since thread #1 doesn't sleep, it's takes 100% CPU. In addition, running python 2.7 on windows, #2 doesn’t preempt the CPU due to #1 taking all of the CPU cycles, so no response is processed.

Fix is simple – thread #1 needs to sleep so thread #2 can get scheduled and get it’s work done.

* Refine event loop perf fix in main.py

Refine event loop perf fix in main.py

* Fixing regular expression

Previous regex would result in release:a1 and release_version: 12.
Modified the regex for part Release to only pick up lower case letters.

* Adding missing forward slash on test pypi url

* fixing typos/grammar (#138)

fixing typos/grammar.

* Updating to release version 1.0.0a20.
MrMeemus added a commit that referenced this pull request Oct 13, 2017
* Use SqlToolsService built on .NET Core 2.0 and a build script updates (#131)

* Bump version to 1.0.0a19

* Use .NET Core 2.0 RTM built sqltoolsservice

* Add build script to upload to azure blob storage

* Upgrade to VS 2017

* Remove 3.3 as supported Python version

* Fix perf issue where main event loop takes 100% of CPU (#132)

Fix perf issue where main event loop takes 100% of CPU

We have a 2 threads:
Thread #1 runs in a loop polling the response queue
Thread #2 runs in a loop decoding responses from the sqltoolsservice over stdout and posting them to the response queue

Since thread #1 doesn't sleep, it's takes 100% CPU. In addition, running python 2.7 on windows, #2 doesn’t preempt the CPU due to #1 taking all of the CPU cycles, so no response is processed.

Fix is simple – thread #1 needs to sleep so thread #2 can get scheduled and get it’s work done.

* Refine event loop perf fix in main.py

Refine event loop perf fix in main.py

* Fixing regular expression

Previous regex would result in release:a1 and release_version: 12.
Modified the regex for part Release to only pick up lower case letters.

* Adding missing forward slash on test pypi url

* fixing typos/grammar (#138)

fixing typos/grammar.

* Updating to release version 1.0.0a20.

* Create doc for official msft docs page

* Updated documentation page with usage_guide

* Added link to download adventureworks

* Updated with sqlcmd usage

* Added in run and cloud shell support

* Update/consolidate linux install (#153)

* universal linux wheel gen and setup update.

* Updating version cfg.

* Updating sqltoolsservice container.

* Updating spacing for flake8.

* Updating team email. (#154)
MrMeemus added a commit that referenced this pull request Nov 10, 2017
* Merge release 1.0.0a21 (#155)

* Use SqlToolsService built on .NET Core 2.0 and a build script updates (#131)

* Bump version to 1.0.0a19

* Use .NET Core 2.0 RTM built sqltoolsservice

* Add build script to upload to azure blob storage

* Upgrade to VS 2017

* Remove 3.3 as supported Python version

* Fix perf issue where main event loop takes 100% of CPU (#132)

Fix perf issue where main event loop takes 100% of CPU

We have a 2 threads:
Thread #1 runs in a loop polling the response queue
Thread #2 runs in a loop decoding responses from the sqltoolsservice over stdout and posting them to the response queue

Since thread #1 doesn't sleep, it's takes 100% CPU. In addition, running python 2.7 on windows, #2 doesn’t preempt the CPU due to #1 taking all of the CPU cycles, so no response is processed.

Fix is simple – thread #1 needs to sleep so thread #2 can get scheduled and get it’s work done.

* Refine event loop perf fix in main.py

Refine event loop perf fix in main.py

* Fixing regular expression

Previous regex would result in release:a1 and release_version: 12.
Modified the regex for part Release to only pick up lower case letters.

* Adding missing forward slash on test pypi url

* fixing typos/grammar (#138)

fixing typos/grammar.

* Updating to release version 1.0.0a20.

* Create doc for official msft docs page

* Updated documentation page with usage_guide

* Added link to download adventureworks

* Updated with sqlcmd usage

* Added in run and cloud shell support

* Update/consolidate linux install (#153)

* universal linux wheel gen and setup update.

* Updating version cfg.

* Updating sqltoolsservice container.

* Updating spacing for flake8.

* Updating team email. (#154)

* Updating mssqltoolsservice to be integrated as a package of mssqlscripter.

* Updating sqltoolsservice to be loaded from the repro instead of storage account.

* Fix index file generation for daily storage account.

* Fixing manylinux1 tag.

* Updating platform tag for win x64.

* Renaming sqltoolsservice win x64 folder.

* Adding platform tags for win_amd64, manylinux1_x86_64, manylinux1_i686.

* version bumping to 1.0.0a22.

* Flake8 format fixes.

* Erroring out when build receives invalid flag.
MrMeemus added a commit that referenced this pull request Nov 17, 2017
* Use SqlToolsService built on .NET Core 2.0 and a build script updates (#131)

* Bump version to 1.0.0a19

* Use .NET Core 2.0 RTM built sqltoolsservice

* Add build script to upload to azure blob storage

* Upgrade to VS 2017

* Remove 3.3 as supported Python version

* Fix perf issue where main event loop takes 100% of CPU (#132)

Fix perf issue where main event loop takes 100% of CPU

We have a 2 threads:
Thread #1 runs in a loop polling the response queue
Thread #2 runs in a loop decoding responses from the sqltoolsservice over stdout and posting them to the response queue

Since thread #1 doesn't sleep, it's takes 100% CPU. In addition, running python 2.7 on windows, #2 doesn’t preempt the CPU due to #1 taking all of the CPU cycles, so no response is processed.

Fix is simple – thread #1 needs to sleep so thread #2 can get scheduled and get it’s work done.

* Refine event loop perf fix in main.py

Refine event loop perf fix in main.py

* Fixing regular expression

Previous regex would result in release:a1 and release_version: 12.
Modified the regex for part Release to only pick up lower case letters.

* Adding missing forward slash on test pypi url

* fixing typos/grammar (#138)

fixing typos/grammar.

* Updating to release version 1.0.0a20.

* Create doc for official msft docs page

* Updated documentation page with usage_guide

* Added link to download adventureworks

* Updated with sqlcmd usage

* Added in run and cloud shell support

* Update/consolidate linux install (#153)

* universal linux wheel gen and setup update.

* Updating version cfg.

* Updating sqltoolsservice container.

* Updating spacing for flake8.

* Updating team email. (#154)

* Fixing resource warning for sqltoolsservice (#158)

* Fixing resource warning for sqltoolsservice by closing stdout after killing process.

* Shortening sleep time during shutdown.

* Fixing missing bracket.

* Updating doc's after repro rename (#160)

* Updating files after repro rename.

* Fixing flake8 issues.

* Ron/platform wheels support (#161)

* Merge release 1.0.0a21 (#155)

* Use SqlToolsService built on .NET Core 2.0 and a build script updates (#131)

* Bump version to 1.0.0a19

* Use .NET Core 2.0 RTM built sqltoolsservice

* Add build script to upload to azure blob storage

* Upgrade to VS 2017

* Remove 3.3 as supported Python version

* Fix perf issue where main event loop takes 100% of CPU (#132)

Fix perf issue where main event loop takes 100% of CPU

We have a 2 threads:
Thread #1 runs in a loop polling the response queue
Thread #2 runs in a loop decoding responses from the sqltoolsservice over stdout and posting them to the response queue

Since thread #1 doesn't sleep, it's takes 100% CPU. In addition, running python 2.7 on windows, #2 doesn’t preempt the CPU due to #1 taking all of the CPU cycles, so no response is processed.

Fix is simple – thread #1 needs to sleep so thread #2 can get scheduled and get it’s work done.

* Refine event loop perf fix in main.py

Refine event loop perf fix in main.py

* Fixing regular expression

Previous regex would result in release:a1 and release_version: 12.
Modified the regex for part Release to only pick up lower case letters.

* Adding missing forward slash on test pypi url

* fixing typos/grammar (#138)

fixing typos/grammar.

* Updating to release version 1.0.0a20.

* Create doc for official msft docs page

* Updated documentation page with usage_guide

* Added link to download adventureworks

* Updated with sqlcmd usage

* Added in run and cloud shell support

* Update/consolidate linux install (#153)

* universal linux wheel gen and setup update.

* Updating version cfg.

* Updating sqltoolsservice container.

* Updating spacing for flake8.

* Updating team email. (#154)

* Updating mssqltoolsservice to be integrated as a package of mssqlscripter.

* Updating sqltoolsservice to be loaded from the repro instead of storage account.

* Fix index file generation for daily storage account.

* Fixing manylinux1 tag.

* Updating platform tag for win x64.

* Renaming sqltoolsservice win x64 folder.

* Adding platform tags for win_amd64, manylinux1_x86_64, manylinux1_i686.

* version bumping to 1.0.0a22.

* Flake8 format fixes.

* Erroring out when build receives invalid flag.

* Fixing tag for win64

* Update libunwind8 install for CentOS

* Ron/sqltoolsservice update (#163)

* Updating sqltoolsservice with self contained version.

* Refreshing sqltoolsservice again.

* Making mssql-scripter executable and adding null checks in main.py

* Adding clean up step to remove build directory after each build.

* Fixing path for build directory.

* Removing 'pypi' from upload step.

* Flake 8 extra line fix.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants