From eecd40d4404be016ce61743383b94e6bde4f3923 Mon Sep 17 00:00:00 2001 From: Nate McMaster Date: Thu, 28 Jun 2018 16:48:52 -0700 Subject: [PATCH 01/27] Bumping version from 2.2.0 to 3.0.0 --- version.props | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/version.props b/version.props index 44985cedb3..71a78cddd8 100644 --- a/version.props +++ b/version.props @@ -1,7 +1,7 @@ - + - 2.2.0 - preview1 + 3.0.0 + alpha1 $(VersionPrefix) $(VersionPrefix)-$(VersionSuffix)-final t000 From dd04840cc0142fd0a325fd50abd85ecff859c624 Mon Sep 17 00:00:00 2001 From: "Nate McMaster (automated)" Date: Mon, 2 Jul 2018 12:40:23 -0700 Subject: [PATCH 02/27] [automated] Change default branch to master --- .appveyor.yml | 2 +- .travis.yml | 2 +- .vsts-pipelines/builds/ci-internal.yml | 4 ++-- .vsts-pipelines/builds/ci-public.yml | 6 +++--- korebuild.json | 4 ++-- run.ps1 | 6 +++--- run.sh | 2 +- 7 files changed, 13 insertions(+), 13 deletions(-) diff --git a/.appveyor.yml b/.appveyor.yml index 4eea96ab69..d45bd5a1f8 100644 --- a/.appveyor.yml +++ b/.appveyor.yml @@ -2,7 +2,7 @@ init: - git config --global core.autocrlf true branches: only: - - dev + - master - /^release\/.*$/ - /^(.*\/)?ci-.*$/ build_script: diff --git a/.travis.yml b/.travis.yml index 64bdbb4441..ab3980055c 100644 --- a/.travis.yml +++ b/.travis.yml @@ -16,7 +16,7 @@ addons: - libunwind8 branches: only: - - dev + - master - /^release\/.*$/ - /^(.*\/)?ci-.*$/ before_install: diff --git a/.vsts-pipelines/builds/ci-internal.yml b/.vsts-pipelines/builds/ci-internal.yml index d7ceb76378..c2c5336fd0 100644 --- a/.vsts-pipelines/builds/ci-internal.yml +++ b/.vsts-pipelines/builds/ci-internal.yml @@ -1,5 +1,5 @@ trigger: -- dev +- master - release/* resources: @@ -7,7 +7,7 @@ resources: - repository: buildtools type: git name: aspnet-BuildTools - ref: refs/heads/dev + ref: refs/heads/master phases: - template: .vsts-pipelines/templates/project-ci.yml@buildtools diff --git a/.vsts-pipelines/builds/ci-public.yml b/.vsts-pipelines/builds/ci-public.yml index b7f25723f8..507c89b025 100644 --- a/.vsts-pipelines/builds/ci-public.yml +++ b/.vsts-pipelines/builds/ci-public.yml @@ -1,5 +1,5 @@ trigger: -- dev +- master - release/* # See https://github.com/aspnet/BuildTools @@ -9,7 +9,7 @@ resources: type: github endpoint: DotNet-Bot GitHub Connection name: aspnet/BuildTools - ref: refs/heads/dev - + ref: refs/heads/master + phases: - template: .vsts-pipelines/templates/project-ci.yml@buildtools diff --git a/korebuild.json b/korebuild.json index bd5d51a51b..8a276a7f35 100644 --- a/korebuild.json +++ b/korebuild.json @@ -1,4 +1,4 @@ { - "$schema": "https://raw.githubusercontent.com/aspnet/BuildTools/dev/tools/korebuild.schema.json", - "channel": "dev" + "$schema": "https://raw.githubusercontent.com/aspnet/BuildTools/master/tools/korebuild.schema.json", + "channel": "master" } diff --git a/run.ps1 b/run.ps1 index 3b27382468..34604c7175 100644 --- a/run.ps1 +++ b/run.ps1 @@ -52,8 +52,8 @@ in the file are overridden by command line parameters. Example config file: ```json { - "$schema": "https://raw.githubusercontent.com/aspnet/BuildTools/dev/tools/korebuild.schema.json", - "channel": "dev", + "$schema": "https://raw.githubusercontent.com/aspnet/BuildTools/master/tools/korebuild.schema.json", + "channel": "master", "toolsSource": "https://aspnetcore.blob.core.windows.net/buildtools" } ``` @@ -192,7 +192,7 @@ if (!$DotNetHome) { else { Join-Path $PSScriptRoot '.dotnet'} } -if (!$Channel) { $Channel = 'dev' } +if (!$Channel) { $Channel = 'master' } if (!$ToolsSource) { $ToolsSource = 'https://aspnetcore.blob.core.windows.net/buildtools' } # Execute diff --git a/run.sh b/run.sh index 02aac15874..61f7a53385 100755 --- a/run.sh +++ b/run.sh @@ -248,7 +248,7 @@ if [ -f "$config_file" ]; then [ ! -z "${config_tools_source:-}" ] && tools_source="$config_tools_source" fi -[ -z "$channel" ] && channel='dev' +[ -z "$channel" ] && channel='master' [ -z "$tools_source" ] && tools_source='https://aspnetcore.blob.core.windows.net/buildtools' get_korebuild From 7f14fd15e32d7bbdc74485264cba56dbc6790395 Mon Sep 17 00:00:00 2001 From: "ASP.NET CI" Date: Tue, 3 Jul 2018 16:13:52 +0000 Subject: [PATCH 03/27] Update dependencies.props [auto-updated: dependencies] --- build/dependencies.props | 12 ++++++------ korebuild-lock.txt | 4 ++-- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/build/dependencies.props b/build/dependencies.props index d77dee67ef..992dc7dbc3 100644 --- a/build/dependencies.props +++ b/build/dependencies.props @@ -3,15 +3,15 @@ $(MSBuildAllProjects);$(MSBuildThisFileFullPath) - 2.2.0-preview1-17090 - 2.2.0-preview1-34530 - 2.2.0-preview1-34530 - 2.2.0-preview1-34530 - 2.2.0-preview1-34530 + 3.0.0-alpha1-10000 + 3.0.0-alpha1-10016 + 3.0.0-alpha1-10016 + 3.0.0-alpha1-10016 + 3.0.0-alpha1-10016 2.0.0 2.1.0 2.2.0-preview1-26618-02 - 2.2.0-preview1-34530 + 3.0.0-alpha1-10016 15.6.1 4.6.0-preview1-26617-01 2.0.3 diff --git a/korebuild-lock.txt b/korebuild-lock.txt index a8109db529..f0b76184fd 100644 --- a/korebuild-lock.txt +++ b/korebuild-lock.txt @@ -1,2 +1,2 @@ -version:2.2.0-preview1-17090 -commithash:b19e903e946579cd9482089bce7d917e8bacd765 +version:3.0.0-alpha1-10000 +commithash:b7b88d08d55abc8b71de9abf16e26fc713e332cd From 91c518e13d7ede44e6cb88df895d9a242b07726e Mon Sep 17 00:00:00 2001 From: "ASP.NET CI" Date: Sun, 8 Jul 2018 19:55:22 +0000 Subject: [PATCH 04/27] Update dependencies.props [auto-updated: dependencies] --- build/dependencies.props | 14 +++++++------- korebuild-lock.txt | 4 ++-- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/build/dependencies.props b/build/dependencies.props index 992dc7dbc3..42cd0422ff 100644 --- a/build/dependencies.props +++ b/build/dependencies.props @@ -3,22 +3,22 @@ $(MSBuildAllProjects);$(MSBuildThisFileFullPath) - 3.0.0-alpha1-10000 - 3.0.0-alpha1-10016 - 3.0.0-alpha1-10016 - 3.0.0-alpha1-10016 - 3.0.0-alpha1-10016 + 3.0.0-alpha1-10005 + 3.0.0-alpha1-10044 + 3.0.0-alpha1-10044 + 3.0.0-alpha1-10044 + 3.0.0-alpha1-10044 2.0.0 2.1.0 2.2.0-preview1-26618-02 - 3.0.0-alpha1-10016 + 3.0.0-alpha1-10044 15.6.1 4.6.0-preview1-26617-01 2.0.3 4.6.0-preview1-26617-01 4.6.0-preview1-26617-01 2.3.1 - 2.4.0-beta.1.build3945 + 2.4.0-rc.1.build4038 diff --git a/korebuild-lock.txt b/korebuild-lock.txt index f0b76184fd..f357ac9f7d 100644 --- a/korebuild-lock.txt +++ b/korebuild-lock.txt @@ -1,2 +1,2 @@ -version:3.0.0-alpha1-10000 -commithash:b7b88d08d55abc8b71de9abf16e26fc713e332cd +version:3.0.0-alpha1-10005 +commithash:05570853de976a526462ca140a55b1ac59d9a351 From ccee25654ffe791c7d212e209c202e018feabc83 Mon Sep 17 00:00:00 2001 From: "ASP.NET CI" Date: Sun, 15 Jul 2018 19:58:44 +0000 Subject: [PATCH 05/27] Update dependencies.props [auto-updated: dependencies] --- build/dependencies.props | 22 +++++++++++----------- korebuild-lock.txt | 4 ++-- 2 files changed, 13 insertions(+), 13 deletions(-) diff --git a/build/dependencies.props b/build/dependencies.props index 42cd0422ff..baecc9a476 100644 --- a/build/dependencies.props +++ b/build/dependencies.props @@ -3,20 +3,20 @@ $(MSBuildAllProjects);$(MSBuildThisFileFullPath) - 3.0.0-alpha1-10005 - 3.0.0-alpha1-10044 - 3.0.0-alpha1-10044 - 3.0.0-alpha1-10044 - 3.0.0-alpha1-10044 - 2.0.0 - 2.1.0 + 3.0.0-alpha1-10009 + 3.0.0-alpha1-10081 + 3.0.0-alpha1-10081 + 3.0.0-alpha1-10081 + 3.0.0-alpha1-10081 + 2.0.9 + 2.1.2 2.2.0-preview1-26618-02 - 3.0.0-alpha1-10044 + 3.0.0-alpha1-10081 15.6.1 - 4.6.0-preview1-26617-01 + 4.6.0-preview1-26708-04 2.0.3 - 4.6.0-preview1-26617-01 - 4.6.0-preview1-26617-01 + 4.6.0-preview1-26708-04 + 4.6.0-preview1-26708-04 2.3.1 2.4.0-rc.1.build4038 diff --git a/korebuild-lock.txt b/korebuild-lock.txt index f357ac9f7d..4db537685b 100644 --- a/korebuild-lock.txt +++ b/korebuild-lock.txt @@ -1,2 +1,2 @@ -version:3.0.0-alpha1-10005 -commithash:05570853de976a526462ca140a55b1ac59d9a351 +version:3.0.0-alpha1-10009 +commithash:86be4707e47d2f1930a982f2b59eacfc4196da33 From 13329bfb7f89f91cfbd4e288a5234c000ba4ac7d Mon Sep 17 00:00:00 2001 From: "ASP.NET CI" Date: Sun, 22 Jul 2018 12:59:44 -0700 Subject: [PATCH 06/27] Update dependencies.props [auto-updated: dependencies] --- build/dependencies.props | 12 ++++++------ korebuild-lock.txt | 4 ++-- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/build/dependencies.props b/build/dependencies.props index baecc9a476..49f9dd2a0b 100644 --- a/build/dependencies.props +++ b/build/dependencies.props @@ -3,15 +3,15 @@ $(MSBuildAllProjects);$(MSBuildThisFileFullPath) - 3.0.0-alpha1-10009 - 3.0.0-alpha1-10081 - 3.0.0-alpha1-10081 - 3.0.0-alpha1-10081 - 3.0.0-alpha1-10081 + 3.0.0-alpha1-10011 + 3.0.0-alpha1-10123 + 3.0.0-alpha1-10123 + 3.0.0-alpha1-10123 + 3.0.0-alpha1-10123 2.0.9 2.1.2 2.2.0-preview1-26618-02 - 3.0.0-alpha1-10081 + 3.0.0-alpha1-10123 15.6.1 4.6.0-preview1-26708-04 2.0.3 diff --git a/korebuild-lock.txt b/korebuild-lock.txt index 4db537685b..9a67ee9c28 100644 --- a/korebuild-lock.txt +++ b/korebuild-lock.txt @@ -1,2 +1,2 @@ -version:3.0.0-alpha1-10009 -commithash:86be4707e47d2f1930a982f2b59eacfc4196da33 +version:3.0.0-alpha1-10011 +commithash:717c2eb1f91dafd2580c1a9b8e5064d12dd8c054 From 52551b27bd9591b9363a5d25f384bb3f14660c8d Mon Sep 17 00:00:00 2001 From: Eilon Lipton Date: Tue, 24 Jul 2018 10:51:12 -0700 Subject: [PATCH 07/27] Update CONTRIBUTING.md --- CONTRIBUTING.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 64ff041d5c..eac4268e4c 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -1,4 +1,4 @@ Contributing ====== -Information on contributing to this repo is in the [Contributing Guide](https://github.com/aspnet/Home/blob/dev/CONTRIBUTING.md) in the Home repo. +Information on contributing to this repo is in the [Contributing Guide](https://github.com/aspnet/Home/blob/master/CONTRIBUTING.md) in the Home repo. From 6603313a1a380d677fe2d5e7650f4dea0f5083b1 Mon Sep 17 00:00:00 2001 From: "ASP.NET CI" Date: Sun, 29 Jul 2018 19:57:26 +0000 Subject: [PATCH 08/27] Update dependencies.props [auto-updated: dependencies] --- build/dependencies.props | 21 +++++++++++---------- korebuild-lock.txt | 4 ++-- 2 files changed, 13 insertions(+), 12 deletions(-) diff --git a/build/dependencies.props b/build/dependencies.props index 49f9dd2a0b..6df783d5af 100644 --- a/build/dependencies.props +++ b/build/dependencies.props @@ -3,22 +3,23 @@ $(MSBuildAllProjects);$(MSBuildThisFileFullPath) - 3.0.0-alpha1-10011 - 3.0.0-alpha1-10123 - 3.0.0-alpha1-10123 - 3.0.0-alpha1-10123 - 3.0.0-alpha1-10123 + 3.0.0-alpha1-10015 + 3.0.0-alpha1-10173 + 3.0.0-alpha1-10173 + 3.0.0-alpha1-10173 + 3.0.0-alpha1-10173 2.0.9 2.1.2 2.2.0-preview1-26618-02 - 3.0.0-alpha1-10123 + 3.0.0-alpha1-10173 15.6.1 - 4.6.0-preview1-26708-04 + 4.6.0-preview1-26727-04 2.0.3 - 4.6.0-preview1-26708-04 - 4.6.0-preview1-26708-04 + 4.6.0-preview1-26727-04 + 4.6.0-preview1-26727-04 2.3.1 - 2.4.0-rc.1.build4038 + 2.4.0 + diff --git a/korebuild-lock.txt b/korebuild-lock.txt index 9a67ee9c28..1e75dc3a23 100644 --- a/korebuild-lock.txt +++ b/korebuild-lock.txt @@ -1,2 +1,2 @@ -version:3.0.0-alpha1-10011 -commithash:717c2eb1f91dafd2580c1a9b8e5064d12dd8c054 +version:3.0.0-alpha1-10015 +commithash:3f36e5c2f061712f76f2766c435d2555681d5c55 From 87d2a7733a93d7470d895647349783131f5f3548 Mon Sep 17 00:00:00 2001 From: "ASP.NET CI" Date: Sun, 5 Aug 2018 19:54:04 +0000 Subject: [PATCH 09/27] Update dependencies.props [auto-updated: dependencies] --- build/dependencies.props | 12 ++++++------ korebuild-lock.txt | 4 ++-- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/build/dependencies.props b/build/dependencies.props index 6df783d5af..dd5d8bb82e 100644 --- a/build/dependencies.props +++ b/build/dependencies.props @@ -3,15 +3,15 @@ $(MSBuildAllProjects);$(MSBuildThisFileFullPath) - 3.0.0-alpha1-10015 - 3.0.0-alpha1-10173 - 3.0.0-alpha1-10173 - 3.0.0-alpha1-10173 - 3.0.0-alpha1-10173 + 3.0.0-alpha1-20180731.2 + 3.0.0-alpha1-10221 + 3.0.0-alpha1-10221 + 3.0.0-alpha1-10221 + 3.0.0-alpha1-10221 2.0.9 2.1.2 2.2.0-preview1-26618-02 - 3.0.0-alpha1-10173 + 3.0.0-alpha1-10221 15.6.1 4.6.0-preview1-26727-04 2.0.3 diff --git a/korebuild-lock.txt b/korebuild-lock.txt index 1e75dc3a23..8f9f6066ef 100644 --- a/korebuild-lock.txt +++ b/korebuild-lock.txt @@ -1,2 +1,2 @@ -version:3.0.0-alpha1-10015 -commithash:3f36e5c2f061712f76f2766c435d2555681d5c55 +version:3.0.0-alpha1-20180731.2 +commithash:1179f1083695ac9213c8a70a4d1d6c45a52caf41 From 7e2debe46b65f37f2ad9dc5e4d91bf1f9de846d2 Mon Sep 17 00:00:00 2001 From: "ASP.NET CI" Date: Sun, 12 Aug 2018 20:01:10 +0000 Subject: [PATCH 10/27] Update dependencies.props [auto-updated: dependencies] --- build/dependencies.props | 18 +++++++++--------- korebuild-lock.txt | 4 ++-- 2 files changed, 11 insertions(+), 11 deletions(-) diff --git a/build/dependencies.props b/build/dependencies.props index dd5d8bb82e..c4b24e59fe 100644 --- a/build/dependencies.props +++ b/build/dependencies.props @@ -3,20 +3,20 @@ $(MSBuildAllProjects);$(MSBuildThisFileFullPath) - 3.0.0-alpha1-20180731.2 - 3.0.0-alpha1-10221 - 3.0.0-alpha1-10221 - 3.0.0-alpha1-10221 - 3.0.0-alpha1-10221 + 3.0.0-alpha1-20180810.1 + 3.0.0-alpha1-10275 + 3.0.0-alpha1-10275 + 3.0.0-alpha1-10275 + 3.0.0-alpha1-10275 2.0.9 2.1.2 2.2.0-preview1-26618-02 - 3.0.0-alpha1-10221 + 3.0.0-alpha1-10275 15.6.1 - 4.6.0-preview1-26727-04 + 4.6.0-preview1-26807-04 2.0.3 - 4.6.0-preview1-26727-04 - 4.6.0-preview1-26727-04 + 4.6.0-preview1-26807-04 + 4.6.0-preview1-26807-04 2.3.1 2.4.0 diff --git a/korebuild-lock.txt b/korebuild-lock.txt index 8f9f6066ef..e417a01b52 100644 --- a/korebuild-lock.txt +++ b/korebuild-lock.txt @@ -1,2 +1,2 @@ -version:3.0.0-alpha1-20180731.2 -commithash:1179f1083695ac9213c8a70a4d1d6c45a52caf41 +version:3.0.0-alpha1-20180810.1 +commithash:45c32b4f020e14a9295be31866051a18d293309d From ebf60fba57cf7a5036abb2c04f4a19d1a3ceaeea Mon Sep 17 00:00:00 2001 From: "ASP.NET CI" Date: Sun, 19 Aug 2018 19:15:40 +0000 Subject: [PATCH 11/27] Update dependencies.props [auto-updated: dependencies] --- build/dependencies.props | 18 +++++++++--------- korebuild-lock.txt | 4 ++-- 2 files changed, 11 insertions(+), 11 deletions(-) diff --git a/build/dependencies.props b/build/dependencies.props index c4b24e59fe..859c7a548c 100644 --- a/build/dependencies.props +++ b/build/dependencies.props @@ -3,20 +3,20 @@ $(MSBuildAllProjects);$(MSBuildThisFileFullPath) - 3.0.0-alpha1-20180810.1 - 3.0.0-alpha1-10275 - 3.0.0-alpha1-10275 - 3.0.0-alpha1-10275 - 3.0.0-alpha1-10275 + 3.0.0-alpha1-20180817.3 + 3.0.0-alpha1-10321 + 3.0.0-alpha1-10321 + 3.0.0-alpha1-10321 + 3.0.0-alpha1-10321 2.0.9 2.1.2 2.2.0-preview1-26618-02 - 3.0.0-alpha1-10275 + 3.0.0-alpha1-10321 15.6.1 - 4.6.0-preview1-26807-04 + 4.6.0-preview1-26816-01 2.0.3 - 4.6.0-preview1-26807-04 - 4.6.0-preview1-26807-04 + 4.6.0-preview1-26816-01 + 4.6.0-preview1-26816-01 2.3.1 2.4.0 diff --git a/korebuild-lock.txt b/korebuild-lock.txt index e417a01b52..e5330b3d33 100644 --- a/korebuild-lock.txt +++ b/korebuild-lock.txt @@ -1,2 +1,2 @@ -version:3.0.0-alpha1-20180810.1 -commithash:45c32b4f020e14a9295be31866051a18d293309d +version:3.0.0-alpha1-20180817.3 +commithash:134cdbee9bee29dd3ccb654c67663b27b9ffa6c8 From 9587c58140c4f52e616fc89b1c2ada50ed6f0e45 Mon Sep 17 00:00:00 2001 From: "ASP.NET CI" Date: Sun, 26 Aug 2018 19:15:08 +0000 Subject: [PATCH 12/27] Update dependencies.props [auto-updated: dependencies] --- build/dependencies.props | 18 +++++++++--------- korebuild-lock.txt | 4 ++-- 2 files changed, 11 insertions(+), 11 deletions(-) diff --git a/build/dependencies.props b/build/dependencies.props index 859c7a548c..1d555d5fd0 100644 --- a/build/dependencies.props +++ b/build/dependencies.props @@ -3,20 +3,20 @@ $(MSBuildAllProjects);$(MSBuildThisFileFullPath) - 3.0.0-alpha1-20180817.3 - 3.0.0-alpha1-10321 - 3.0.0-alpha1-10321 - 3.0.0-alpha1-10321 - 3.0.0-alpha1-10321 + 3.0.0-alpha1-20180821.3 + 3.0.0-alpha1-10352 + 3.0.0-alpha1-10352 + 3.0.0-alpha1-10352 + 3.0.0-alpha1-10352 2.0.9 2.1.2 2.2.0-preview1-26618-02 - 3.0.0-alpha1-10321 + 3.0.0-alpha1-10352 15.6.1 - 4.6.0-preview1-26816-01 + 4.6.0-preview1-26817-04 2.0.3 - 4.6.0-preview1-26816-01 - 4.6.0-preview1-26816-01 + 4.6.0-preview1-26817-04 + 4.6.0-preview1-26817-04 2.3.1 2.4.0 diff --git a/korebuild-lock.txt b/korebuild-lock.txt index e5330b3d33..767a471795 100644 --- a/korebuild-lock.txt +++ b/korebuild-lock.txt @@ -1,2 +1,2 @@ -version:3.0.0-alpha1-20180817.3 -commithash:134cdbee9bee29dd3ccb654c67663b27b9ffa6c8 +version:3.0.0-alpha1-20180821.3 +commithash:0939a90812deb1c604eb9a4768869687495fc1dd From 9cb675fec89702d28b5f188e0ab4f7d671d7aa11 Mon Sep 17 00:00:00 2001 From: "ASP.NET CI" Date: Sun, 2 Sep 2018 19:15:11 +0000 Subject: [PATCH 13/27] Update dependencies.props [auto-updated: dependencies] --- build/dependencies.props | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/build/dependencies.props b/build/dependencies.props index 1d555d5fd0..b2e6e78e12 100644 --- a/build/dependencies.props +++ b/build/dependencies.props @@ -4,19 +4,19 @@ 3.0.0-alpha1-20180821.3 - 3.0.0-alpha1-10352 - 3.0.0-alpha1-10352 - 3.0.0-alpha1-10352 - 3.0.0-alpha1-10352 + 3.0.0-alpha1-10393 + 3.0.0-alpha1-10393 + 3.0.0-alpha1-10393 + 3.0.0-alpha1-10393 2.0.9 2.1.2 2.2.0-preview1-26618-02 - 3.0.0-alpha1-10352 + 3.0.0-alpha1-10393 15.6.1 - 4.6.0-preview1-26817-04 + 4.6.0-preview1-26829-04 2.0.3 - 4.6.0-preview1-26817-04 - 4.6.0-preview1-26817-04 + 4.6.0-preview1-26829-04 + 4.6.0-preview1-26829-04 2.3.1 2.4.0 From 6529a5614b2ab1a78b98685b89f324450bc5b080 Mon Sep 17 00:00:00 2001 From: "ASP.NET CI" Date: Wed, 5 Sep 2018 23:47:18 +0000 Subject: [PATCH 14/27] Update dependencies.props [auto-updated: dependencies] --- build/dependencies.props | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/build/dependencies.props b/build/dependencies.props index b2e6e78e12..f5c1ccaf1b 100644 --- a/build/dependencies.props +++ b/build/dependencies.props @@ -4,19 +4,19 @@ 3.0.0-alpha1-20180821.3 - 3.0.0-alpha1-10393 - 3.0.0-alpha1-10393 - 3.0.0-alpha1-10393 - 3.0.0-alpha1-10393 + 3.0.0-alpha1-10400 + 3.0.0-alpha1-10400 + 3.0.0-alpha1-10400 + 3.0.0-alpha1-10400 2.0.9 - 2.1.2 - 2.2.0-preview1-26618-02 - 3.0.0-alpha1-10393 + 2.1.3 + 2.2.0-preview2-26905-02 + 3.0.0-alpha1-10400 15.6.1 - 4.6.0-preview1-26829-04 + 4.6.0-preview1-26831-06 2.0.3 - 4.6.0-preview1-26829-04 - 4.6.0-preview1-26829-04 + 4.6.0-preview1-26831-06 + 4.6.0-preview1-26831-06 2.3.1 2.4.0 From e9c0d285b577cafe0e5374369874e6ba756f1676 Mon Sep 17 00:00:00 2001 From: "ASP.NET CI" Date: Sun, 9 Sep 2018 19:15:52 +0000 Subject: [PATCH 15/27] Update dependencies.props [auto-updated: dependencies] --- build/dependencies.props | 18 +++++++++--------- korebuild-lock.txt | 4 ++-- 2 files changed, 11 insertions(+), 11 deletions(-) diff --git a/build/dependencies.props b/build/dependencies.props index 583baab26a..a935597137 100644 --- a/build/dependencies.props +++ b/build/dependencies.props @@ -3,20 +3,20 @@ $(MSBuildAllProjects);$(MSBuildThisFileFullPath) - 3.0.0-alpha1-20180821.3 - 3.0.0-alpha1-10400 - 3.0.0-alpha1-10400 - 3.0.0-alpha1-10400 - 3.0.0-alpha1-10400 + 3.0.0-alpha1-20180907.9 + 3.0.0-alpha1-10419 + 3.0.0-alpha1-10419 + 3.0.0-alpha1-10419 + 3.0.0-alpha1-10419 2.0.9 2.1.3 2.2.0-preview2-26905-02 - 3.0.0-alpha1-10400 + 3.0.0-alpha1-10419 15.6.1 - 4.6.0-preview1-26831-06 + 4.6.0-preview1-26905-03 2.0.3 - 4.6.0-preview1-26831-06 - 4.6.0-preview1-26831-06 + 4.6.0-preview1-26905-03 + 4.6.0-preview1-26905-03 2.3.1 2.4.0 diff --git a/korebuild-lock.txt b/korebuild-lock.txt index 767a471795..b614cab6e8 100644 --- a/korebuild-lock.txt +++ b/korebuild-lock.txt @@ -1,2 +1,2 @@ -version:3.0.0-alpha1-20180821.3 -commithash:0939a90812deb1c604eb9a4768869687495fc1dd +version:3.0.0-alpha1-20180907.9 +commithash:f997365a8832ff0a3cbd9a98df45734ac2723fa0 From 0de5698b05880af2783ee28b17fd9214753aca78 Mon Sep 17 00:00:00 2001 From: "ASP.NET CI" Date: Sun, 16 Sep 2018 19:14:54 +0000 Subject: [PATCH 16/27] Update dependencies.props [auto-updated: dependencies] --- build/dependencies.props | 18 +++++++++--------- korebuild-lock.txt | 4 ++-- 2 files changed, 11 insertions(+), 11 deletions(-) diff --git a/build/dependencies.props b/build/dependencies.props index a935597137..6eef2d319d 100644 --- a/build/dependencies.props +++ b/build/dependencies.props @@ -3,20 +3,20 @@ $(MSBuildAllProjects);$(MSBuildThisFileFullPath) - 3.0.0-alpha1-20180907.9 - 3.0.0-alpha1-10419 - 3.0.0-alpha1-10419 - 3.0.0-alpha1-10419 - 3.0.0-alpha1-10419 + 3.0.0-alpha1-20180911.2 + 3.0.0-alpha1-10454 + 3.0.0-alpha1-10454 + 3.0.0-alpha1-10454 + 3.0.0-alpha1-10454 2.0.9 2.1.3 2.2.0-preview2-26905-02 - 3.0.0-alpha1-10419 + 3.0.0-alpha1-10454 15.6.1 - 4.6.0-preview1-26905-03 + 4.6.0-preview1-26907-04 2.0.3 - 4.6.0-preview1-26905-03 - 4.6.0-preview1-26905-03 + 4.6.0-preview1-26907-04 + 4.6.0-preview1-26907-04 2.3.1 2.4.0 diff --git a/korebuild-lock.txt b/korebuild-lock.txt index b614cab6e8..a817c10d28 100644 --- a/korebuild-lock.txt +++ b/korebuild-lock.txt @@ -1,2 +1,2 @@ -version:3.0.0-alpha1-20180907.9 -commithash:f997365a8832ff0a3cbd9a98df45734ac2723fa0 +version:3.0.0-alpha1-20180911.2 +commithash:2a2b7dbea1b247930c41da497f4ea0b2bb756818 From ff9a93f160f7859ebff304c13b7ead86e1ce0ee5 Mon Sep 17 00:00:00 2001 From: "ASP.NET CI" Date: Sun, 23 Sep 2018 12:14:15 -0700 Subject: [PATCH 17/27] Update dependencies.props [auto-updated: dependencies] --- build/dependencies.props | 12 ++++++------ korebuild-lock.txt | 4 ++-- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/build/dependencies.props b/build/dependencies.props index 6eef2d319d..89286333c5 100644 --- a/build/dependencies.props +++ b/build/dependencies.props @@ -3,15 +3,15 @@ $(MSBuildAllProjects);$(MSBuildThisFileFullPath) - 3.0.0-alpha1-20180911.2 - 3.0.0-alpha1-10454 - 3.0.0-alpha1-10454 - 3.0.0-alpha1-10454 - 3.0.0-alpha1-10454 + 3.0.0-alpha1-20180919.1 + 3.0.0-alpha1-10495 + 3.0.0-alpha1-10495 + 3.0.0-alpha1-10495 + 3.0.0-alpha1-10495 2.0.9 2.1.3 2.2.0-preview2-26905-02 - 3.0.0-alpha1-10454 + 3.0.0-alpha1-10495 15.6.1 4.6.0-preview1-26907-04 2.0.3 diff --git a/korebuild-lock.txt b/korebuild-lock.txt index a817c10d28..d66a13bdc7 100644 --- a/korebuild-lock.txt +++ b/korebuild-lock.txt @@ -1,2 +1,2 @@ -version:3.0.0-alpha1-20180911.2 -commithash:2a2b7dbea1b247930c41da497f4ea0b2bb756818 +version:3.0.0-alpha1-20180919.1 +commithash:3066ae0a230870ea07e3f132605b5e5493f8bbd4 From ffa368cdcbd1742abc69bb1cab9bc5ce78a881aa Mon Sep 17 00:00:00 2001 From: Eilon Lipton Date: Thu, 27 Sep 2018 15:32:38 -0700 Subject: [PATCH 18/27] Update LICENSE.txt --- LICENSE.txt | 207 +++++++++++++++++++++++++++++++++++++++++++++++++--- 1 file changed, 197 insertions(+), 10 deletions(-) diff --git a/LICENSE.txt b/LICENSE.txt index 7b2956ecee..b3b180cd51 100644 --- a/LICENSE.txt +++ b/LICENSE.txt @@ -1,14 +1,201 @@ -Copyright (c) .NET Foundation and Contributors + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ -All rights reserved. + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION -Licensed under the Apache License, Version 2.0 (the "License"); you may not use -this file except in compliance with the License. You may obtain a copy of the -License at + 1. Definitions. - http://www.apache.org/licenses/LICENSE-2.0 + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. -Unless required by applicable law or agreed to in writing, software distributed -under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR -CONDITIONS OF ANY KIND, either express or implied. See the License for the -specific language governing permissions and limitations under the License. + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "[]" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + + Copyright (c) .NET Foundation and Contributors + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. From 21fe13b44689a8418a2069be4d7e54f7a73d798b Mon Sep 17 00:00:00 2001 From: "ASP.NET CI" Date: Sun, 30 Sep 2018 12:14:54 -0700 Subject: [PATCH 19/27] Update dependencies.props [auto-updated: dependencies] --- build/dependencies.props | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/build/dependencies.props b/build/dependencies.props index 89286333c5..08f8ca472f 100644 --- a/build/dependencies.props +++ b/build/dependencies.props @@ -4,14 +4,14 @@ 3.0.0-alpha1-20180919.1 - 3.0.0-alpha1-10495 - 3.0.0-alpha1-10495 - 3.0.0-alpha1-10495 - 3.0.0-alpha1-10495 + 3.0.0-alpha1-10549 + 3.0.0-alpha1-10549 + 3.0.0-alpha1-10549 + 3.0.0-alpha1-10549 2.0.9 2.1.3 2.2.0-preview2-26905-02 - 3.0.0-alpha1-10495 + 3.0.0-alpha1-10549 15.6.1 4.6.0-preview1-26907-04 2.0.3 From 76cb2784b90b5549427700d4d93e44803c49101c Mon Sep 17 00:00:00 2001 From: "ASP.NET CI" Date: Sun, 7 Oct 2018 12:15:24 -0700 Subject: [PATCH 20/27] Update dependencies.props [auto-updated: dependencies] --- build/dependencies.props | 12 ++++++------ korebuild-lock.txt | 4 ++-- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/build/dependencies.props b/build/dependencies.props index 08f8ca472f..26a4444734 100644 --- a/build/dependencies.props +++ b/build/dependencies.props @@ -3,15 +3,15 @@ $(MSBuildAllProjects);$(MSBuildThisFileFullPath) - 3.0.0-alpha1-20180919.1 - 3.0.0-alpha1-10549 - 3.0.0-alpha1-10549 - 3.0.0-alpha1-10549 - 3.0.0-alpha1-10549 + 3.0.0-alpha1-20181004.7 + 3.0.0-alpha1-10584 + 3.0.0-alpha1-10584 + 3.0.0-alpha1-10584 + 3.0.0-alpha1-10584 2.0.9 2.1.3 2.2.0-preview2-26905-02 - 3.0.0-alpha1-10549 + 3.0.0-alpha1-10584 15.6.1 4.6.0-preview1-26907-04 2.0.3 diff --git a/korebuild-lock.txt b/korebuild-lock.txt index d66a13bdc7..591cfd52ff 100644 --- a/korebuild-lock.txt +++ b/korebuild-lock.txt @@ -1,2 +1,2 @@ -version:3.0.0-alpha1-20180919.1 -commithash:3066ae0a230870ea07e3f132605b5e5493f8bbd4 +version:3.0.0-alpha1-20181004.7 +commithash:27fabdaf2b1d4753c3d2749581694ca65d78f7f2 From c1fdd4cdc930afa693507d20aecde320d5a3e682 Mon Sep 17 00:00:00 2001 From: "ASP.NET CI" Date: Thu, 11 Oct 2018 12:11:56 -0700 Subject: [PATCH 21/27] Update dependencies.props [auto-updated: dependencies] --- build/dependencies.props | 12 ++++++------ korebuild-lock.txt | 4 ++-- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/build/dependencies.props b/build/dependencies.props index 26a4444734..ed5efb8949 100644 --- a/build/dependencies.props +++ b/build/dependencies.props @@ -3,15 +3,15 @@ $(MSBuildAllProjects);$(MSBuildThisFileFullPath) - 3.0.0-alpha1-20181004.7 - 3.0.0-alpha1-10584 - 3.0.0-alpha1-10584 - 3.0.0-alpha1-10584 - 3.0.0-alpha1-10584 + 3.0.0-alpha1-20181011.3 + 3.0.0-alpha1-10605 + 3.0.0-alpha1-10605 + 3.0.0-alpha1-10605 + 3.0.0-alpha1-10605 2.0.9 2.1.3 2.2.0-preview2-26905-02 - 3.0.0-alpha1-10584 + 3.0.0-alpha1-10605 15.6.1 4.6.0-preview1-26907-04 2.0.3 diff --git a/korebuild-lock.txt b/korebuild-lock.txt index 591cfd52ff..f7d4e37b32 100644 --- a/korebuild-lock.txt +++ b/korebuild-lock.txt @@ -1,2 +1,2 @@ -version:3.0.0-alpha1-20181004.7 -commithash:27fabdaf2b1d4753c3d2749581694ca65d78f7f2 +version:3.0.0-alpha1-20181011.3 +commithash:e7569d931e994629267ab2646e9926140962b4ac From 7ef22b12e4d2db5205c82691eb11c21895b04d63 Mon Sep 17 00:00:00 2001 From: "Chris Ross (ASP.NET)" Date: Mon, 22 Oct 2018 12:21:47 -0700 Subject: [PATCH 22/27] Update dependencies.props --- build/dependencies.props | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/build/dependencies.props b/build/dependencies.props index ed5efb8949..8666e2bfc5 100644 --- a/build/dependencies.props +++ b/build/dependencies.props @@ -4,14 +4,14 @@ 3.0.0-alpha1-20181011.3 - 3.0.0-alpha1-10605 - 3.0.0-alpha1-10605 - 3.0.0-alpha1-10605 - 3.0.0-alpha1-10605 + 3.0.0-alpha1-10653 + 3.0.0-alpha1-10653 + 3.0.0-alpha1-10653 + 3.0.0-alpha1-10653 2.0.9 2.1.3 - 2.2.0-preview2-26905-02 - 3.0.0-alpha1-10605 + 2.2.0-preview3-27014-02 + 3.0.0-alpha1-10653 15.6.1 4.6.0-preview1-26907-04 2.0.3 From 7974467dc9b4a9253bbefbb598deaf30531a4448 Mon Sep 17 00:00:00 2001 From: "Chris Ross (ASP.NET)" Date: Tue, 30 Oct 2018 12:35:26 -0700 Subject: [PATCH 23/27] Cleanup server limits tests #472 #476 #469 --- .../ServerTests.cs | 96 +++++++------------ .../Utilities.cs | 6 ++ 2 files changed, 42 insertions(+), 60 deletions(-) diff --git a/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/ServerTests.cs b/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/ServerTests.cs index e0ecbc7d2b..32e328a63d 100644 --- a/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/ServerTests.cs +++ b/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/ServerTests.cs @@ -300,22 +300,15 @@ namespace Microsoft.AspNetCore.Server.HttpSys } [ConditionalFact] - public async Task Server_SetHttp503VebosittHittingThrottle_Success() + public async Task Server_SetHttp503VebosityHittingThrottle_Success() { - // This is just to get a dynamic port - string address; - using (Utilities.CreateHttpServer(out address, httpContext => Task.FromResult(0))) { } - - var server = Utilities.CreatePump(); - server.Listener.Options.UrlPrefixes.Add(UrlPrefix.Create(address)); - Assert.Null(server.Listener.Options.MaxConnections); - server.Listener.Options.MaxConnections = 3; - server.Listener.Options.Http503Verbosity = Http503VerbosityLevel.Limited; - - using (server) + using (Utilities.CreateDynamicHost(out var address, options => + { + Assert.Null(options.MaxConnections); + options.MaxConnections = 3; + options.Http503Verbosity = Http503VerbosityLevel.Limited; + }, httpContext => Task.FromResult(0))) { - await server.StartAsync(new DummyApplication(), CancellationToken.None); - using (var client1 = await SendHungRequestAsync("GET", address)) using (var client2 = await SendHungRequestAsync("GET", address)) { @@ -340,31 +333,25 @@ namespace Microsoft.AspNetCore.Server.HttpSys [ConditionalFact] public void Server_SetConnectionLimitArgumentValidation_Success() { - var server = Utilities.CreatePump(); - - Assert.Null(server.Listener.Options.MaxConnections); - Assert.Throws(() => server.Listener.Options.MaxConnections = -2); - Assert.Null(server.Listener.Options.MaxConnections); - server.Listener.Options.MaxConnections = null; - server.Listener.Options.MaxConnections = 3; + using (var server = Utilities.CreatePump()) + { + Assert.Null(server.Listener.Options.MaxConnections); + Assert.Throws(() => server.Listener.Options.MaxConnections = -2); + Assert.Null(server.Listener.Options.MaxConnections); + server.Listener.Options.MaxConnections = null; + server.Listener.Options.MaxConnections = 3; + } } [ConditionalFact] public async Task Server_SetConnectionLimit_Success() { - // This is just to get a dynamic port - string address; - using (Utilities.CreateHttpServer(out address, httpContext => Task.FromResult(0))) { } - - var server = Utilities.CreatePump(); - server.Listener.Options.UrlPrefixes.Add(UrlPrefix.Create(address)); - Assert.Null(server.Listener.Options.MaxConnections); - server.Listener.Options.MaxConnections = 3; - - using (server) + using (Utilities.CreateDynamicHost(out var address, options => + { + Assert.Null(options.MaxConnections); + options.MaxConnections = 3; + }, httpContext => Task.FromResult(0))) { - await server.StartAsync(new DummyApplication(), CancellationToken.None); - using (var client1 = await SendHungRequestAsync("GET", address)) using (var client2 = await SendHungRequestAsync("GET", address)) { @@ -384,19 +371,14 @@ namespace Microsoft.AspNetCore.Server.HttpSys [ConditionalFact] public async Task Server_SetConnectionLimitChangeAfterStarted_Success() { - // This is just to get a dynamic port - string address; - using (Utilities.CreateHttpServer(out address, httpContext => Task.FromResult(0))) { } - - var server = Utilities.CreatePump(); - server.Listener.Options.UrlPrefixes.Add(UrlPrefix.Create(address)); - Assert.Null(server.Listener.Options.MaxConnections); - server.Listener.Options.MaxConnections = 3; - - using (server) + HttpSysOptions options = null; + using (Utilities.CreateDynamicHost(out var address, opt => + { + options = opt; + Assert.Null(options.MaxConnections); + options.MaxConnections = 3; + }, httpContext => Task.FromResult(0))) { - await server.StartAsync(new DummyApplication(), CancellationToken.None); - using (var client1 = await SendHungRequestAsync("GET", address)) using (var client2 = await SendHungRequestAsync("GET", address)) using (var client3 = await SendHungRequestAsync("GET", address)) @@ -404,12 +386,12 @@ namespace Microsoft.AspNetCore.Server.HttpSys // Maxed out, refuses connection and throws await Assert.ThrowsAsync(() => SendRequestAsync(address)); - server.Listener.Options.MaxConnections = 4; + options.MaxConnections = 4; string responseText = await SendRequestAsync(address); Assert.Equal(string.Empty, responseText); - server.Listener.Options.MaxConnections = 2; + options.MaxConnections = 2; // Maxed out, refuses connection and throws await Assert.ThrowsAsync(() => SendRequestAsync(address)); @@ -420,18 +402,12 @@ namespace Microsoft.AspNetCore.Server.HttpSys [ConditionalFact] public async Task Server_SetConnectionLimitInfinite_Success() { - // This is just to get a dynamic port - string address; - using (Utilities.CreateHttpServer(out address, httpContext => Task.FromResult(0))) { } - - var server = Utilities.CreatePump(); - server.Listener.Options.UrlPrefixes.Add(UrlPrefix.Create(address)); - server.Listener.Options.MaxConnections = -1; // infinite - - using (server) + using (Utilities.CreateDynamicHost(out var address, options => + { + Assert.Null(options.MaxConnections); + options.MaxConnections = -1; // infinite + }, httpContext => Task.FromResult(0))) { - await server.StartAsync(new DummyApplication(), CancellationToken.None); - using (var client1 = await SendHungRequestAsync("GET", address)) using (var client2 = await SendHungRequestAsync("GET", address)) using (var client3 = await SendHungRequestAsync("GET", address)) @@ -633,7 +609,7 @@ namespace Microsoft.AspNetCore.Server.HttpSys private async Task SendRequestAsync(string uri) { - using (HttpClient client = new HttpClient()) + using (HttpClient client = new HttpClient() { Timeout = Utilities.DefaultTimeout } ) { return await client.GetStringAsync(uri); } @@ -641,7 +617,7 @@ namespace Microsoft.AspNetCore.Server.HttpSys private async Task SendRequestAsync(string uri, string upload) { - using (HttpClient client = new HttpClient()) + using (HttpClient client = new HttpClient() { Timeout = Utilities.DefaultTimeout }) { HttpResponseMessage response = await client.PostAsync(uri, new StringContent(upload)); response.EnsureSuccessStatusCode(); diff --git a/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Utilities.cs b/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Utilities.cs index cecc4e270a..e46df7666f 100644 --- a/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Utilities.cs +++ b/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Utilities.cs @@ -23,6 +23,7 @@ namespace Microsoft.AspNetCore.Server.HttpSys private const int MaxPort = 8000; private static int NextPort = BasePort; private static object PortLock = new object(); + internal static readonly TimeSpan DefaultTimeout = TimeSpan.FromSeconds(15); internal static IServer CreateHttpServer(out string baseAddress, RequestDelegate app) { @@ -61,6 +62,11 @@ namespace Microsoft.AspNetCore.Server.HttpSys }, app); } + internal static IWebHost CreateDynamicHost(out string baseAddress, Action configureOptions, RequestDelegate app) + { + return CreateDynamicHost(string.Empty, out var root, out baseAddress, configureOptions, app); + } + internal static IWebHost CreateDynamicHost(string basePath, out string root, out string baseAddress, Action configureOptions, RequestDelegate app) { lock (PortLock) From 2451b68ca0e4ec0be484076ce8a735b70ec0fa92 Mon Sep 17 00:00:00 2001 From: "Chris Ross (ASP.NET)" Date: Mon, 29 Oct 2018 12:19:36 -0700 Subject: [PATCH 24/27] Rewrite Listener.ResponseSendFileTests --- .../Listener/ResponseSendFileTests.cs | 344 ---------------- .../OpaqueUpgradeTests.cs | 4 +- .../RequestBodyLimitTests.cs | 64 +-- .../ResponseSendFileTests.cs | 373 +++++++++++++++++- .../Utilities.cs | 37 +- 5 files changed, 440 insertions(+), 382 deletions(-) delete mode 100644 test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Listener/ResponseSendFileTests.cs diff --git a/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Listener/ResponseSendFileTests.cs b/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Listener/ResponseSendFileTests.cs deleted file mode 100644 index 0417776e96..0000000000 --- a/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Listener/ResponseSendFileTests.cs +++ /dev/null @@ -1,344 +0,0 @@ -// Copyright (c) .NET Foundation. All rights reserved. -// Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. - -using System; -using System.Collections.Generic; -using System.IO; -using System.Linq; -using System.Net.Http; -using System.Threading; -using System.Threading.Tasks; -using Microsoft.AspNetCore.Testing.xunit; -using Xunit; - -namespace Microsoft.AspNetCore.Server.HttpSys.Listener -{ - public class ResponseSendFileTests - { - private readonly string AbsoluteFilePath; - private readonly string RelativeFilePath; - private readonly long FileLength; - - public ResponseSendFileTests() - { - AbsoluteFilePath = Directory.GetFiles(Directory.GetCurrentDirectory()).First(); - RelativeFilePath = Path.GetFileName(AbsoluteFilePath); - FileLength = new FileInfo(AbsoluteFilePath).Length; - } - - [ConditionalFact] - public async Task ResponseSendFile_EmptyFileCountUnspecified_SetsChunkedAndFlushesHeaders() - { - var emptyFilePath = Path.Combine(Directory.GetCurrentDirectory(), "zz_" + Guid.NewGuid().ToString() + "EmptyTestFile.txt"); - var emptyFile = File.Create(emptyFilePath, 1024); - emptyFile.Dispose(); - - string address; - using (var server = Utilities.CreateHttpServer(out address)) - { - var responseTask = SendRequestAsync(address); - - var context = await server.AcceptAsync(Utilities.DefaultTimeout).Before(responseTask); - await context.Response.SendFileAsync(emptyFilePath, 0, null, CancellationToken.None); - Assert.True(context.Response.HasStarted); - await context.Response.Body.WriteAsync(new byte[10], 0, 10, CancellationToken.None); - context.Dispose(); - File.Delete(emptyFilePath); - - var response = await responseTask; - Assert.Equal(200, (int)response.StatusCode); - IEnumerable contentLength; - Assert.False(response.Content.Headers.TryGetValues("content-length", out contentLength), "Content-Length"); - Assert.True(response.Headers.TransferEncodingChunked.HasValue); - Assert.Equal(10, (await response.Content.ReadAsByteArrayAsync()).Length); - } - } - - [ConditionalFact] - public async Task ResponseSendFile_WithActiveCancellationToken_Success() - { - string address; - using (var server = Utilities.CreateHttpServer(out address)) - { - var responseTask = SendRequestAsync(address); - - var context = await server.AcceptAsync(Utilities.DefaultTimeout).Before(responseTask); - var cts = new CancellationTokenSource(); - // First write sends headers - await context.Response.SendFileAsync(AbsoluteFilePath, 0, null, cts.Token); - await context.Response.SendFileAsync(AbsoluteFilePath, 0, null, cts.Token); - context.Dispose(); - - var response = await responseTask; - Assert.Equal(200, (int)response.StatusCode); - Assert.Equal(FileLength * 2, (await response.Content.ReadAsByteArrayAsync()).Length); - } - } - - [ConditionalFact] - public async Task ResponseSendFile_WithTimerCancellationToken_Success() - { - string address; - using (var server = Utilities.CreateHttpServer(out address)) - { - var responseTask = SendRequestAsync(address); - - var context = await server.AcceptAsync(Utilities.DefaultTimeout).Before(responseTask); - var cts = new CancellationTokenSource(); - cts.CancelAfter(TimeSpan.FromSeconds(10)); - // First write sends headers - await context.Response.SendFileAsync(AbsoluteFilePath, 0, null, cts.Token); - await context.Response.SendFileAsync(AbsoluteFilePath, 0, null, cts.Token); - context.Dispose(); - - var response = await responseTask; - Assert.Equal(200, (int)response.StatusCode); - Assert.Equal(FileLength * 2, (await response.Content.ReadAsByteArrayAsync()).Length); - } - } - - [ConditionalFact] - public async Task ResponseSendFileWriteExceptions_FirstCallWithCanceledCancellationToken_CancelsAndAborts() - { - string address; - using (var server = Utilities.CreateHttpServer(out address)) - { - server.Options.ThrowWriteExceptions = true; - var responseTask = SendRequestAsync(address); - - var context = await server.AcceptAsync(Utilities.DefaultTimeout).Before(responseTask); - var cts = new CancellationTokenSource(); - cts.Cancel(); - // First write sends headers - var writeTask = context.Response.SendFileAsync(AbsoluteFilePath, 0, null, cts.Token); - Assert.True(writeTask.IsCanceled); - context.Dispose(); -#if NET461 - // .NET HttpClient automatically retries a request if it does not get a response. - context = await server.AcceptAsync(Utilities.DefaultTimeout).Before(responseTask); - cts = new CancellationTokenSource(); - cts.Cancel(); - // First write sends headers - writeTask = context.Response.SendFileAsync(AbsoluteFilePath, 0, null, cts.Token); - Assert.True(writeTask.IsCanceled); - context.Dispose(); -#elif NETCOREAPP2_2 -#else -#error Target framework needs to be updated -#endif - await Assert.ThrowsAsync(() => responseTask); - } - } - - [ConditionalFact] - public async Task ResponseSendFile_FirstSendWithCanceledCancellationToken_CancelsAndAborts() - { - string address; - using (var server = Utilities.CreateHttpServer(out address)) - { - var responseTask = SendRequestAsync(address); - - var context = await server.AcceptAsync(Utilities.DefaultTimeout).Before(responseTask); - var cts = new CancellationTokenSource(); - cts.Cancel(); - // First write sends headers - var writeTask = context.Response.SendFileAsync(AbsoluteFilePath, 0, null, cts.Token); - Assert.True(writeTask.IsCanceled); - context.Dispose(); -#if NET461 - // .NET HttpClient automatically retries a request if it does not get a response. - context = await server.AcceptAsync(Utilities.DefaultTimeout).Before(responseTask); - cts = new CancellationTokenSource(); - cts.Cancel(); - // First write sends headers - writeTask = context.Response.SendFileAsync(AbsoluteFilePath, 0, null, cts.Token); - Assert.True(writeTask.IsCanceled); - context.Dispose(); -#elif NETCOREAPP2_2 -#else -#error Target framework needs to be updated -#endif - await Assert.ThrowsAsync(() => responseTask); - } - } - - [ConditionalFact] - public async Task ResponseSendFileExceptions_SecondSendWithCanceledCancellationToken_CancelsAndAborts() - { - string address; - using (var server = Utilities.CreateHttpServer(out address)) - { - server.Options.ThrowWriteExceptions = true; - var responseTask = SendRequestAsync(address); - - var context = await server.AcceptAsync(Utilities.DefaultTimeout).Before(responseTask); - var cts = new CancellationTokenSource(); - // First write sends headers - await context.Response.SendFileAsync(AbsoluteFilePath, 0, null, cts.Token); - cts.Cancel(); - var writeTask = context.Response.SendFileAsync(AbsoluteFilePath, 0, null, cts.Token); - Assert.True(writeTask.IsCanceled); - context.Dispose(); - - await Assert.ThrowsAsync(() => responseTask); - } - } - - [ConditionalFact] - public async Task ResponseSendFile_SecondSendWithCanceledCancellationToken_CancelsAndAborts() - { - string address; - using (var server = Utilities.CreateHttpServer(out address)) - { - var responseTask = SendRequestAsync(address); - - var context = await server.AcceptAsync(Utilities.DefaultTimeout).Before(responseTask); - var cts = new CancellationTokenSource(); - // First write sends headers - await context.Response.SendFileAsync(AbsoluteFilePath, 0, null, cts.Token); - cts.Cancel(); - var writeTask = context.Response.SendFileAsync(AbsoluteFilePath, 0, null, cts.Token); - Assert.True(writeTask.IsCanceled); - context.Dispose(); - - await Assert.ThrowsAsync(() => responseTask); - } - } - - [ConditionalFact] - public async Task ResponseSendFileExceptions_ClientDisconnectsBeforeFirstSend_SendThrows() - { - string address; - using (var server = Utilities.CreateHttpServer(out address)) - { - server.Options.ThrowWriteExceptions = true; - var cts = new CancellationTokenSource(); - var responseTask = SendRequestAsync(address, cts.Token); - - var context = await server.AcceptAsync(Utilities.DefaultTimeout).Before(responseTask); - - // First write sends headers - cts.Cancel(); - await Assert.ThrowsAnyAsync(() => responseTask); - - Assert.True(context.DisconnectToken.WaitHandle.WaitOne(TimeSpan.FromSeconds(5))); - await Assert.ThrowsAsync(async () => - { - // It can take several tries before Send notices the disconnect. - for (int i = 0; i < Utilities.WriteRetryLimit; i++) - { - await context.Response.SendFileAsync(AbsoluteFilePath, 0, null, CancellationToken.None); - } - }); - - await Assert.ThrowsAsync(() => - context.Response.SendFileAsync(AbsoluteFilePath, 0, null, CancellationToken.None)); - - context.Dispose(); - } - } - - [ConditionalFact] - public async Task ResponseSendFile_ClientDisconnectsBeforeFirstSend_SendCompletesSilently() - { - string address; - using (var server = Utilities.CreateHttpServer(out address)) - { - var cts = new CancellationTokenSource(); - var responseTask = SendRequestAsync(address, cts.Token); - - var context = await server.AcceptAsync(Utilities.DefaultTimeout).Before(responseTask); - // First write sends headers - cts.Cancel(); - await Assert.ThrowsAnyAsync(() => responseTask); - Assert.True(context.DisconnectToken.WaitHandle.WaitOne(TimeSpan.FromSeconds(5))); - // It can take several tries before Send notices the disconnect. - for (int i = 0; i < Utilities.WriteRetryLimit; i++) - { - await context.Response.SendFileAsync(AbsoluteFilePath, 0, null, CancellationToken.None); - } - context.Dispose(); - } - } - - [ConditionalFact] - public async Task ResponseSendFileExceptions_ClientDisconnectsBeforeSecondSend_SendThrows() - { - string address; - using (var server = Utilities.CreateHttpServer(out address)) - { - server.Options.ThrowWriteExceptions = true; - RequestContext context; - using (var client = new HttpClient()) - { - var responseTask = client.GetAsync(address, HttpCompletionOption.ResponseHeadersRead); - - context = await server.AcceptAsync(Utilities.DefaultTimeout).Before(responseTask); - // First write sends headers - var sendFileTask = context.Response.SendFileAsync(AbsoluteFilePath, 0, null, CancellationToken.None); - - var response = await responseTask; - response.EnsureSuccessStatusCode(); - // Drain data from the connection so that SendFileAsync can complete. - var bufferTask = response.Content.LoadIntoBufferAsync(); - - await sendFileTask; - response.Dispose(); - } - - Assert.True(context.DisconnectToken.WaitHandle.WaitOne(TimeSpan.FromSeconds(5))); - await Assert.ThrowsAsync(async () => - { - // It can take several tries before Write notices the disconnect. - for (int i = 0; i < Utilities.WriteRetryLimit; i++) - { - await context.Response.SendFileAsync(AbsoluteFilePath, 0, null, CancellationToken.None); - } - }); - context.Dispose(); - } - } - - [ConditionalFact] - public async Task ResponseSendFile_ClientDisconnectsBeforeSecondSend_SendCompletesSilently() - { - string address; - using (var server = Utilities.CreateHttpServer(out address)) - { - RequestContext context; - using (var client = new HttpClient()) - { - var responseTask = client.GetAsync(address, HttpCompletionOption.ResponseHeadersRead); - - context = await server.AcceptAsync(Utilities.DefaultTimeout).Before(responseTask); - // First write sends headers - var sendFileTask = context.Response.SendFileAsync(AbsoluteFilePath, 0, null, CancellationToken.None); - - var response = await responseTask; - response.EnsureSuccessStatusCode(); - // Drain data from the connection so that SendFileAsync can complete. - var bufferTask = response.Content.LoadIntoBufferAsync(); - - await sendFileTask; - response.Dispose(); - } - - Assert.True(context.DisconnectToken.WaitHandle.WaitOne(TimeSpan.FromSeconds(5))); - // It can take several tries before Write notices the disconnect. - for (int i = 0; i < Utilities.WriteRetryLimit; i++) - { - await context.Response.SendFileAsync(AbsoluteFilePath, 0, null, CancellationToken.None); - } - context.Dispose(); - } - } - - private async Task SendRequestAsync(string uri, CancellationToken cancellationToken = new CancellationToken()) - { - using (HttpClient client = new HttpClient()) - { - return await client.GetAsync(uri, cancellationToken); - } - } - } -} \ No newline at end of file diff --git a/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/OpaqueUpgradeTests.cs b/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/OpaqueUpgradeTests.cs index 609bc59fdd..c9bebee2de 100644 --- a/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/OpaqueUpgradeTests.cs +++ b/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/OpaqueUpgradeTests.cs @@ -134,7 +134,7 @@ namespace Microsoft.AspNetCore.Server.HttpSys ManualResetEvent waitHandle = new ManualResetEvent(false); bool? upgraded = null; string address; - using (Utilities.CreateHttpServer(out address, options => options.MaxRequestBodySize = 10, async httpContext => + using (Utilities.CreateHttpServer(out address, async httpContext => { var feature = httpContext.Features.Get(); Assert.NotNull(feature); @@ -152,7 +152,7 @@ namespace Microsoft.AspNetCore.Server.HttpSys Assert.Equal(15, await stream.ReadAsync(new byte[15], 0, 15)); upgraded = true; waitHandle.Set(); - })) + }, options => options.MaxRequestBodySize = 10)) { using (Stream stream = await SendOpaqueRequestAsync("GET", address)) { diff --git a/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/RequestBodyLimitTests.cs b/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/RequestBodyLimitTests.cs index ae203ceab1..bfeb4f42b9 100644 --- a/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/RequestBodyLimitTests.cs +++ b/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/RequestBodyLimitTests.cs @@ -19,7 +19,7 @@ namespace Microsoft.AspNetCore.Server.HttpSys public async Task ContentLengthEqualsLimit_ReadSync_Success() { string address; - using (Utilities.CreateHttpServer(out address, options => options.MaxRequestBodySize = 11, httpContext => + using (Utilities.CreateHttpServer(out address, httpContext => { httpContext.Features.Get().AllowSynchronousIO = true; var feature = httpContext.Features.Get(); @@ -31,7 +31,7 @@ namespace Microsoft.AspNetCore.Server.HttpSys httpContext.Response.ContentLength = read; httpContext.Response.Body.Write(input, 0, read); return Task.FromResult(0); - })) + }, options => options.MaxRequestBodySize = 11)) { var response = await SendRequestAsync(address, "Hello World"); Assert.Equal("Hello World", response); @@ -42,7 +42,7 @@ namespace Microsoft.AspNetCore.Server.HttpSys public async Task ContentLengthEqualsLimit_ReadAsync_Success() { string address; - using (Utilities.CreateHttpServer(out address, options => options.MaxRequestBodySize = 11, async httpContext => + using (Utilities.CreateHttpServer(out address, async httpContext => { var feature = httpContext.Features.Get(); Assert.NotNull(feature); @@ -52,7 +52,7 @@ namespace Microsoft.AspNetCore.Server.HttpSys int read = await httpContext.Request.Body.ReadAsync(input, 0, input.Length); httpContext.Response.ContentLength = read; await httpContext.Response.Body.WriteAsync(input, 0, read); - })) + }, options => options.MaxRequestBodySize = 11)) { var response = await SendRequestAsync(address, "Hello World"); Assert.Equal("Hello World", response); @@ -63,7 +63,7 @@ namespace Microsoft.AspNetCore.Server.HttpSys public async Task ContentLengthEqualsLimit_ReadBeginEnd_Success() { string address; - using (Utilities.CreateHttpServer(out address, options => options.MaxRequestBodySize = 11, httpContext => + using (Utilities.CreateHttpServer(out address, httpContext => { var feature = httpContext.Features.Get(); Assert.NotNull(feature); @@ -74,7 +74,7 @@ namespace Microsoft.AspNetCore.Server.HttpSys httpContext.Response.ContentLength = read; httpContext.Response.Body.EndWrite(httpContext.Response.Body.BeginWrite(input, 0, read, null, null)); return Task.FromResult(0); - })) + }, options => options.MaxRequestBodySize = 11)) { var response = await SendRequestAsync(address, "Hello World"); Assert.Equal("Hello World", response); @@ -85,7 +85,7 @@ namespace Microsoft.AspNetCore.Server.HttpSys public async Task ChunkedEqualsLimit_ReadSync_Success() { string address; - using (Utilities.CreateHttpServer(out address, options => options.MaxRequestBodySize = 11, httpContext => + using (Utilities.CreateHttpServer(out address, httpContext => { httpContext.Features.Get().AllowSynchronousIO = true; var feature = httpContext.Features.Get(); @@ -97,7 +97,7 @@ namespace Microsoft.AspNetCore.Server.HttpSys httpContext.Response.ContentLength = read; httpContext.Response.Body.Write(input, 0, read); return Task.FromResult(0); - })) + }, options => options.MaxRequestBodySize = 11)) { var response = await SendRequestAsync(address, "Hello World", chunked: true); Assert.Equal("Hello World", response); @@ -108,7 +108,7 @@ namespace Microsoft.AspNetCore.Server.HttpSys public async Task ChunkedEqualsLimit_ReadAsync_Success() { string address; - using (Utilities.CreateHttpServer(out address, options => options.MaxRequestBodySize = 11, async httpContext => + using (Utilities.CreateHttpServer(out address, async httpContext => { var feature = httpContext.Features.Get(); Assert.NotNull(feature); @@ -118,7 +118,7 @@ namespace Microsoft.AspNetCore.Server.HttpSys int read = await httpContext.Request.Body.ReadAsync(input, 0, input.Length); httpContext.Response.ContentLength = read; await httpContext.Response.Body.WriteAsync(input, 0, read); - })) + }, options => options.MaxRequestBodySize = 11)) { var response = await SendRequestAsync(address, "Hello World", chunked: true); Assert.Equal("Hello World", response); @@ -129,7 +129,7 @@ namespace Microsoft.AspNetCore.Server.HttpSys public async Task ChunkedEqualsLimit_ReadBeginEnd_Success() { string address; - using (Utilities.CreateHttpServer(out address, options => options.MaxRequestBodySize = 11, httpContext => + using (Utilities.CreateHttpServer(out address, httpContext => { var feature = httpContext.Features.Get(); Assert.NotNull(feature); @@ -140,7 +140,7 @@ namespace Microsoft.AspNetCore.Server.HttpSys httpContext.Response.ContentLength = read; httpContext.Response.Body.EndWrite(httpContext.Response.Body.BeginWrite(input, 0, read, null, null)); return Task.FromResult(0); - })) + }, options => options.MaxRequestBodySize = 11)) { var response = await SendRequestAsync(address, "Hello World", chunked: true); Assert.Equal("Hello World", response); @@ -151,7 +151,7 @@ namespace Microsoft.AspNetCore.Server.HttpSys public async Task ContentLengthExceedsLimit_ReadSync_ThrowsImmediately() { string address; - using (Utilities.CreateHttpServer(out address, options => options.MaxRequestBodySize = 10, httpContext => + using (Utilities.CreateHttpServer(out address, httpContext => { httpContext.Features.Get().AllowSynchronousIO = true; var feature = httpContext.Features.Get(); @@ -164,7 +164,7 @@ namespace Microsoft.AspNetCore.Server.HttpSys ex = Assert.Throws(() => httpContext.Request.Body.Read(input, 0, input.Length)); Assert.Equal("The request's Content-Length 11 is larger than the request body size limit 10.", ex.Message); return Task.FromResult(0); - })) + }, options => options.MaxRequestBodySize = 10)) { var response = await SendRequestAsync(address, "Hello World"); Assert.Equal(string.Empty, response); @@ -175,7 +175,7 @@ namespace Microsoft.AspNetCore.Server.HttpSys public async Task ContentLengthExceedsLimit_ReadAsync_ThrowsImmediately() { string address; - using (Utilities.CreateHttpServer(out address, options => options.MaxRequestBodySize = 10, httpContext => + using (Utilities.CreateHttpServer(out address, httpContext => { var feature = httpContext.Features.Get(); Assert.NotNull(feature); @@ -187,7 +187,7 @@ namespace Microsoft.AspNetCore.Server.HttpSys ex = Assert.Throws(() => { var t = httpContext.Request.Body.ReadAsync(input, 0, input.Length); }); Assert.Equal("The request's Content-Length 11 is larger than the request body size limit 10.", ex.Message); return Task.FromResult(0); - })) + }, options => options.MaxRequestBodySize = 10)) { var response = await SendRequestAsync(address, "Hello World"); Assert.Equal(string.Empty, response); @@ -198,7 +198,7 @@ namespace Microsoft.AspNetCore.Server.HttpSys public async Task ContentLengthExceedsLimit_ReadBeginEnd_ThrowsImmediately() { string address; - using (Utilities.CreateHttpServer(out address, options => options.MaxRequestBodySize = 10, httpContext => + using (Utilities.CreateHttpServer(out address, httpContext => { var feature = httpContext.Features.Get(); Assert.NotNull(feature); @@ -210,7 +210,7 @@ namespace Microsoft.AspNetCore.Server.HttpSys ex = Assert.Throws(() => httpContext.Request.Body.BeginRead(input, 0, input.Length, null, null)); Assert.Equal("The request's Content-Length 11 is larger than the request body size limit 10.", ex.Message); return Task.FromResult(0); - })) + }, options => options.MaxRequestBodySize = 10)) { var response = await SendRequestAsync(address, "Hello World"); Assert.Equal(string.Empty, response); @@ -221,7 +221,7 @@ namespace Microsoft.AspNetCore.Server.HttpSys public async Task ChunkedExceedsLimit_ReadSync_ThrowsAtLimit() { string address; - using (Utilities.CreateHttpServer(out address, options => options.MaxRequestBodySize = 10, httpContext => + using (Utilities.CreateHttpServer(out address, httpContext => { httpContext.Features.Get().AllowSynchronousIO = true; var feature = httpContext.Features.Get(); @@ -234,7 +234,7 @@ namespace Microsoft.AspNetCore.Server.HttpSys ex = Assert.Throws(() => httpContext.Request.Body.Read(input, 0, input.Length)); Assert.Equal("The total number of bytes read 11 has exceeded the request body size limit 10.", ex.Message); return Task.FromResult(0); - })) + }, options => options.MaxRequestBodySize = 10)) { var response = await SendRequestAsync(address, "Hello World", chunked: true); Assert.Equal(string.Empty, response); @@ -245,7 +245,7 @@ namespace Microsoft.AspNetCore.Server.HttpSys public async Task ChunkedExceedsLimit_ReadAsync_ThrowsAtLimit() { string address; - using (Utilities.CreateHttpServer(out address, options => options.MaxRequestBodySize = 10, async httpContext => + using (Utilities.CreateHttpServer(out address, async httpContext => { var feature = httpContext.Features.Get(); Assert.NotNull(feature); @@ -256,7 +256,7 @@ namespace Microsoft.AspNetCore.Server.HttpSys Assert.Equal("The total number of bytes read 11 has exceeded the request body size limit 10.", ex.Message); ex = await Assert.ThrowsAsync(() => httpContext.Request.Body.ReadAsync(input, 0, input.Length)); Assert.Equal("The total number of bytes read 11 has exceeded the request body size limit 10.", ex.Message); - })) + }, options => options.MaxRequestBodySize = 10)) { var response = await SendRequestAsync(address, "Hello World", chunked: true); Assert.Equal(string.Empty, response); @@ -267,7 +267,7 @@ namespace Microsoft.AspNetCore.Server.HttpSys public async Task ChunkedExceedsLimit_ReadBeginEnd_ThrowsAtLimit() { string address; - using (Utilities.CreateHttpServer(out address, options => options.MaxRequestBodySize = 10, httpContext => + using (Utilities.CreateHttpServer(out address, httpContext => { var feature = httpContext.Features.Get(); Assert.NotNull(feature); @@ -280,7 +280,7 @@ namespace Microsoft.AspNetCore.Server.HttpSys ex = Assert.Throws(() => body.EndRead(body.BeginRead(input, 0, input.Length, null, null))); Assert.Equal("The total number of bytes read 11 has exceeded the request body size limit 10.", ex.Message); return Task.FromResult(0); - })) + }, options => options.MaxRequestBodySize = 10)) { var response = await SendRequestAsync(address, "Hello World", chunked: true); Assert.Equal(string.Empty, response); @@ -292,7 +292,7 @@ namespace Microsoft.AspNetCore.Server.HttpSys { var content = new StaggardContent(); string address; - using (Utilities.CreateHttpServer(out address, options => options.MaxRequestBodySize = 10, httpContext => + using (Utilities.CreateHttpServer(out address, httpContext => { httpContext.Features.Get().AllowSynchronousIO = true; var feature = httpContext.Features.Get(); @@ -306,7 +306,7 @@ namespace Microsoft.AspNetCore.Server.HttpSys var ex = Assert.Throws(() => httpContext.Request.Body.Read(input, 0, input.Length)); Assert.Equal("The total number of bytes read 20 has exceeded the request body size limit 10.", ex.Message); return Task.FromResult(0); - })) + }, options => options.MaxRequestBodySize = 10)) { string response = await SendRequestAsync(address, content, chunked: true); Assert.Equal(string.Empty, response); @@ -318,7 +318,7 @@ namespace Microsoft.AspNetCore.Server.HttpSys { var content = new StaggardContent(); string address; - using (Utilities.CreateHttpServer(out address, options => options.MaxRequestBodySize = 10, async httpContext => + using (Utilities.CreateHttpServer(out address, async httpContext => { var feature = httpContext.Features.Get(); Assert.NotNull(feature); @@ -330,7 +330,7 @@ namespace Microsoft.AspNetCore.Server.HttpSys content.Block.Release(); var ex = await Assert.ThrowsAsync(() => httpContext.Request.Body.ReadAsync(input, 0, input.Length)); Assert.Equal("The total number of bytes read 20 has exceeded the request body size limit 10.", ex.Message); - })) + }, options => options.MaxRequestBodySize = 10)) { string response = await SendRequestAsync(address, content, chunked: true); Assert.Equal(string.Empty, response); @@ -341,7 +341,7 @@ namespace Microsoft.AspNetCore.Server.HttpSys public async Task AdjustLimitPerRequest_ContentLength_ReadAsync_Success() { string address; - using (Utilities.CreateHttpServer(out address, options => options.MaxRequestBodySize = 11, async httpContext => + using (Utilities.CreateHttpServer(out address, async httpContext => { var feature = httpContext.Features.Get(); Assert.NotNull(feature); @@ -354,7 +354,7 @@ namespace Microsoft.AspNetCore.Server.HttpSys Assert.True(feature.IsReadOnly); httpContext.Response.ContentLength = read; await httpContext.Response.Body.WriteAsync(input, 0, read); - })) + }, options => options.MaxRequestBodySize = 11)) { var response = await SendRequestAsync(address, "Hello World!"); Assert.Equal("Hello World!", response); @@ -365,7 +365,7 @@ namespace Microsoft.AspNetCore.Server.HttpSys public async Task AdjustLimitPerRequest_Chunked_ReadAsync_Success() { string address; - using (Utilities.CreateHttpServer(out address, options => options.MaxRequestBodySize = 11, async httpContext => + using (Utilities.CreateHttpServer(out address, async httpContext => { var feature = httpContext.Features.Get(); Assert.NotNull(feature); @@ -378,7 +378,7 @@ namespace Microsoft.AspNetCore.Server.HttpSys Assert.True(feature.IsReadOnly); httpContext.Response.ContentLength = read; await httpContext.Response.Body.WriteAsync(input, 0, read); - })) + }, options => options.MaxRequestBodySize = 11)) { var response = await SendRequestAsync(address, "Hello World!", chunked: true); Assert.Equal("Hello World!", response); diff --git a/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/ResponseSendFileTests.cs b/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/ResponseSendFileTests.cs index d3a8c5e5d0..69f0a64ec9 100644 --- a/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/ResponseSendFileTests.cs +++ b/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/ResponseSendFileTests.cs @@ -10,6 +10,7 @@ using System.Net.Http; using System.Text; using System.Threading; using System.Threading.Tasks; +using Microsoft.AspNetCore.Http; using Microsoft.AspNetCore.Http.Features; using Microsoft.AspNetCore.Testing.xunit; using Xunit; @@ -348,11 +349,377 @@ namespace Microsoft.AspNetCore.Server.HttpSys } } - private async Task SendRequestAsync(string uri) + [ConditionalFact] + public async Task ResponseSendFile_EmptyFileCountUnspecified_SetsChunkedAndFlushesHeaders() { - using (HttpClient client = new HttpClient()) + var emptyFilePath = Path.Combine(Directory.GetCurrentDirectory(), "zz_" + Guid.NewGuid().ToString() + "EmptyTestFile.txt"); + var emptyFile = File.Create(emptyFilePath, 1024); + emptyFile.Dispose(); + try { - return await client.GetAsync(uri); + using (Utilities.CreateHttpServer(out var address, async httpContext => + { + await httpContext.Response.SendFileAsync(emptyFilePath, 0, null, CancellationToken.None); + Assert.True(httpContext.Response.HasStarted); + await httpContext.Response.Body.WriteAsync(new byte[10], 0, 10, CancellationToken.None); + })) + { + var response = await SendRequestAsync(address); + Assert.Equal(200, (int)response.StatusCode); + Assert.False(response.Content.Headers.TryGetValues("content-length", out var contentLength), "Content-Length"); + Assert.True(response.Headers.TransferEncodingChunked.HasValue); + Assert.Equal(10, (await response.Content.ReadAsByteArrayAsync()).Length); + } + } + finally + { + File.Delete(emptyFilePath); + } + } + + [ConditionalFact] + public async Task ResponseSendFile_WithActiveCancellationToken_Success() + { + using (Utilities.CreateHttpServer(out var address, async httpContext => + { + var cts = new CancellationTokenSource(); + // First write sends headers + await httpContext.Response.SendFileAsync(AbsoluteFilePath, 0, null, cts.Token); + await httpContext.Response.SendFileAsync(AbsoluteFilePath, 0, null, cts.Token); + })) + { + var response = await SendRequestAsync(address); + Assert.Equal(200, (int)response.StatusCode); + Assert.Equal(FileLength * 2, (await response.Content.ReadAsByteArrayAsync()).Length); + } + } + + [ConditionalFact] + public async Task ResponseSendFile_WithTimerCancellationToken_Success() + { + using (Utilities.CreateHttpServer(out var address, async httpContext => + { + var cts = new CancellationTokenSource(); + cts.CancelAfter(TimeSpan.FromSeconds(10)); + // First write sends headers + await httpContext.Response.SendFileAsync(AbsoluteFilePath, 0, null, cts.Token); + await httpContext.Response.SendFileAsync(AbsoluteFilePath, 0, null, cts.Token); + })) + { + var response = await SendRequestAsync(address); + Assert.Equal(200, (int)response.StatusCode); + Assert.Equal(FileLength * 2, (await response.Content.ReadAsByteArrayAsync()).Length); + } + } + + [ConditionalFact] + public async Task ResponseSendFileWriteExceptions_FirstCallWithCanceledCancellationToken_CancelsAndAborts() + { + var testComplete = new TaskCompletionSource(TaskCreationOptions.RunContinuationsAsynchronously); + using (Utilities.CreateHttpServer(out var address, httpContext => + { + try + { + var cts = new CancellationTokenSource(); + cts.Cancel(); + // First write sends headers + var writeTask = httpContext.Response.SendFileAsync(AbsoluteFilePath, 0, null, cts.Token); + Assert.True(writeTask.IsCanceled); + testComplete.SetResult(0); + } + catch (Exception ex) + { + testComplete.SetException(ex); + } + + return Task.CompletedTask; + }, options => options.ThrowWriteExceptions = true)) + { + await Assert.ThrowsAsync(() => SendRequestAsync(address)); + await testComplete.Task.WithTimeout(); + } + } + + [ConditionalFact] + public async Task ResponseSendFile_FirstSendWithCanceledCancellationToken_CancelsAndAborts() + { + var testComplete = new TaskCompletionSource(TaskCreationOptions.RunContinuationsAsynchronously); + using (Utilities.CreateHttpServer(out var address, httpContext => + { + try + { + var cts = new CancellationTokenSource(); + cts.Cancel(); + // First write sends headers + var writeTask = httpContext.Response.SendFileAsync(AbsoluteFilePath, 0, null, cts.Token); + Assert.True(writeTask.IsCanceled); + testComplete.SetResult(0); + } + catch (Exception ex) + { + testComplete.SetException(ex); + } + + return Task.CompletedTask; + })) + { + await Assert.ThrowsAsync(() => SendRequestAsync(address)); + await testComplete.Task.WithTimeout(); + } + } + + [ConditionalFact] + public async Task ResponseSendFileExceptions_SecondSendWithCanceledCancellationToken_CancelsAndAborts() + { + var testComplete = new TaskCompletionSource(TaskCreationOptions.RunContinuationsAsynchronously); + using (Utilities.CreateHttpServer(out var address, async httpContext => + { + try + { + var cts = new CancellationTokenSource(); + // First write sends headers + await httpContext.Response.SendFileAsync(AbsoluteFilePath, 0, null, cts.Token); + cts.Cancel(); + var writeTask = httpContext.Response.SendFileAsync(AbsoluteFilePath, 0, null, cts.Token); + Assert.True(writeTask.IsCanceled); + testComplete.SetResult(0); + } + catch (Exception ex) + { + testComplete.SetException(ex); + } + }, options => options.ThrowWriteExceptions = true)) + { + await Assert.ThrowsAsync(() => SendRequestAsync(address)); + await testComplete.Task.WithTimeout(); + } + } + + [ConditionalFact] + public async Task ResponseSendFile_SecondSendWithCanceledCancellationToken_CancelsAndAborts() + { + var testComplete = new TaskCompletionSource(TaskCreationOptions.RunContinuationsAsynchronously); + using (Utilities.CreateHttpServer(out var address, async httpContext => + { + try + { + var cts = new CancellationTokenSource(); + // First write sends headers + await httpContext.Response.SendFileAsync(AbsoluteFilePath, 0, null, cts.Token); + cts.Cancel(); + var writeTask = httpContext.Response.SendFileAsync(AbsoluteFilePath, 0, null, cts.Token); + Assert.True(writeTask.IsCanceled); + testComplete.SetResult(0); + } + catch (Exception ex) + { + testComplete.SetException(ex); + } + })) + { + await Assert.ThrowsAsync(() => SendRequestAsync(address)); + await testComplete.Task.WithTimeout(); + } + } + + [ConditionalFact] + public async Task ResponseSendFileExceptions_ClientDisconnectsBeforeFirstSend_SendThrows() + { + var requestReceived = new TaskCompletionSource(TaskCreationOptions.RunContinuationsAsynchronously); + var requestCancelled = new TaskCompletionSource(TaskCreationOptions.RunContinuationsAsynchronously); + var cancellationReceived = new TaskCompletionSource(TaskCreationOptions.RunContinuationsAsynchronously); + var testComplete = new TaskCompletionSource(TaskCreationOptions.RunContinuationsAsynchronously); + using (Utilities.CreateHttpServer(out var address, async httpContext => + { + httpContext.RequestAborted.Register(() => cancellationReceived.SetResult(0)); + requestReceived.SetResult(0); + await requestCancelled.Task; + + try + { + await Assert.ThrowsAsync(async () => + { + // It can take several tries before Send notices the disconnect. + for (int i = 0; i < Utilities.WriteRetryLimit; i++) + { + await httpContext.Response.SendFileAsync(AbsoluteFilePath, 0, null); + } + }); + + await Assert.ThrowsAsync(() => + httpContext.Response.SendFileAsync(AbsoluteFilePath, 0, null)); + + testComplete.SetResult(0); + } + catch (Exception ex) + { + testComplete.SetException(ex); + } + + }, options => options.ThrowWriteExceptions = true)) + { + var cts = new CancellationTokenSource(); + var responseTask = SendRequestAsync(address, cts.Token); + await requestReceived.Task.WithTimeout(); + // First write sends headers + cts.Cancel(); + await Assert.ThrowsAnyAsync(() => responseTask); + requestCancelled.SetResult(0); + + await testComplete.Task.WithTimeout(); + await cancellationReceived.Task.WithTimeout(); + } + } + + [ConditionalFact] + public async Task ResponseSendFile_ClientDisconnectsBeforeFirstSend_SendCompletesSilently() + { + var requestReceived = new TaskCompletionSource(TaskCreationOptions.RunContinuationsAsynchronously); + var requestCancelled = new TaskCompletionSource(TaskCreationOptions.RunContinuationsAsynchronously); + var cancellationReceived = new TaskCompletionSource(TaskCreationOptions.RunContinuationsAsynchronously); + var testComplete = new TaskCompletionSource(TaskCreationOptions.RunContinuationsAsynchronously); + using (Utilities.CreateHttpServer(out var address, async httpContext => + { + httpContext.RequestAborted.Register(() => cancellationReceived.SetResult(0)); + requestReceived.SetResult(0); + await requestCancelled.Task; + + try + { + // It can take several tries before Send notices the disconnect. + for (int i = 0; i < Utilities.WriteRetryLimit; i++) + { + await httpContext.Response.SendFileAsync(AbsoluteFilePath, 0, null); + } + + testComplete.SetResult(0); + } + catch (Exception ex) + { + testComplete.SetException(ex); + } + + })) + { + var cts = new CancellationTokenSource(); + var responseTask = SendRequestAsync(address, cts.Token); + await requestReceived.Task.WithTimeout(); + // First write sends headers + cts.Cancel(); + await Assert.ThrowsAnyAsync(() => responseTask); + requestCancelled.SetResult(0); + + await testComplete.Task.WithTimeout(); + await cancellationReceived.Task.WithTimeout(); + } + } + + [ConditionalFact] + public async Task ResponseSendFileExceptions_ClientDisconnectsBeforeSecondSend_SendThrows() + { + var firstSendComplete = new TaskCompletionSource(TaskCreationOptions.RunContinuationsAsynchronously); + var clientDisconnected = new TaskCompletionSource(TaskCreationOptions.RunContinuationsAsynchronously); + var cancellationReceived = new TaskCompletionSource(TaskCreationOptions.RunContinuationsAsynchronously); + var testComplete = new TaskCompletionSource(TaskCreationOptions.RunContinuationsAsynchronously); + using (Utilities.CreateHttpServer(out var address, async httpContext => + { + httpContext.RequestAborted.Register(() => cancellationReceived.SetResult(0)); + // First write sends headers + await httpContext.Response.SendFileAsync(AbsoluteFilePath, 0, null); + firstSendComplete.SetResult(0); + await clientDisconnected.Task; + + try + { + await Assert.ThrowsAsync(async () => + { + // It can take several tries before Write notices the disconnect. + for (int i = 0; i < Utilities.WriteRetryLimit; i++) + { + await httpContext.Response.SendFileAsync(AbsoluteFilePath, 0, null, CancellationToken.None); + } + }); + + testComplete.SetResult(0); + } + catch (Exception ex) + { + testComplete.SetException(ex); + } + }, options => options.ThrowWriteExceptions = true)) + { + using (var client = new HttpClient()) + { + var response = await client.GetAsync(address, HttpCompletionOption.ResponseHeadersRead); + response.EnsureSuccessStatusCode(); + // Drain data from the connection so that SendFileAsync can complete. + var bufferTask = response.Content.LoadIntoBufferAsync(); + + await firstSendComplete.Task.WithTimeout(); + + // Abort + response.Dispose(); + } + clientDisconnected.SetResult(0); + await testComplete.Task.WithTimeout(); + await cancellationReceived.Task.WithTimeout(); + } + } + + [ConditionalFact] + public async Task ResponseSendFile_ClientDisconnectsBeforeSecondSend_SendCompletesSilently() + { + var firstSendComplete = new TaskCompletionSource(TaskCreationOptions.RunContinuationsAsynchronously); + var clientDisconnected = new TaskCompletionSource(TaskCreationOptions.RunContinuationsAsynchronously); + var cancellationReceived = new TaskCompletionSource(TaskCreationOptions.RunContinuationsAsynchronously); + var testComplete = new TaskCompletionSource(TaskCreationOptions.RunContinuationsAsynchronously); + using (Utilities.CreateHttpServer(out var address, async httpContext => + { + httpContext.RequestAborted.Register(() => cancellationReceived.SetResult(0)); + // First write sends headers + await httpContext.Response.SendFileAsync(AbsoluteFilePath, 0, null); + firstSendComplete.SetResult(0); + await clientDisconnected.Task; + + try + { + // It can take several tries before Write notices the disconnect. + for (int i = 0; i < Utilities.WriteRetryLimit; i++) + { + await httpContext.Response.SendFileAsync(AbsoluteFilePath, 0, null, CancellationToken.None); + } + + testComplete.SetResult(0); + } + catch (Exception ex) + { + testComplete.SetException(ex); + } + })) + { + using (var client = new HttpClient()) + { + var response = await client.GetAsync(address, HttpCompletionOption.ResponseHeadersRead); + response.EnsureSuccessStatusCode(); + // Drain data from the connection so that SendFileAsync can complete. + var bufferTask = response.Content.LoadIntoBufferAsync(); + + await firstSendComplete.Task.WithTimeout(); + + // Abort + response.Dispose(); + } + clientDisconnected.SetResult(0); + await testComplete.Task.WithTimeout(); + await cancellationReceived.Task.WithTimeout(); + } + } + + private async Task SendRequestAsync(string uri, CancellationToken cancellationToken = new CancellationToken()) + { + using (HttpClient client = new HttpClient() { Timeout = Utilities.DefaultTimeout }) + { + return await client.GetAsync(uri, cancellationToken); } } } diff --git a/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Utilities.cs b/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Utilities.cs index e46df7666f..5c340a93c9 100644 --- a/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Utilities.cs +++ b/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Utilities.cs @@ -3,6 +3,7 @@ using System; using System.Threading; +using System.Threading.Tasks; using Microsoft.AspNetCore.Authentication; using Microsoft.AspNetCore.Builder; using Microsoft.AspNetCore.Hosting; @@ -24,6 +25,7 @@ namespace Microsoft.AspNetCore.Server.HttpSys private static int NextPort = BasePort; private static object PortLock = new object(); internal static readonly TimeSpan DefaultTimeout = TimeSpan.FromSeconds(15); + internal static readonly int WriteRetryLimit = 1000; internal static IServer CreateHttpServer(out string baseAddress, RequestDelegate app) { @@ -31,7 +33,7 @@ namespace Microsoft.AspNetCore.Server.HttpSys return CreateDynamicHttpServer(string.Empty, out root, out baseAddress, options => { }, app); } - internal static IServer CreateHttpServer(out string baseAddress, Action configureOptions, RequestDelegate app) + internal static IServer CreateHttpServer(out string baseAddress, RequestDelegate app, Action configureOptions) { string root; return CreateDynamicHttpServer(string.Empty, out root, out baseAddress, configureOptions, app); @@ -148,5 +150,38 @@ namespace Microsoft.AspNetCore.Server.HttpSys server.StartAsync(new DummyApplication(app), CancellationToken.None).Wait(); return server; } + + internal static Task WithTimeout(this Task task) => task.WithTimeout(DefaultTimeout); + + internal static async Task WithTimeout(this Task task, TimeSpan timeout) + { + var completedTask = await Task.WhenAny(task, Task.Delay(timeout)); + + if (completedTask == task) + { + await task; + return; + } + else + { + throw new TimeoutException("The task has timed out."); + } + } + + internal static Task WithTimeout(this Task task) => task.WithTimeout(DefaultTimeout); + + internal static async Task WithTimeout(this Task task, TimeSpan timeout) + { + var completedTask = await Task.WhenAny(task, Task.Delay(timeout)); + + if (completedTask == task) + { + return await task; + } + else + { + throw new TimeoutException("The task has timed out."); + } + } } } From 60af147f035f3c9cf2ecc03272c498944d1f9595 Mon Sep 17 00:00:00 2001 From: "Chris Ross (ASP.NET)" Date: Tue, 6 Nov 2018 09:39:09 -0800 Subject: [PATCH 25/27] Remove net472 test target --- build/dependencies.props | 1 - build/sources.props | 1 - test/Directory.Build.props | 5 ---- .../Listener/ResponseBodyTests.cs | 28 ++----------------- .../ResponseHeaderTests.cs | 12 -------- 5 files changed, 2 insertions(+), 45 deletions(-) diff --git a/build/dependencies.props b/build/dependencies.props index df41032480..8666e2bfc5 100644 --- a/build/dependencies.props +++ b/build/dependencies.props @@ -11,7 +11,6 @@ 2.0.9 2.1.3 2.2.0-preview3-27014-02 - 1.0.0-alpha-004 3.0.0-alpha1-10653 15.6.1 4.6.0-preview1-26907-04 diff --git a/build/sources.props b/build/sources.props index 2fcf9273e5..9215df9751 100644 --- a/build/sources.props +++ b/build/sources.props @@ -8,7 +8,6 @@ https://dotnet.myget.org/F/dotnet-core/api/v3/index.json; https://dotnet.myget.org/F/aspnetcore-dev/api/v3/index.json; https://dotnet.myget.org/F/aspnetcore-tools/api/v3/index.json; - https://dotnet.myget.org/F/roslyn-tools/api/v3/index.json; $(RestoreSources); diff --git a/test/Directory.Build.props b/test/Directory.Build.props index f66637ad9f..ffd3106b17 100644 --- a/test/Directory.Build.props +++ b/test/Directory.Build.props @@ -5,7 +5,6 @@ netcoreapp2.2 $(DeveloperBuildTestTfms) $(StandardTestTfms) - $(StandardTestTfms);net472 @@ -16,8 +15,4 @@ - - - - diff --git a/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Listener/ResponseBodyTests.cs b/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Listener/ResponseBodyTests.cs index 1b3bbd7a33..ed3bfde554 100644 --- a/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Listener/ResponseBodyTests.cs +++ b/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Listener/ResponseBodyTests.cs @@ -159,19 +159,7 @@ namespace Microsoft.AspNetCore.Server.HttpSys.Listener var writeTask = context.Response.Body.WriteAsync(new byte[10], 0, 10, cts.Token); Assert.True(writeTask.IsCanceled); context.Dispose(); -#if NET472 - // HttpClient retries the request because it didn't get a response. - context = await server.AcceptAsync(Utilities.DefaultTimeout).Before(responseTask); - cts = new CancellationTokenSource(); - cts.Cancel(); - // First write sends headers - writeTask = context.Response.Body.WriteAsync(new byte[10], 0, 10, cts.Token); - Assert.True(writeTask.IsCanceled); - context.Dispose(); -#elif NETCOREAPP2_2 -#else -#error Target framework needs to be updated -#endif + await Assert.ThrowsAsync(() => responseTask); } } @@ -191,19 +179,7 @@ namespace Microsoft.AspNetCore.Server.HttpSys.Listener var writeTask = context.Response.Body.WriteAsync(new byte[10], 0, 10, cts.Token); Assert.True(writeTask.IsCanceled); context.Dispose(); -#if NET472 - // HttpClient retries the request because it didn't get a response. - context = await server.AcceptAsync(Utilities.DefaultTimeout).Before(responseTask); - cts = new CancellationTokenSource(); - cts.Cancel(); - // First write sends headers - writeTask = context.Response.Body.WriteAsync(new byte[10], 0, 10, cts.Token); - Assert.True(writeTask.IsCanceled); - context.Dispose(); -#elif NETCOREAPP2_2 -#else -#error Target framework needs to be updated -#endif + await Assert.ThrowsAsync(() => responseTask); } } diff --git a/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/ResponseHeaderTests.cs b/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/ResponseHeaderTests.cs index 270e5aeaa7..2fe93b2cdf 100644 --- a/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/ResponseHeaderTests.cs +++ b/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/ResponseHeaderTests.cs @@ -81,13 +81,7 @@ namespace Microsoft.AspNetCore.Server.HttpSys Assert.Equal(0, response.ContentLength); Assert.NotNull(response.Headers["Date"]); Assert.Equal("Microsoft-HTTPAPI/2.0", response.Headers["Server"]); -#if NETCOREAPP2_2 // WebHeaderCollection.GetValues() not available in CoreCLR. Assert.Equal("custom1, and custom2, custom3", response.Headers["WWW-Authenticate"]); -#elif NET472 - Assert.Equal(new string[] { "custom1, and custom2", "custom3" }, response.Headers.GetValues("WWW-Authenticate")); -#else -#error Target framework needs to be updated -#endif } } @@ -111,13 +105,7 @@ namespace Microsoft.AspNetCore.Server.HttpSys Assert.Equal(0, response.ContentLength); Assert.NotNull(response.Headers["Date"]); Assert.Equal("Microsoft-HTTPAPI/2.0", response.Headers["Server"]); -#if NETCOREAPP2_2 // WebHeaderCollection.GetValues() not available in CoreCLR. Assert.Equal("custom1, and custom2, custom3", response.Headers["Custom-Header1"]); -#elif NET472 - Assert.Equal(new string[] { "custom1, and custom2", "custom3" }, response.Headers.GetValues("Custom-Header1")); -#else -#error Target framework needs to be updated -#endif } } From d4f588658218ef59c8ae14261e323efa6d8a8156 Mon Sep 17 00:00:00 2001 From: Nate McMaster Date: Wed, 21 Nov 2018 15:55:25 -0800 Subject: [PATCH 26/27] Update README.md --- README.md | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/README.md b/README.md index b9c9f22edf..abf9cf99f7 100644 --- a/README.md +++ b/README.md @@ -1,10 +1,8 @@ -HttpSysServer -================= +HttpSysServer [Archived] +======================== -| AppVeyor | Travis | -| ---- | ---- -| [![AppVeyor](https://ci.appveyor.com/api/projects/status/47fv9qoe862xlr25/branch/dev?svg=true)](https://ci.appveyor.com/project/aspnetci/HttpSysServer/branch/dev) | [![Travis](https://travis-ci.org/aspnet/HttpSysServer.svg?branch=dev)](https://travis-ci.org/aspnet/HttpSysServer) | +**This GitHub project has been archived.** Ongoing development on this project can be found in . This repo contains a web server for ASP.NET Core based on the Windows [Http Server API](https://msdn.microsoft.com/en-us/library/windows/desktop/aa364510.aspx). -This project is part of ASP.NET Core. You can find samples, documentation and getting started instructions for ASP.NET Core at the [Home](https://github.com/aspnet/home) repo. +This project is part of ASP.NET Core. You can find samples, documentation and getting started instructions for ASP.NET Core at the [AspNetCore](https://github.com/aspnet/AspNetCore) repo. From 70dcf6c2867d5e439972dd89bf0ee4fd5ef7315e Mon Sep 17 00:00:00 2001 From: Ryan Brandenburg Date: Mon, 26 Nov 2018 12:11:10 -0800 Subject: [PATCH 27/27] Reorganize source code in preparation to move into aspnet/AspNetCore Prior to reorganization, this source code was found in https://github.com/aspnet/HttpSysServer/tree/d4f588658218ef59c8ae14261e323efa6d8a8156 --- .appveyor.yml | 17 -- .gitattributes | 51 ---- .travis.yml | 27 -- .vsts-pipelines/builds/ci-internal.yml | 13 - .vsts-pipelines/builds/ci-public.yml | 15 - CONTRIBUTING.md | 4 - LICENSE.txt | 201 -------------- NuGet.config | 7 - build.cmd | 2 - build.sh | 8 - korebuild-lock.txt | 2 - korebuild.json | 4 - run.cmd | 2 - run.ps1 | 209 -------------- run.sh | 256 ------------------ .gitignore => src/HttpSysServer/.gitignore | 0 .../HttpSysServer/Directory.Build.props | 0 .../HttpSysServer/Directory.Build.targets | 0 .../HttpSysServer/HttpSysServer.sln | 0 .../HttpSysServer/NuGetPackageVerifier.json | 0 README.md => src/HttpSysServer/README.md | 0 {build => src/HttpSysServer/build}/Key.snk | Bin .../HttpSysServer/build}/dependencies.props | 0 {build => src/HttpSysServer/build}/repo.props | 0 .../HttpSysServer/build}/sources.props | 0 .../samples}/HotAddSample/HotAddSample.csproj | 0 .../Properties/launchSettings.json | 0 .../samples}/HotAddSample/Startup.cs | 0 .../samples}/SelfHostServer/App.config | 0 .../Properties/launchSettings.json | 0 .../samples}/SelfHostServer/Public/1kb.txt | 0 .../SelfHostServer/SelfHostServer.csproj | 0 .../samples}/SelfHostServer/Startup.cs | 0 .../samples}/TestClient/App.config | 0 .../samples}/TestClient/Program.cs | 0 .../TestClient/Properties/AssemblyInfo.cs | 0 .../samples}/TestClient/TestClient.csproj | 0 .../Constants.cs | 0 .../NativeInterop/CookedUrl.cs | 0 .../NativeInterop/HeapAllocHandle.cs | 0 .../NativeInterop/HttpApiTypes.cs | 0 .../NativeInterop/HttpSysRequestHeader.cs | 0 .../NativeInterop/HttpSysResponseHeader.cs | 0 .../NativeInterop/NclUtilities.cs | 0 .../SafeLocalFreeChannelBinding.cs | 0 .../NativeInterop/SafeLocalMemHandle.cs | 0 .../NativeInterop/SafeNativeOverlapped.cs | 0 .../NativeInterop/SocketAddress.cs | 0 .../NativeInterop/UnsafeNativeMethods.cs | 0 .../RequestProcessing/HeaderCollection.cs | 0 .../RequestProcessing/HeaderEncoding.cs | 0 .../RequestProcessing/HeaderParser.cs | 0 .../RequestProcessing/HttpKnownHeaderNames.cs | 0 .../RequestProcessing/NativeRequestContext.cs | 0 .../RequestProcessing/RawUrlHelper.cs | 0 .../RequestHeaders.Generated.cs | 0 .../RequestProcessing/RequestHeaders.cs | 0 .../RequestProcessing/RequestUriBuilder.cs | 0 .../RequestProcessing/SslStatus.cs | 0 .../src}/Directory.Build.props | 0 .../AsyncAcceptContext.cs | 0 .../AuthenticationHandler.cs | 0 .../AuthenticationManager.cs | 0 .../AuthenticationSchemes.cs | 0 .../FeatureContext.cs | 0 .../Helpers.cs | 0 .../Http503VerbosityLevel .cs | 0 .../HttpSysDefaults.cs | 0 .../HttpSysException.cs | 0 .../HttpSysListener.cs | 0 .../HttpSysOptions.cs | 0 .../LogHelper.cs | 0 .../MessagePump.cs | 0 ...Microsoft.AspNetCore.Server.HttpSys.csproj | 0 .../NativeInterop/ComNetOS.cs | 0 .../NativeInterop/DisconnectListener.cs | 0 .../NativeInterop/HttpApi.cs | 0 .../NativeInterop/HttpRequestQueueV2Handle.cs | 0 .../NativeInterop/HttpServerSessionHandle.cs | 0 .../NativeInterop/HttpSysSettings.cs | 0 .../NativeInterop/IntPtrHelper.cs | 0 .../NativeInterop/RequestQueue.cs | 0 .../NativeInterop/ServerSession.cs | 0 .../NativeInterop/TokenBindingUtil.cs | 0 .../NativeInterop/UrlGroup.cs | 0 .../Properties/AssemblyInfo.cs | 0 .../Properties/Resources.Designer.cs | 0 .../RequestProcessing/BoundaryType.cs | 0 .../RequestProcessing/ClientCertLoader.cs | 0 .../RequestProcessing/HttpReasonPhrase.cs | 0 .../RequestProcessing/OpaqueStream.cs | 0 .../RequestProcessing/Request.cs | 0 .../RequestProcessing/RequestContext.cs | 0 .../RequestHeaders.Generated.tt | 0 .../RequestProcessing/RequestStream.cs | 0 .../RequestStreamAsyncResult.cs | 0 .../RequestProcessing/Response.cs | 0 .../RequestProcessing/ResponseBody.cs | 0 .../ResponseStreamAsyncResult.cs | 0 .../Resources.resx | 0 .../ResponseStream.cs | 0 .../StandardFeatureCollection.cs | 0 .../TimeoutManager.cs | 0 .../UrlPrefix.cs | 0 .../UrlPrefixCollection.cs | 0 .../ValidationHelper.cs | 0 .../WebHostBuilderHttpSysExtensions.cs | 0 .../baseline.netcore.json | 0 .../HttpSysServer/test}/Directory.Build.props | 0 .../AuthenticationTests.cs | 0 .../DummyApplication.cs | 0 .../HttpsTests.cs | 0 .../Listener/RequestBodyTests.cs | 0 .../Listener/RequestHeaderTests.cs | 0 .../Listener/RequestTests.cs | 0 .../Listener/ResponseBodyTests.cs | 0 .../Listener/ResponseCachingTests.cs | 0 .../Listener/ResponseHeaderTests.cs | 0 .../Listener/ServerTests.cs | 0 .../Listener/Utilities.cs | 0 .../MessagePumpTests.cs | 0 ...Core.Server.HttpSys.FunctionalTests.csproj | 0 .../OSDontSkipConditionAttribute.cs | 0 .../OpaqueUpgradeTests.cs | 0 .../Properties/AssemblyInfo.cs | 0 .../RequestBodyLimitTests.cs | 0 .../RequestBodyTests.cs | 0 .../RequestHeaderTests.cs | 0 .../RequestTests.cs | 0 .../ResponseBodyTests.cs | 0 .../ResponseCachingTests.cs | 0 .../ResponseHeaderTests.cs | 0 .../ResponseSendFileTests.cs | 0 .../ResponseTests.cs | 0 .../ServerTests.cs | 0 .../Utilities.cs | 0 ...oft.AspNetCore.Server.HttpSys.Tests.csproj | 0 .../UrlPrefixTests.cs | 0 .../HttpSysServer/version.props | 0 139 files changed, 818 deletions(-) delete mode 100644 .appveyor.yml delete mode 100644 .gitattributes delete mode 100644 .travis.yml delete mode 100644 .vsts-pipelines/builds/ci-internal.yml delete mode 100644 .vsts-pipelines/builds/ci-public.yml delete mode 100644 CONTRIBUTING.md delete mode 100644 LICENSE.txt delete mode 100644 NuGet.config delete mode 100644 build.cmd delete mode 100755 build.sh delete mode 100644 korebuild-lock.txt delete mode 100644 korebuild.json delete mode 100644 run.cmd delete mode 100644 run.ps1 delete mode 100755 run.sh rename .gitignore => src/HttpSysServer/.gitignore (100%) rename Directory.Build.props => src/HttpSysServer/Directory.Build.props (100%) rename Directory.Build.targets => src/HttpSysServer/Directory.Build.targets (100%) rename HttpSysServer.sln => src/HttpSysServer/HttpSysServer.sln (100%) rename NuGetPackageVerifier.json => src/HttpSysServer/NuGetPackageVerifier.json (100%) rename README.md => src/HttpSysServer/README.md (100%) rename {build => src/HttpSysServer/build}/Key.snk (100%) rename {build => src/HttpSysServer/build}/dependencies.props (100%) rename {build => src/HttpSysServer/build}/repo.props (100%) rename {build => src/HttpSysServer/build}/sources.props (100%) rename {samples => src/HttpSysServer/samples}/HotAddSample/HotAddSample.csproj (100%) rename {samples => src/HttpSysServer/samples}/HotAddSample/Properties/launchSettings.json (100%) rename {samples => src/HttpSysServer/samples}/HotAddSample/Startup.cs (100%) rename {samples => src/HttpSysServer/samples}/SelfHostServer/App.config (100%) rename {samples => src/HttpSysServer/samples}/SelfHostServer/Properties/launchSettings.json (100%) rename {samples => src/HttpSysServer/samples}/SelfHostServer/Public/1kb.txt (100%) rename {samples => src/HttpSysServer/samples}/SelfHostServer/SelfHostServer.csproj (100%) rename {samples => src/HttpSysServer/samples}/SelfHostServer/Startup.cs (100%) rename {samples => src/HttpSysServer/samples}/TestClient/App.config (100%) rename {samples => src/HttpSysServer/samples}/TestClient/Program.cs (100%) rename {samples => src/HttpSysServer/samples}/TestClient/Properties/AssemblyInfo.cs (100%) rename {samples => src/HttpSysServer/samples}/TestClient/TestClient.csproj (100%) rename {shared => src/HttpSysServer/shared}/Microsoft.AspNetCore.HttpSys.Sources/Constants.cs (100%) rename {shared => src/HttpSysServer/shared}/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/CookedUrl.cs (100%) rename {shared => src/HttpSysServer/shared}/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/HeapAllocHandle.cs (100%) rename {shared => src/HttpSysServer/shared}/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/HttpApiTypes.cs (100%) rename {shared => src/HttpSysServer/shared}/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/HttpSysRequestHeader.cs (100%) rename {shared => src/HttpSysServer/shared}/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/HttpSysResponseHeader.cs (100%) rename {shared => src/HttpSysServer/shared}/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/NclUtilities.cs (100%) rename {shared => src/HttpSysServer/shared}/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/SafeLocalFreeChannelBinding.cs (100%) rename {shared => src/HttpSysServer/shared}/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/SafeLocalMemHandle.cs (100%) rename {shared => src/HttpSysServer/shared}/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/SafeNativeOverlapped.cs (100%) rename {shared => src/HttpSysServer/shared}/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/SocketAddress.cs (100%) rename {shared => src/HttpSysServer/shared}/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/UnsafeNativeMethods.cs (100%) rename {shared => src/HttpSysServer/shared}/Microsoft.AspNetCore.HttpSys.Sources/RequestProcessing/HeaderCollection.cs (100%) rename {shared => src/HttpSysServer/shared}/Microsoft.AspNetCore.HttpSys.Sources/RequestProcessing/HeaderEncoding.cs (100%) rename {shared => src/HttpSysServer/shared}/Microsoft.AspNetCore.HttpSys.Sources/RequestProcessing/HeaderParser.cs (100%) rename {shared => src/HttpSysServer/shared}/Microsoft.AspNetCore.HttpSys.Sources/RequestProcessing/HttpKnownHeaderNames.cs (100%) rename {shared => src/HttpSysServer/shared}/Microsoft.AspNetCore.HttpSys.Sources/RequestProcessing/NativeRequestContext.cs (100%) rename {shared => src/HttpSysServer/shared}/Microsoft.AspNetCore.HttpSys.Sources/RequestProcessing/RawUrlHelper.cs (100%) rename {shared => src/HttpSysServer/shared}/Microsoft.AspNetCore.HttpSys.Sources/RequestProcessing/RequestHeaders.Generated.cs (100%) rename {shared => src/HttpSysServer/shared}/Microsoft.AspNetCore.HttpSys.Sources/RequestProcessing/RequestHeaders.cs (100%) rename {shared => src/HttpSysServer/shared}/Microsoft.AspNetCore.HttpSys.Sources/RequestProcessing/RequestUriBuilder.cs (100%) rename {shared => src/HttpSysServer/shared}/Microsoft.AspNetCore.HttpSys.Sources/RequestProcessing/SslStatus.cs (100%) rename src/{ => HttpSysServer/src}/Directory.Build.props (100%) rename src/{ => HttpSysServer/src}/Microsoft.AspNetCore.Server.HttpSys/AsyncAcceptContext.cs (100%) rename src/{ => HttpSysServer/src}/Microsoft.AspNetCore.Server.HttpSys/AuthenticationHandler.cs (100%) rename src/{ => HttpSysServer/src}/Microsoft.AspNetCore.Server.HttpSys/AuthenticationManager.cs (100%) rename src/{ => HttpSysServer/src}/Microsoft.AspNetCore.Server.HttpSys/AuthenticationSchemes.cs (100%) rename src/{ => HttpSysServer/src}/Microsoft.AspNetCore.Server.HttpSys/FeatureContext.cs (100%) rename src/{ => HttpSysServer/src}/Microsoft.AspNetCore.Server.HttpSys/Helpers.cs (100%) rename src/{ => HttpSysServer/src}/Microsoft.AspNetCore.Server.HttpSys/Http503VerbosityLevel .cs (100%) rename src/{ => HttpSysServer/src}/Microsoft.AspNetCore.Server.HttpSys/HttpSysDefaults.cs (100%) rename src/{ => HttpSysServer/src}/Microsoft.AspNetCore.Server.HttpSys/HttpSysException.cs (100%) rename src/{ => HttpSysServer/src}/Microsoft.AspNetCore.Server.HttpSys/HttpSysListener.cs (100%) rename src/{ => HttpSysServer/src}/Microsoft.AspNetCore.Server.HttpSys/HttpSysOptions.cs (100%) rename src/{ => HttpSysServer/src}/Microsoft.AspNetCore.Server.HttpSys/LogHelper.cs (100%) rename src/{ => HttpSysServer/src}/Microsoft.AspNetCore.Server.HttpSys/MessagePump.cs (100%) rename src/{ => HttpSysServer/src}/Microsoft.AspNetCore.Server.HttpSys/Microsoft.AspNetCore.Server.HttpSys.csproj (100%) rename src/{ => HttpSysServer/src}/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/ComNetOS.cs (100%) rename src/{ => HttpSysServer/src}/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/DisconnectListener.cs (100%) rename src/{ => HttpSysServer/src}/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/HttpApi.cs (100%) rename src/{ => HttpSysServer/src}/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/HttpRequestQueueV2Handle.cs (100%) rename src/{ => HttpSysServer/src}/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/HttpServerSessionHandle.cs (100%) rename src/{ => HttpSysServer/src}/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/HttpSysSettings.cs (100%) rename src/{ => HttpSysServer/src}/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/IntPtrHelper.cs (100%) rename src/{ => HttpSysServer/src}/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/RequestQueue.cs (100%) rename src/{ => HttpSysServer/src}/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/ServerSession.cs (100%) rename src/{ => HttpSysServer/src}/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/TokenBindingUtil.cs (100%) rename src/{ => HttpSysServer/src}/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/UrlGroup.cs (100%) rename src/{ => HttpSysServer/src}/Microsoft.AspNetCore.Server.HttpSys/Properties/AssemblyInfo.cs (100%) rename src/{ => HttpSysServer/src}/Microsoft.AspNetCore.Server.HttpSys/Properties/Resources.Designer.cs (100%) rename src/{ => HttpSysServer/src}/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/BoundaryType.cs (100%) rename src/{ => HttpSysServer/src}/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/ClientCertLoader.cs (100%) rename src/{ => HttpSysServer/src}/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/HttpReasonPhrase.cs (100%) rename src/{ => HttpSysServer/src}/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/OpaqueStream.cs (100%) rename src/{ => HttpSysServer/src}/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/Request.cs (100%) rename src/{ => HttpSysServer/src}/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/RequestContext.cs (100%) rename src/{ => HttpSysServer/src}/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/RequestHeaders.Generated.tt (100%) rename src/{ => HttpSysServer/src}/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/RequestStream.cs (100%) rename src/{ => HttpSysServer/src}/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/RequestStreamAsyncResult.cs (100%) rename src/{ => HttpSysServer/src}/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/Response.cs (100%) rename src/{ => HttpSysServer/src}/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/ResponseBody.cs (100%) rename src/{ => HttpSysServer/src}/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/ResponseStreamAsyncResult.cs (100%) rename src/{ => HttpSysServer/src}/Microsoft.AspNetCore.Server.HttpSys/Resources.resx (100%) rename src/{ => HttpSysServer/src}/Microsoft.AspNetCore.Server.HttpSys/ResponseStream.cs (100%) rename src/{ => HttpSysServer/src}/Microsoft.AspNetCore.Server.HttpSys/StandardFeatureCollection.cs (100%) rename src/{ => HttpSysServer/src}/Microsoft.AspNetCore.Server.HttpSys/TimeoutManager.cs (100%) rename src/{ => HttpSysServer/src}/Microsoft.AspNetCore.Server.HttpSys/UrlPrefix.cs (100%) rename src/{ => HttpSysServer/src}/Microsoft.AspNetCore.Server.HttpSys/UrlPrefixCollection.cs (100%) rename src/{ => HttpSysServer/src}/Microsoft.AspNetCore.Server.HttpSys/ValidationHelper.cs (100%) rename src/{ => HttpSysServer/src}/Microsoft.AspNetCore.Server.HttpSys/WebHostBuilderHttpSysExtensions.cs (100%) rename src/{ => HttpSysServer/src}/Microsoft.AspNetCore.Server.HttpSys/baseline.netcore.json (100%) rename {test => src/HttpSysServer/test}/Directory.Build.props (100%) rename {test => src/HttpSysServer/test}/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/AuthenticationTests.cs (100%) rename {test => src/HttpSysServer/test}/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/DummyApplication.cs (100%) rename {test => src/HttpSysServer/test}/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/HttpsTests.cs (100%) rename {test => src/HttpSysServer/test}/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Listener/RequestBodyTests.cs (100%) rename {test => src/HttpSysServer/test}/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Listener/RequestHeaderTests.cs (100%) rename {test => src/HttpSysServer/test}/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Listener/RequestTests.cs (100%) rename {test => src/HttpSysServer/test}/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Listener/ResponseBodyTests.cs (100%) rename {test => src/HttpSysServer/test}/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Listener/ResponseCachingTests.cs (100%) rename {test => src/HttpSysServer/test}/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Listener/ResponseHeaderTests.cs (100%) rename {test => src/HttpSysServer/test}/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Listener/ServerTests.cs (100%) rename {test => src/HttpSysServer/test}/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Listener/Utilities.cs (100%) rename {test => src/HttpSysServer/test}/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/MessagePumpTests.cs (100%) rename {test => src/HttpSysServer/test}/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests.csproj (100%) rename {test => src/HttpSysServer/test}/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/OSDontSkipConditionAttribute.cs (100%) rename {test => src/HttpSysServer/test}/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/OpaqueUpgradeTests.cs (100%) rename {test => src/HttpSysServer/test}/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Properties/AssemblyInfo.cs (100%) rename {test => src/HttpSysServer/test}/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/RequestBodyLimitTests.cs (100%) rename {test => src/HttpSysServer/test}/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/RequestBodyTests.cs (100%) rename {test => src/HttpSysServer/test}/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/RequestHeaderTests.cs (100%) rename {test => src/HttpSysServer/test}/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/RequestTests.cs (100%) rename {test => src/HttpSysServer/test}/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/ResponseBodyTests.cs (100%) rename {test => src/HttpSysServer/test}/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/ResponseCachingTests.cs (100%) rename {test => src/HttpSysServer/test}/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/ResponseHeaderTests.cs (100%) rename {test => src/HttpSysServer/test}/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/ResponseSendFileTests.cs (100%) rename {test => src/HttpSysServer/test}/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/ResponseTests.cs (100%) rename {test => src/HttpSysServer/test}/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/ServerTests.cs (100%) rename {test => src/HttpSysServer/test}/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Utilities.cs (100%) rename {test => src/HttpSysServer/test}/Microsoft.AspNetCore.Server.HttpSys.Tests/Microsoft.AspNetCore.Server.HttpSys.Tests.csproj (100%) rename {test => src/HttpSysServer/test}/Microsoft.AspNetCore.Server.HttpSys.Tests/UrlPrefixTests.cs (100%) rename version.props => src/HttpSysServer/version.props (100%) diff --git a/.appveyor.yml b/.appveyor.yml deleted file mode 100644 index d45bd5a1f8..0000000000 --- a/.appveyor.yml +++ /dev/null @@ -1,17 +0,0 @@ -init: -- git config --global core.autocrlf true -branches: - only: - - master - - /^release\/.*$/ - - /^(.*\/)?ci-.*$/ -build_script: -- ps: .\run.ps1 default-build -clone_depth: 1 -environment: - global: - DOTNET_SKIP_FIRST_TIME_EXPERIENCE: true - DOTNET_CLI_TELEMETRY_OPTOUT: 1 -test: 'off' -deploy: 'off' -os: Visual Studio 2017 diff --git a/.gitattributes b/.gitattributes deleted file mode 100644 index 97b827b758..0000000000 --- a/.gitattributes +++ /dev/null @@ -1,51 +0,0 @@ -*.doc diff=astextplain -*.DOC diff=astextplain -*.docx diff=astextplain -*.DOCX diff=astextplain -*.dot diff=astextplain -*.DOT diff=astextplain -*.pdf diff=astextplain -*.PDF diff=astextplain -*.rtf diff=astextplain -*.RTF diff=astextplain - -*.jpg binary -*.png binary -*.gif binary - -*.cs text=auto diff=csharp -*.vb text=auto -*.resx text=auto -*.c text=auto -*.cpp text=auto -*.cxx text=auto -*.h text=auto -*.hxx text=auto -*.py text=auto -*.rb text=auto -*.java text=auto -*.html text=auto -*.htm text=auto -*.css text=auto -*.scss text=auto -*.sass text=auto -*.less text=auto -*.js text=auto -*.lisp text=auto -*.clj text=auto -*.sql text=auto -*.php text=auto -*.lua text=auto -*.m text=auto -*.asm text=auto -*.erl text=auto -*.fs text=auto -*.fsx text=auto -*.hs text=auto - -*.csproj text=auto -*.vbproj text=auto -*.fsproj text=auto -*.dbproj text=auto -*.sln text=auto eol=crlf -*.sh eol=lf diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index ab3980055c..0000000000 --- a/.travis.yml +++ /dev/null @@ -1,27 +0,0 @@ -language: csharp -sudo: false -dist: trusty -env: - global: - - DOTNET_SKIP_FIRST_TIME_EXPERIENCE: true - - DOTNET_CLI_TELEMETRY_OPTOUT: 1 -mono: none -os: -- linux -- osx -osx_image: xcode8.2 -addons: - apt: - packages: - - libunwind8 -branches: - only: - - master - - /^release\/.*$/ - - /^(.*\/)?ci-.*$/ -before_install: -- if test "$TRAVIS_OS_NAME" == "osx"; then brew update; brew install openssl; ln -s - /usr/local/opt/openssl/lib/libcrypto.1.0.0.dylib /usr/local/lib/; ln -s /usr/local/opt/openssl/lib/libssl.1.0.0.dylib - /usr/local/lib/; fi -script: -- ./build.sh diff --git a/.vsts-pipelines/builds/ci-internal.yml b/.vsts-pipelines/builds/ci-internal.yml deleted file mode 100644 index c2c5336fd0..0000000000 --- a/.vsts-pipelines/builds/ci-internal.yml +++ /dev/null @@ -1,13 +0,0 @@ -trigger: -- master -- release/* - -resources: - repositories: - - repository: buildtools - type: git - name: aspnet-BuildTools - ref: refs/heads/master - -phases: -- template: .vsts-pipelines/templates/project-ci.yml@buildtools diff --git a/.vsts-pipelines/builds/ci-public.yml b/.vsts-pipelines/builds/ci-public.yml deleted file mode 100644 index 507c89b025..0000000000 --- a/.vsts-pipelines/builds/ci-public.yml +++ /dev/null @@ -1,15 +0,0 @@ -trigger: -- master -- release/* - -# See https://github.com/aspnet/BuildTools -resources: - repositories: - - repository: buildtools - type: github - endpoint: DotNet-Bot GitHub Connection - name: aspnet/BuildTools - ref: refs/heads/master - -phases: -- template: .vsts-pipelines/templates/project-ci.yml@buildtools diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md deleted file mode 100644 index eac4268e4c..0000000000 --- a/CONTRIBUTING.md +++ /dev/null @@ -1,4 +0,0 @@ -Contributing -====== - -Information on contributing to this repo is in the [Contributing Guide](https://github.com/aspnet/Home/blob/master/CONTRIBUTING.md) in the Home repo. diff --git a/LICENSE.txt b/LICENSE.txt deleted file mode 100644 index b3b180cd51..0000000000 --- a/LICENSE.txt +++ /dev/null @@ -1,201 +0,0 @@ - Apache License - Version 2.0, January 2004 - http://www.apache.org/licenses/ - - TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION - - 1. Definitions. - - "License" shall mean the terms and conditions for use, reproduction, - and distribution as defined by Sections 1 through 9 of this document. - - "Licensor" shall mean the copyright owner or entity authorized by - the copyright owner that is granting the License. - - "Legal Entity" shall mean the union of the acting entity and all - other entities that control, are controlled by, or are under common - control with that entity. For the purposes of this definition, - "control" means (i) the power, direct or indirect, to cause the - direction or management of such entity, whether by contract or - otherwise, or (ii) ownership of fifty percent (50%) or more of the - outstanding shares, or (iii) beneficial ownership of such entity. - - "You" (or "Your") shall mean an individual or Legal Entity - exercising permissions granted by this License. - - "Source" form shall mean the preferred form for making modifications, - including but not limited to software source code, documentation - source, and configuration files. - - "Object" form shall mean any form resulting from mechanical - transformation or translation of a Source form, including but - not limited to compiled object code, generated documentation, - and conversions to other media types. - - "Work" shall mean the work of authorship, whether in Source or - Object form, made available under the License, as indicated by a - copyright notice that is included in or attached to the work - (an example is provided in the Appendix below). - - "Derivative Works" shall mean any work, whether in Source or Object - form, that is based on (or derived from) the Work and for which the - editorial revisions, annotations, elaborations, or other modifications - represent, as a whole, an original work of authorship. For the purposes - of this License, Derivative Works shall not include works that remain - separable from, or merely link (or bind by name) to the interfaces of, - the Work and Derivative Works thereof. - - "Contribution" shall mean any work of authorship, including - the original version of the Work and any modifications or additions - to that Work or Derivative Works thereof, that is intentionally - submitted to Licensor for inclusion in the Work by the copyright owner - or by an individual or Legal Entity authorized to submit on behalf of - the copyright owner. For the purposes of this definition, "submitted" - means any form of electronic, verbal, or written communication sent - to the Licensor or its representatives, including but not limited to - communication on electronic mailing lists, source code control systems, - and issue tracking systems that are managed by, or on behalf of, the - Licensor for the purpose of discussing and improving the Work, but - excluding communication that is conspicuously marked or otherwise - designated in writing by the copyright owner as "Not a Contribution." - - "Contributor" shall mean Licensor and any individual or Legal Entity - on behalf of whom a Contribution has been received by Licensor and - subsequently incorporated within the Work. - - 2. Grant of Copyright License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - copyright license to reproduce, prepare Derivative Works of, - publicly display, publicly perform, sublicense, and distribute the - Work and such Derivative Works in Source or Object form. - - 3. Grant of Patent License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - (except as stated in this section) patent license to make, have made, - use, offer to sell, sell, import, and otherwise transfer the Work, - where such license applies only to those patent claims licensable - by such Contributor that are necessarily infringed by their - Contribution(s) alone or by combination of their Contribution(s) - with the Work to which such Contribution(s) was submitted. If You - institute patent litigation against any entity (including a - cross-claim or counterclaim in a lawsuit) alleging that the Work - or a Contribution incorporated within the Work constitutes direct - or contributory patent infringement, then any patent licenses - granted to You under this License for that Work shall terminate - as of the date such litigation is filed. - - 4. Redistribution. You may reproduce and distribute copies of the - Work or Derivative Works thereof in any medium, with or without - modifications, and in Source or Object form, provided that You - meet the following conditions: - - (a) You must give any other recipients of the Work or - Derivative Works a copy of this License; and - - (b) You must cause any modified files to carry prominent notices - stating that You changed the files; and - - (c) You must retain, in the Source form of any Derivative Works - that You distribute, all copyright, patent, trademark, and - attribution notices from the Source form of the Work, - excluding those notices that do not pertain to any part of - the Derivative Works; and - - (d) If the Work includes a "NOTICE" text file as part of its - distribution, then any Derivative Works that You distribute must - include a readable copy of the attribution notices contained - within such NOTICE file, excluding those notices that do not - pertain to any part of the Derivative Works, in at least one - of the following places: within a NOTICE text file distributed - as part of the Derivative Works; within the Source form or - documentation, if provided along with the Derivative Works; or, - within a display generated by the Derivative Works, if and - wherever such third-party notices normally appear. The contents - of the NOTICE file are for informational purposes only and - do not modify the License. You may add Your own attribution - notices within Derivative Works that You distribute, alongside - or as an addendum to the NOTICE text from the Work, provided - that such additional attribution notices cannot be construed - as modifying the License. - - You may add Your own copyright statement to Your modifications and - may provide additional or different license terms and conditions - for use, reproduction, or distribution of Your modifications, or - for any such Derivative Works as a whole, provided Your use, - reproduction, and distribution of the Work otherwise complies with - the conditions stated in this License. - - 5. Submission of Contributions. Unless You explicitly state otherwise, - any Contribution intentionally submitted for inclusion in the Work - by You to the Licensor shall be under the terms and conditions of - this License, without any additional terms or conditions. - Notwithstanding the above, nothing herein shall supersede or modify - the terms of any separate license agreement you may have executed - with Licensor regarding such Contributions. - - 6. Trademarks. This License does not grant permission to use the trade - names, trademarks, service marks, or product names of the Licensor, - except as required for reasonable and customary use in describing the - origin of the Work and reproducing the content of the NOTICE file. - - 7. Disclaimer of Warranty. Unless required by applicable law or - agreed to in writing, Licensor provides the Work (and each - Contributor provides its Contributions) on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or - implied, including, without limitation, any warranties or conditions - of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A - PARTICULAR PURPOSE. You are solely responsible for determining the - appropriateness of using or redistributing the Work and assume any - risks associated with Your exercise of permissions under this License. - - 8. Limitation of Liability. In no event and under no legal theory, - whether in tort (including negligence), contract, or otherwise, - unless required by applicable law (such as deliberate and grossly - negligent acts) or agreed to in writing, shall any Contributor be - liable to You for damages, including any direct, indirect, special, - incidental, or consequential damages of any character arising as a - result of this License or out of the use or inability to use the - Work (including but not limited to damages for loss of goodwill, - work stoppage, computer failure or malfunction, or any and all - other commercial damages or losses), even if such Contributor - has been advised of the possibility of such damages. - - 9. Accepting Warranty or Additional Liability. While redistributing - the Work or Derivative Works thereof, You may choose to offer, - and charge a fee for, acceptance of support, warranty, indemnity, - or other liability obligations and/or rights consistent with this - License. However, in accepting such obligations, You may act only - on Your own behalf and on Your sole responsibility, not on behalf - of any other Contributor, and only if You agree to indemnify, - defend, and hold each Contributor harmless for any liability - incurred by, or claims asserted against, such Contributor by reason - of your accepting any such warranty or additional liability. - - END OF TERMS AND CONDITIONS - - APPENDIX: How to apply the Apache License to your work. - - To apply the Apache License to your work, attach the following - boilerplate notice, with the fields enclosed by brackets "[]" - replaced with your own identifying information. (Don't include - the brackets!) The text should be enclosed in the appropriate - comment syntax for the file format. We also recommend that a - file or class name and description of purpose be included on the - same "printed page" as the copyright notice for easier - identification within third-party archives. - - Copyright (c) .NET Foundation and Contributors - - Licensed under the Apache License, Version 2.0 (the "License"); - you may not use this file except in compliance with the License. - You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. diff --git a/NuGet.config b/NuGet.config deleted file mode 100644 index e32bddfd51..0000000000 --- a/NuGet.config +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/build.cmd b/build.cmd deleted file mode 100644 index c0050bda12..0000000000 --- a/build.cmd +++ /dev/null @@ -1,2 +0,0 @@ -@ECHO OFF -PowerShell -NoProfile -NoLogo -ExecutionPolicy unrestricted -Command "[System.Threading.Thread]::CurrentThread.CurrentCulture = ''; [System.Threading.Thread]::CurrentThread.CurrentUICulture = '';& '%~dp0run.ps1' default-build %*; exit $LASTEXITCODE" diff --git a/build.sh b/build.sh deleted file mode 100755 index 98a4b22765..0000000000 --- a/build.sh +++ /dev/null @@ -1,8 +0,0 @@ -#!/usr/bin/env bash - -set -euo pipefail -DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" - -# Call "sync" between "chmod" and execution to prevent "text file busy" error in Docker (aufs) -chmod +x "$DIR/run.sh"; sync -"$DIR/run.sh" default-build "$@" diff --git a/korebuild-lock.txt b/korebuild-lock.txt deleted file mode 100644 index f7d4e37b32..0000000000 --- a/korebuild-lock.txt +++ /dev/null @@ -1,2 +0,0 @@ -version:3.0.0-alpha1-20181011.3 -commithash:e7569d931e994629267ab2646e9926140962b4ac diff --git a/korebuild.json b/korebuild.json deleted file mode 100644 index 8a276a7f35..0000000000 --- a/korebuild.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "$schema": "https://raw.githubusercontent.com/aspnet/BuildTools/master/tools/korebuild.schema.json", - "channel": "master" -} diff --git a/run.cmd b/run.cmd deleted file mode 100644 index d52d5c7e68..0000000000 --- a/run.cmd +++ /dev/null @@ -1,2 +0,0 @@ -@ECHO OFF -PowerShell -NoProfile -NoLogo -ExecutionPolicy unrestricted -Command "[System.Threading.Thread]::CurrentThread.CurrentCulture = ''; [System.Threading.Thread]::CurrentThread.CurrentUICulture = '';& '%~dp0run.ps1' %*; exit $LASTEXITCODE" diff --git a/run.ps1 b/run.ps1 deleted file mode 100644 index 34604c7175..0000000000 --- a/run.ps1 +++ /dev/null @@ -1,209 +0,0 @@ -#!/usr/bin/env powershell -#requires -version 4 - -<# -.SYNOPSIS -Executes KoreBuild commands. - -.DESCRIPTION -Downloads korebuild if required. Then executes the KoreBuild command. To see available commands, execute with `-Command help`. - -.PARAMETER Command -The KoreBuild command to run. - -.PARAMETER Path -The folder to build. Defaults to the folder containing this script. - -.PARAMETER Channel -The channel of KoreBuild to download. Overrides the value from the config file. - -.PARAMETER DotNetHome -The directory where .NET Core tools will be stored. - -.PARAMETER ToolsSource -The base url where build tools can be downloaded. Overrides the value from the config file. - -.PARAMETER Update -Updates KoreBuild to the latest version even if a lock file is present. - -.PARAMETER Reinstall -Re-installs KoreBuild - -.PARAMETER ConfigFile -The path to the configuration file that stores values. Defaults to korebuild.json. - -.PARAMETER ToolsSourceSuffix -The Suffix to append to the end of the ToolsSource. Useful for query strings in blob stores. - -.PARAMETER CI -Sets up CI specific settings and variables. - -.PARAMETER Arguments -Arguments to be passed to the command - -.NOTES -This function will create a file $PSScriptRoot/korebuild-lock.txt. This lock file can be committed to source, but does not have to be. -When the lockfile is not present, KoreBuild will create one using latest available version from $Channel. - -The $ConfigFile is expected to be an JSON file. It is optional, and the configuration values in it are optional as well. Any options set -in the file are overridden by command line parameters. - -.EXAMPLE -Example config file: -```json -{ - "$schema": "https://raw.githubusercontent.com/aspnet/BuildTools/master/tools/korebuild.schema.json", - "channel": "master", - "toolsSource": "https://aspnetcore.blob.core.windows.net/buildtools" -} -``` -#> -[CmdletBinding(PositionalBinding = $false)] -param( - [Parameter(Mandatory = $true, Position = 0)] - [string]$Command, - [string]$Path = $PSScriptRoot, - [Alias('c')] - [string]$Channel, - [Alias('d')] - [string]$DotNetHome, - [Alias('s')] - [string]$ToolsSource, - [Alias('u')] - [switch]$Update, - [switch]$Reinstall, - [string]$ToolsSourceSuffix, - [string]$ConfigFile = $null, - [switch]$CI, - [Parameter(ValueFromRemainingArguments = $true)] - [string[]]$Arguments -) - -Set-StrictMode -Version 2 -$ErrorActionPreference = 'Stop' - -# -# Functions -# - -function Get-KoreBuild { - - $lockFile = Join-Path $Path 'korebuild-lock.txt' - - if (!(Test-Path $lockFile) -or $Update) { - Get-RemoteFile "$ToolsSource/korebuild/channels/$Channel/latest.txt" $lockFile $ToolsSourceSuffix - } - - $version = Get-Content $lockFile | Where-Object { $_ -like 'version:*' } | Select-Object -first 1 - if (!$version) { - Write-Error "Failed to parse version from $lockFile. Expected a line that begins with 'version:'" - } - $version = $version.TrimStart('version:').Trim() - $korebuildPath = Join-Paths $DotNetHome ('buildtools', 'korebuild', $version) - - if ($Reinstall -and (Test-Path $korebuildPath)) { - Remove-Item -Force -Recurse $korebuildPath - } - - if (!(Test-Path $korebuildPath)) { - Write-Host -ForegroundColor Magenta "Downloading KoreBuild $version" - New-Item -ItemType Directory -Path $korebuildPath | Out-Null - $remotePath = "$ToolsSource/korebuild/artifacts/$version/korebuild.$version.zip" - - try { - $tmpfile = Join-Path ([IO.Path]::GetTempPath()) "KoreBuild-$([guid]::NewGuid()).zip" - Get-RemoteFile $remotePath $tmpfile $ToolsSourceSuffix - if (Get-Command -Name 'Microsoft.PowerShell.Archive\Expand-Archive' -ErrorAction Ignore) { - # Use built-in commands where possible as they are cross-plat compatible - Microsoft.PowerShell.Archive\Expand-Archive -Path $tmpfile -DestinationPath $korebuildPath - } - else { - # Fallback to old approach for old installations of PowerShell - Add-Type -AssemblyName System.IO.Compression.FileSystem - [System.IO.Compression.ZipFile]::ExtractToDirectory($tmpfile, $korebuildPath) - } - } - catch { - Remove-Item -Recurse -Force $korebuildPath -ErrorAction Ignore - throw - } - finally { - Remove-Item $tmpfile -ErrorAction Ignore - } - } - - return $korebuildPath -} - -function Join-Paths([string]$path, [string[]]$childPaths) { - $childPaths | ForEach-Object { $path = Join-Path $path $_ } - return $path -} - -function Get-RemoteFile([string]$RemotePath, [string]$LocalPath, [string]$RemoteSuffix) { - if ($RemotePath -notlike 'http*') { - Copy-Item $RemotePath $LocalPath - return - } - - $retries = 10 - while ($retries -gt 0) { - $retries -= 1 - try { - Invoke-WebRequest -UseBasicParsing -Uri $($RemotePath + $RemoteSuffix) -OutFile $LocalPath - return - } - catch { - Write-Verbose "Request failed. $retries retries remaining" - } - } - - Write-Error "Download failed: '$RemotePath'." -} - -# -# Main -# - -# Load configuration or set defaults - -$Path = Resolve-Path $Path -if (!$ConfigFile) { $ConfigFile = Join-Path $Path 'korebuild.json' } - -if (Test-Path $ConfigFile) { - try { - $config = Get-Content -Raw -Encoding UTF8 -Path $ConfigFile | ConvertFrom-Json - if ($config) { - if (!($Channel) -and (Get-Member -Name 'channel' -InputObject $config)) { [string] $Channel = $config.channel } - if (!($ToolsSource) -and (Get-Member -Name 'toolsSource' -InputObject $config)) { [string] $ToolsSource = $config.toolsSource} - } - } - catch { - Write-Host -ForegroundColor Red $Error[0] - Write-Error "$ConfigFile contains invalid JSON." - exit 1 - } -} - -if (!$DotNetHome) { - $DotNetHome = if ($env:DOTNET_HOME) { $env:DOTNET_HOME } ` - elseif ($env:USERPROFILE) { Join-Path $env:USERPROFILE '.dotnet'} ` - elseif ($env:HOME) {Join-Path $env:HOME '.dotnet'}` - else { Join-Path $PSScriptRoot '.dotnet'} -} - -if (!$Channel) { $Channel = 'master' } -if (!$ToolsSource) { $ToolsSource = 'https://aspnetcore.blob.core.windows.net/buildtools' } - -# Execute - -$korebuildPath = Get-KoreBuild -Import-Module -Force -Scope Local (Join-Path $korebuildPath 'KoreBuild.psd1') - -try { - Set-KoreBuildSettings -ToolsSource $ToolsSource -DotNetHome $DotNetHome -RepoPath $Path -ConfigFile $ConfigFile -CI:$CI - Invoke-KoreBuildCommand $Command @Arguments -} -finally { - Remove-Module 'KoreBuild' -ErrorAction Ignore -} diff --git a/run.sh b/run.sh deleted file mode 100755 index 4c1fed5646..0000000000 --- a/run.sh +++ /dev/null @@ -1,256 +0,0 @@ -#!/usr/bin/env bash - -set -euo pipefail - -# -# variables -# - -RESET="\033[0m" -RED="\033[0;31m" -YELLOW="\033[0;33m" -MAGENTA="\033[0;95m" -DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" -[ -z "${DOTNET_HOME:-}" ] && DOTNET_HOME="$HOME/.dotnet" -verbose=false -update=false -reinstall=false -repo_path="$DIR" -channel='' -tools_source='' -tools_source_suffix='' -ci=false - -# -# Functions -# -__usage() { - echo "Usage: $(basename "${BASH_SOURCE[0]}") command [options] [[--] ...]" - echo "" - echo "Arguments:" - echo " command The command to be run." - echo " ... Arguments passed to the command. Variable number of arguments allowed." - echo "" - echo "Options:" - echo " --verbose Show verbose output." - echo " -c|--channel The channel of KoreBuild to download. Overrides the value from the config file.." - echo " --config-file The path to the configuration file that stores values. Defaults to korebuild.json." - echo " -d|--dotnet-home The directory where .NET Core tools will be stored. Defaults to '\$DOTNET_HOME' or '\$HOME/.dotnet." - echo " --path The directory to build. Defaults to the directory containing the script." - echo " -s|--tools-source|-ToolsSource The base url where build tools can be downloaded. Overrides the value from the config file." - echo " --tools-source-suffix|-ToolsSourceSuffix The suffix to append to tools-source. Useful for query strings." - echo " -u|--update Update to the latest KoreBuild even if the lock file is present." - echo " --reinstall Reinstall KoreBuild." - echo " --ci Apply CI specific settings and environment variables." - echo "" - echo "Description:" - echo " This function will create a file \$DIR/korebuild-lock.txt. This lock file can be committed to source, but does not have to be." - echo " When the lockfile is not present, KoreBuild will create one using latest available version from \$channel." - - if [[ "${1:-}" != '--no-exit' ]]; then - exit 2 - fi -} - -get_korebuild() { - local version - local lock_file="$repo_path/korebuild-lock.txt" - if [ ! -f "$lock_file" ] || [ "$update" = true ]; then - __get_remote_file "$tools_source/korebuild/channels/$channel/latest.txt" "$lock_file" "$tools_source_suffix" - fi - version="$(grep 'version:*' -m 1 "$lock_file")" - if [[ "$version" == '' ]]; then - __error "Failed to parse version from $lock_file. Expected a line that begins with 'version:'" - return 1 - fi - version="$(echo "${version#version:}" | sed -e 's/^[[:space:]]*//' -e 's/[[:space:]]*$//')" - local korebuild_path="$DOTNET_HOME/buildtools/korebuild/$version" - - if [ "$reinstall" = true ] && [ -d "$korebuild_path" ]; then - rm -rf "$korebuild_path" - fi - - { - if [ ! -d "$korebuild_path" ]; then - mkdir -p "$korebuild_path" - local remote_path="$tools_source/korebuild/artifacts/$version/korebuild.$version.zip" - tmpfile="$(mktemp)" - echo -e "${MAGENTA}Downloading KoreBuild ${version}${RESET}" - if __get_remote_file "$remote_path" "$tmpfile" "$tools_source_suffix"; then - unzip -q -d "$korebuild_path" "$tmpfile" - fi - rm "$tmpfile" || true - fi - - source "$korebuild_path/KoreBuild.sh" - } || { - if [ -d "$korebuild_path" ]; then - echo "Cleaning up after failed installation" - rm -rf "$korebuild_path" || true - fi - return 1 - } -} - -__error() { - echo -e "${RED}error: $*${RESET}" 1>&2 -} - -__warn() { - echo -e "${YELLOW}warning: $*${RESET}" -} - -__machine_has() { - hash "$1" > /dev/null 2>&1 - return $? -} - -__get_remote_file() { - local remote_path=$1 - local local_path=$2 - local remote_path_suffix=$3 - - if [[ "$remote_path" != 'http'* ]]; then - cp "$remote_path" "$local_path" - return 0 - fi - - local failed=false - if __machine_has wget; then - wget --tries 10 --quiet -O "$local_path" "${remote_path}${remote_path_suffix}" || failed=true - else - failed=true - fi - - if [ "$failed" = true ] && __machine_has curl; then - failed=false - curl --retry 10 -sSL -f --create-dirs -o "$local_path" "${remote_path}${remote_path_suffix}" || failed=true - fi - - if [ "$failed" = true ]; then - __error "Download failed: $remote_path" 1>&2 - return 1 - fi -} - -# -# main -# - -command="${1:-}" -shift - -while [[ $# -gt 0 ]]; do - case $1 in - -\?|-h|--help) - __usage --no-exit - exit 0 - ;; - -c|--channel|-Channel) - shift - channel="${1:-}" - [ -z "$channel" ] && __usage - ;; - --config-file|-ConfigFile) - shift - config_file="${1:-}" - [ -z "$config_file" ] && __usage - if [ ! -f "$config_file" ]; then - __error "Invalid value for --config-file. $config_file does not exist." - exit 1 - fi - ;; - -d|--dotnet-home|-DotNetHome) - shift - DOTNET_HOME="${1:-}" - [ -z "$DOTNET_HOME" ] && __usage - ;; - --path|-Path) - shift - repo_path="${1:-}" - [ -z "$repo_path" ] && __usage - ;; - -s|--tools-source|-ToolsSource) - shift - tools_source="${1:-}" - [ -z "$tools_source" ] && __usage - ;; - --tools-source-suffix|-ToolsSourceSuffix) - shift - tools_source_suffix="${1:-}" - [ -z "$tools_source_suffix" ] && __usage - ;; - -u|--update|-Update) - update=true - ;; - --reinstall|-[Rr]einstall) - reinstall=true - ;; - --ci|-[Cc][Ii]) - ci=true - ;; - --verbose|-Verbose) - verbose=true - ;; - --) - shift - break - ;; - *) - break - ;; - esac - shift -done - -if ! __machine_has unzip; then - __error 'Missing required command: unzip' - exit 1 -fi - -if ! __machine_has curl && ! __machine_has wget; then - __error 'Missing required command. Either wget or curl is required.' - exit 1 -fi - -[ -z "${config_file:-}" ] && config_file="$repo_path/korebuild.json" -if [ -f "$config_file" ]; then - if __machine_has jq ; then - if jq '.' "$config_file" >/dev/null ; then - config_channel="$(jq -r 'select(.channel!=null) | .channel' "$config_file")" - config_tools_source="$(jq -r 'select(.toolsSource!=null) | .toolsSource' "$config_file")" - else - __error "$config_file contains invalid JSON." - exit 1 - fi - elif __machine_has python ; then - if python -c "import json,codecs;obj=json.load(codecs.open('$config_file', 'r', 'utf-8-sig'))" >/dev/null ; then - config_channel="$(python -c "import json,codecs;obj=json.load(codecs.open('$config_file', 'r', 'utf-8-sig'));print(obj['channel'] if 'channel' in obj else '')")" - config_tools_source="$(python -c "import json,codecs;obj=json.load(codecs.open('$config_file', 'r', 'utf-8-sig'));print(obj['toolsSource'] if 'toolsSource' in obj else '')")" - else - __error "$config_file contains invalid JSON." - exit 1 - fi - elif __machine_has python3 ; then - if python3 -c "import json,codecs;obj=json.load(codecs.open('$config_file', 'r', 'utf-8-sig'))" >/dev/null ; then - config_channel="$(python3 -c "import json,codecs;obj=json.load(codecs.open('$config_file', 'r', 'utf-8-sig'));print(obj['channel'] if 'channel' in obj else '')")" - config_tools_source="$(python3 -c "import json,codecs;obj=json.load(codecs.open('$config_file', 'r', 'utf-8-sig'));print(obj['toolsSource'] if 'toolsSource' in obj else '')")" - else - __error "$config_file contains invalid JSON." - exit 1 - fi - else - __error 'Missing required command: jq or python. Could not parse the JSON file.' - exit 1 - fi - - [ ! -z "${config_channel:-}" ] && channel="$config_channel" - [ ! -z "${config_tools_source:-}" ] && tools_source="$config_tools_source" -fi - -[ -z "$channel" ] && channel='master' -[ -z "$tools_source" ] && tools_source='https://aspnetcore.blob.core.windows.net/buildtools' - -get_korebuild -set_korebuildsettings "$tools_source" "$DOTNET_HOME" "$repo_path" "$config_file" "$ci" -invoke_korebuild_command "$command" "$@" diff --git a/.gitignore b/src/HttpSysServer/.gitignore similarity index 100% rename from .gitignore rename to src/HttpSysServer/.gitignore diff --git a/Directory.Build.props b/src/HttpSysServer/Directory.Build.props similarity index 100% rename from Directory.Build.props rename to src/HttpSysServer/Directory.Build.props diff --git a/Directory.Build.targets b/src/HttpSysServer/Directory.Build.targets similarity index 100% rename from Directory.Build.targets rename to src/HttpSysServer/Directory.Build.targets diff --git a/HttpSysServer.sln b/src/HttpSysServer/HttpSysServer.sln similarity index 100% rename from HttpSysServer.sln rename to src/HttpSysServer/HttpSysServer.sln diff --git a/NuGetPackageVerifier.json b/src/HttpSysServer/NuGetPackageVerifier.json similarity index 100% rename from NuGetPackageVerifier.json rename to src/HttpSysServer/NuGetPackageVerifier.json diff --git a/README.md b/src/HttpSysServer/README.md similarity index 100% rename from README.md rename to src/HttpSysServer/README.md diff --git a/build/Key.snk b/src/HttpSysServer/build/Key.snk similarity index 100% rename from build/Key.snk rename to src/HttpSysServer/build/Key.snk diff --git a/build/dependencies.props b/src/HttpSysServer/build/dependencies.props similarity index 100% rename from build/dependencies.props rename to src/HttpSysServer/build/dependencies.props diff --git a/build/repo.props b/src/HttpSysServer/build/repo.props similarity index 100% rename from build/repo.props rename to src/HttpSysServer/build/repo.props diff --git a/build/sources.props b/src/HttpSysServer/build/sources.props similarity index 100% rename from build/sources.props rename to src/HttpSysServer/build/sources.props diff --git a/samples/HotAddSample/HotAddSample.csproj b/src/HttpSysServer/samples/HotAddSample/HotAddSample.csproj similarity index 100% rename from samples/HotAddSample/HotAddSample.csproj rename to src/HttpSysServer/samples/HotAddSample/HotAddSample.csproj diff --git a/samples/HotAddSample/Properties/launchSettings.json b/src/HttpSysServer/samples/HotAddSample/Properties/launchSettings.json similarity index 100% rename from samples/HotAddSample/Properties/launchSettings.json rename to src/HttpSysServer/samples/HotAddSample/Properties/launchSettings.json diff --git a/samples/HotAddSample/Startup.cs b/src/HttpSysServer/samples/HotAddSample/Startup.cs similarity index 100% rename from samples/HotAddSample/Startup.cs rename to src/HttpSysServer/samples/HotAddSample/Startup.cs diff --git a/samples/SelfHostServer/App.config b/src/HttpSysServer/samples/SelfHostServer/App.config similarity index 100% rename from samples/SelfHostServer/App.config rename to src/HttpSysServer/samples/SelfHostServer/App.config diff --git a/samples/SelfHostServer/Properties/launchSettings.json b/src/HttpSysServer/samples/SelfHostServer/Properties/launchSettings.json similarity index 100% rename from samples/SelfHostServer/Properties/launchSettings.json rename to src/HttpSysServer/samples/SelfHostServer/Properties/launchSettings.json diff --git a/samples/SelfHostServer/Public/1kb.txt b/src/HttpSysServer/samples/SelfHostServer/Public/1kb.txt similarity index 100% rename from samples/SelfHostServer/Public/1kb.txt rename to src/HttpSysServer/samples/SelfHostServer/Public/1kb.txt diff --git a/samples/SelfHostServer/SelfHostServer.csproj b/src/HttpSysServer/samples/SelfHostServer/SelfHostServer.csproj similarity index 100% rename from samples/SelfHostServer/SelfHostServer.csproj rename to src/HttpSysServer/samples/SelfHostServer/SelfHostServer.csproj diff --git a/samples/SelfHostServer/Startup.cs b/src/HttpSysServer/samples/SelfHostServer/Startup.cs similarity index 100% rename from samples/SelfHostServer/Startup.cs rename to src/HttpSysServer/samples/SelfHostServer/Startup.cs diff --git a/samples/TestClient/App.config b/src/HttpSysServer/samples/TestClient/App.config similarity index 100% rename from samples/TestClient/App.config rename to src/HttpSysServer/samples/TestClient/App.config diff --git a/samples/TestClient/Program.cs b/src/HttpSysServer/samples/TestClient/Program.cs similarity index 100% rename from samples/TestClient/Program.cs rename to src/HttpSysServer/samples/TestClient/Program.cs diff --git a/samples/TestClient/Properties/AssemblyInfo.cs b/src/HttpSysServer/samples/TestClient/Properties/AssemblyInfo.cs similarity index 100% rename from samples/TestClient/Properties/AssemblyInfo.cs rename to src/HttpSysServer/samples/TestClient/Properties/AssemblyInfo.cs diff --git a/samples/TestClient/TestClient.csproj b/src/HttpSysServer/samples/TestClient/TestClient.csproj similarity index 100% rename from samples/TestClient/TestClient.csproj rename to src/HttpSysServer/samples/TestClient/TestClient.csproj diff --git a/shared/Microsoft.AspNetCore.HttpSys.Sources/Constants.cs b/src/HttpSysServer/shared/Microsoft.AspNetCore.HttpSys.Sources/Constants.cs similarity index 100% rename from shared/Microsoft.AspNetCore.HttpSys.Sources/Constants.cs rename to src/HttpSysServer/shared/Microsoft.AspNetCore.HttpSys.Sources/Constants.cs diff --git a/shared/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/CookedUrl.cs b/src/HttpSysServer/shared/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/CookedUrl.cs similarity index 100% rename from shared/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/CookedUrl.cs rename to src/HttpSysServer/shared/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/CookedUrl.cs diff --git a/shared/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/HeapAllocHandle.cs b/src/HttpSysServer/shared/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/HeapAllocHandle.cs similarity index 100% rename from shared/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/HeapAllocHandle.cs rename to src/HttpSysServer/shared/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/HeapAllocHandle.cs diff --git a/shared/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/HttpApiTypes.cs b/src/HttpSysServer/shared/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/HttpApiTypes.cs similarity index 100% rename from shared/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/HttpApiTypes.cs rename to src/HttpSysServer/shared/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/HttpApiTypes.cs diff --git a/shared/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/HttpSysRequestHeader.cs b/src/HttpSysServer/shared/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/HttpSysRequestHeader.cs similarity index 100% rename from shared/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/HttpSysRequestHeader.cs rename to src/HttpSysServer/shared/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/HttpSysRequestHeader.cs diff --git a/shared/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/HttpSysResponseHeader.cs b/src/HttpSysServer/shared/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/HttpSysResponseHeader.cs similarity index 100% rename from shared/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/HttpSysResponseHeader.cs rename to src/HttpSysServer/shared/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/HttpSysResponseHeader.cs diff --git a/shared/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/NclUtilities.cs b/src/HttpSysServer/shared/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/NclUtilities.cs similarity index 100% rename from shared/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/NclUtilities.cs rename to src/HttpSysServer/shared/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/NclUtilities.cs diff --git a/shared/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/SafeLocalFreeChannelBinding.cs b/src/HttpSysServer/shared/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/SafeLocalFreeChannelBinding.cs similarity index 100% rename from shared/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/SafeLocalFreeChannelBinding.cs rename to src/HttpSysServer/shared/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/SafeLocalFreeChannelBinding.cs diff --git a/shared/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/SafeLocalMemHandle.cs b/src/HttpSysServer/shared/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/SafeLocalMemHandle.cs similarity index 100% rename from shared/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/SafeLocalMemHandle.cs rename to src/HttpSysServer/shared/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/SafeLocalMemHandle.cs diff --git a/shared/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/SafeNativeOverlapped.cs b/src/HttpSysServer/shared/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/SafeNativeOverlapped.cs similarity index 100% rename from shared/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/SafeNativeOverlapped.cs rename to src/HttpSysServer/shared/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/SafeNativeOverlapped.cs diff --git a/shared/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/SocketAddress.cs b/src/HttpSysServer/shared/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/SocketAddress.cs similarity index 100% rename from shared/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/SocketAddress.cs rename to src/HttpSysServer/shared/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/SocketAddress.cs diff --git a/shared/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/UnsafeNativeMethods.cs b/src/HttpSysServer/shared/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/UnsafeNativeMethods.cs similarity index 100% rename from shared/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/UnsafeNativeMethods.cs rename to src/HttpSysServer/shared/Microsoft.AspNetCore.HttpSys.Sources/NativeInterop/UnsafeNativeMethods.cs diff --git a/shared/Microsoft.AspNetCore.HttpSys.Sources/RequestProcessing/HeaderCollection.cs b/src/HttpSysServer/shared/Microsoft.AspNetCore.HttpSys.Sources/RequestProcessing/HeaderCollection.cs similarity index 100% rename from shared/Microsoft.AspNetCore.HttpSys.Sources/RequestProcessing/HeaderCollection.cs rename to src/HttpSysServer/shared/Microsoft.AspNetCore.HttpSys.Sources/RequestProcessing/HeaderCollection.cs diff --git a/shared/Microsoft.AspNetCore.HttpSys.Sources/RequestProcessing/HeaderEncoding.cs b/src/HttpSysServer/shared/Microsoft.AspNetCore.HttpSys.Sources/RequestProcessing/HeaderEncoding.cs similarity index 100% rename from shared/Microsoft.AspNetCore.HttpSys.Sources/RequestProcessing/HeaderEncoding.cs rename to src/HttpSysServer/shared/Microsoft.AspNetCore.HttpSys.Sources/RequestProcessing/HeaderEncoding.cs diff --git a/shared/Microsoft.AspNetCore.HttpSys.Sources/RequestProcessing/HeaderParser.cs b/src/HttpSysServer/shared/Microsoft.AspNetCore.HttpSys.Sources/RequestProcessing/HeaderParser.cs similarity index 100% rename from shared/Microsoft.AspNetCore.HttpSys.Sources/RequestProcessing/HeaderParser.cs rename to src/HttpSysServer/shared/Microsoft.AspNetCore.HttpSys.Sources/RequestProcessing/HeaderParser.cs diff --git a/shared/Microsoft.AspNetCore.HttpSys.Sources/RequestProcessing/HttpKnownHeaderNames.cs b/src/HttpSysServer/shared/Microsoft.AspNetCore.HttpSys.Sources/RequestProcessing/HttpKnownHeaderNames.cs similarity index 100% rename from shared/Microsoft.AspNetCore.HttpSys.Sources/RequestProcessing/HttpKnownHeaderNames.cs rename to src/HttpSysServer/shared/Microsoft.AspNetCore.HttpSys.Sources/RequestProcessing/HttpKnownHeaderNames.cs diff --git a/shared/Microsoft.AspNetCore.HttpSys.Sources/RequestProcessing/NativeRequestContext.cs b/src/HttpSysServer/shared/Microsoft.AspNetCore.HttpSys.Sources/RequestProcessing/NativeRequestContext.cs similarity index 100% rename from shared/Microsoft.AspNetCore.HttpSys.Sources/RequestProcessing/NativeRequestContext.cs rename to src/HttpSysServer/shared/Microsoft.AspNetCore.HttpSys.Sources/RequestProcessing/NativeRequestContext.cs diff --git a/shared/Microsoft.AspNetCore.HttpSys.Sources/RequestProcessing/RawUrlHelper.cs b/src/HttpSysServer/shared/Microsoft.AspNetCore.HttpSys.Sources/RequestProcessing/RawUrlHelper.cs similarity index 100% rename from shared/Microsoft.AspNetCore.HttpSys.Sources/RequestProcessing/RawUrlHelper.cs rename to src/HttpSysServer/shared/Microsoft.AspNetCore.HttpSys.Sources/RequestProcessing/RawUrlHelper.cs diff --git a/shared/Microsoft.AspNetCore.HttpSys.Sources/RequestProcessing/RequestHeaders.Generated.cs b/src/HttpSysServer/shared/Microsoft.AspNetCore.HttpSys.Sources/RequestProcessing/RequestHeaders.Generated.cs similarity index 100% rename from shared/Microsoft.AspNetCore.HttpSys.Sources/RequestProcessing/RequestHeaders.Generated.cs rename to src/HttpSysServer/shared/Microsoft.AspNetCore.HttpSys.Sources/RequestProcessing/RequestHeaders.Generated.cs diff --git a/shared/Microsoft.AspNetCore.HttpSys.Sources/RequestProcessing/RequestHeaders.cs b/src/HttpSysServer/shared/Microsoft.AspNetCore.HttpSys.Sources/RequestProcessing/RequestHeaders.cs similarity index 100% rename from shared/Microsoft.AspNetCore.HttpSys.Sources/RequestProcessing/RequestHeaders.cs rename to src/HttpSysServer/shared/Microsoft.AspNetCore.HttpSys.Sources/RequestProcessing/RequestHeaders.cs diff --git a/shared/Microsoft.AspNetCore.HttpSys.Sources/RequestProcessing/RequestUriBuilder.cs b/src/HttpSysServer/shared/Microsoft.AspNetCore.HttpSys.Sources/RequestProcessing/RequestUriBuilder.cs similarity index 100% rename from shared/Microsoft.AspNetCore.HttpSys.Sources/RequestProcessing/RequestUriBuilder.cs rename to src/HttpSysServer/shared/Microsoft.AspNetCore.HttpSys.Sources/RequestProcessing/RequestUriBuilder.cs diff --git a/shared/Microsoft.AspNetCore.HttpSys.Sources/RequestProcessing/SslStatus.cs b/src/HttpSysServer/shared/Microsoft.AspNetCore.HttpSys.Sources/RequestProcessing/SslStatus.cs similarity index 100% rename from shared/Microsoft.AspNetCore.HttpSys.Sources/RequestProcessing/SslStatus.cs rename to src/HttpSysServer/shared/Microsoft.AspNetCore.HttpSys.Sources/RequestProcessing/SslStatus.cs diff --git a/src/Directory.Build.props b/src/HttpSysServer/src/Directory.Build.props similarity index 100% rename from src/Directory.Build.props rename to src/HttpSysServer/src/Directory.Build.props diff --git a/src/Microsoft.AspNetCore.Server.HttpSys/AsyncAcceptContext.cs b/src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/AsyncAcceptContext.cs similarity index 100% rename from src/Microsoft.AspNetCore.Server.HttpSys/AsyncAcceptContext.cs rename to src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/AsyncAcceptContext.cs diff --git a/src/Microsoft.AspNetCore.Server.HttpSys/AuthenticationHandler.cs b/src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/AuthenticationHandler.cs similarity index 100% rename from src/Microsoft.AspNetCore.Server.HttpSys/AuthenticationHandler.cs rename to src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/AuthenticationHandler.cs diff --git a/src/Microsoft.AspNetCore.Server.HttpSys/AuthenticationManager.cs b/src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/AuthenticationManager.cs similarity index 100% rename from src/Microsoft.AspNetCore.Server.HttpSys/AuthenticationManager.cs rename to src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/AuthenticationManager.cs diff --git a/src/Microsoft.AspNetCore.Server.HttpSys/AuthenticationSchemes.cs b/src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/AuthenticationSchemes.cs similarity index 100% rename from src/Microsoft.AspNetCore.Server.HttpSys/AuthenticationSchemes.cs rename to src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/AuthenticationSchemes.cs diff --git a/src/Microsoft.AspNetCore.Server.HttpSys/FeatureContext.cs b/src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/FeatureContext.cs similarity index 100% rename from src/Microsoft.AspNetCore.Server.HttpSys/FeatureContext.cs rename to src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/FeatureContext.cs diff --git a/src/Microsoft.AspNetCore.Server.HttpSys/Helpers.cs b/src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/Helpers.cs similarity index 100% rename from src/Microsoft.AspNetCore.Server.HttpSys/Helpers.cs rename to src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/Helpers.cs diff --git a/src/Microsoft.AspNetCore.Server.HttpSys/Http503VerbosityLevel .cs b/src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/Http503VerbosityLevel .cs similarity index 100% rename from src/Microsoft.AspNetCore.Server.HttpSys/Http503VerbosityLevel .cs rename to src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/Http503VerbosityLevel .cs diff --git a/src/Microsoft.AspNetCore.Server.HttpSys/HttpSysDefaults.cs b/src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/HttpSysDefaults.cs similarity index 100% rename from src/Microsoft.AspNetCore.Server.HttpSys/HttpSysDefaults.cs rename to src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/HttpSysDefaults.cs diff --git a/src/Microsoft.AspNetCore.Server.HttpSys/HttpSysException.cs b/src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/HttpSysException.cs similarity index 100% rename from src/Microsoft.AspNetCore.Server.HttpSys/HttpSysException.cs rename to src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/HttpSysException.cs diff --git a/src/Microsoft.AspNetCore.Server.HttpSys/HttpSysListener.cs b/src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/HttpSysListener.cs similarity index 100% rename from src/Microsoft.AspNetCore.Server.HttpSys/HttpSysListener.cs rename to src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/HttpSysListener.cs diff --git a/src/Microsoft.AspNetCore.Server.HttpSys/HttpSysOptions.cs b/src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/HttpSysOptions.cs similarity index 100% rename from src/Microsoft.AspNetCore.Server.HttpSys/HttpSysOptions.cs rename to src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/HttpSysOptions.cs diff --git a/src/Microsoft.AspNetCore.Server.HttpSys/LogHelper.cs b/src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/LogHelper.cs similarity index 100% rename from src/Microsoft.AspNetCore.Server.HttpSys/LogHelper.cs rename to src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/LogHelper.cs diff --git a/src/Microsoft.AspNetCore.Server.HttpSys/MessagePump.cs b/src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/MessagePump.cs similarity index 100% rename from src/Microsoft.AspNetCore.Server.HttpSys/MessagePump.cs rename to src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/MessagePump.cs diff --git a/src/Microsoft.AspNetCore.Server.HttpSys/Microsoft.AspNetCore.Server.HttpSys.csproj b/src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/Microsoft.AspNetCore.Server.HttpSys.csproj similarity index 100% rename from src/Microsoft.AspNetCore.Server.HttpSys/Microsoft.AspNetCore.Server.HttpSys.csproj rename to src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/Microsoft.AspNetCore.Server.HttpSys.csproj diff --git a/src/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/ComNetOS.cs b/src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/ComNetOS.cs similarity index 100% rename from src/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/ComNetOS.cs rename to src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/ComNetOS.cs diff --git a/src/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/DisconnectListener.cs b/src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/DisconnectListener.cs similarity index 100% rename from src/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/DisconnectListener.cs rename to src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/DisconnectListener.cs diff --git a/src/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/HttpApi.cs b/src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/HttpApi.cs similarity index 100% rename from src/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/HttpApi.cs rename to src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/HttpApi.cs diff --git a/src/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/HttpRequestQueueV2Handle.cs b/src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/HttpRequestQueueV2Handle.cs similarity index 100% rename from src/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/HttpRequestQueueV2Handle.cs rename to src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/HttpRequestQueueV2Handle.cs diff --git a/src/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/HttpServerSessionHandle.cs b/src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/HttpServerSessionHandle.cs similarity index 100% rename from src/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/HttpServerSessionHandle.cs rename to src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/HttpServerSessionHandle.cs diff --git a/src/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/HttpSysSettings.cs b/src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/HttpSysSettings.cs similarity index 100% rename from src/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/HttpSysSettings.cs rename to src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/HttpSysSettings.cs diff --git a/src/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/IntPtrHelper.cs b/src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/IntPtrHelper.cs similarity index 100% rename from src/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/IntPtrHelper.cs rename to src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/IntPtrHelper.cs diff --git a/src/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/RequestQueue.cs b/src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/RequestQueue.cs similarity index 100% rename from src/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/RequestQueue.cs rename to src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/RequestQueue.cs diff --git a/src/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/ServerSession.cs b/src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/ServerSession.cs similarity index 100% rename from src/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/ServerSession.cs rename to src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/ServerSession.cs diff --git a/src/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/TokenBindingUtil.cs b/src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/TokenBindingUtil.cs similarity index 100% rename from src/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/TokenBindingUtil.cs rename to src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/TokenBindingUtil.cs diff --git a/src/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/UrlGroup.cs b/src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/UrlGroup.cs similarity index 100% rename from src/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/UrlGroup.cs rename to src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/NativeInterop/UrlGroup.cs diff --git a/src/Microsoft.AspNetCore.Server.HttpSys/Properties/AssemblyInfo.cs b/src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/Properties/AssemblyInfo.cs similarity index 100% rename from src/Microsoft.AspNetCore.Server.HttpSys/Properties/AssemblyInfo.cs rename to src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/Properties/AssemblyInfo.cs diff --git a/src/Microsoft.AspNetCore.Server.HttpSys/Properties/Resources.Designer.cs b/src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/Properties/Resources.Designer.cs similarity index 100% rename from src/Microsoft.AspNetCore.Server.HttpSys/Properties/Resources.Designer.cs rename to src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/Properties/Resources.Designer.cs diff --git a/src/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/BoundaryType.cs b/src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/BoundaryType.cs similarity index 100% rename from src/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/BoundaryType.cs rename to src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/BoundaryType.cs diff --git a/src/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/ClientCertLoader.cs b/src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/ClientCertLoader.cs similarity index 100% rename from src/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/ClientCertLoader.cs rename to src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/ClientCertLoader.cs diff --git a/src/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/HttpReasonPhrase.cs b/src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/HttpReasonPhrase.cs similarity index 100% rename from src/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/HttpReasonPhrase.cs rename to src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/HttpReasonPhrase.cs diff --git a/src/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/OpaqueStream.cs b/src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/OpaqueStream.cs similarity index 100% rename from src/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/OpaqueStream.cs rename to src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/OpaqueStream.cs diff --git a/src/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/Request.cs b/src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/Request.cs similarity index 100% rename from src/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/Request.cs rename to src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/Request.cs diff --git a/src/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/RequestContext.cs b/src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/RequestContext.cs similarity index 100% rename from src/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/RequestContext.cs rename to src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/RequestContext.cs diff --git a/src/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/RequestHeaders.Generated.tt b/src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/RequestHeaders.Generated.tt similarity index 100% rename from src/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/RequestHeaders.Generated.tt rename to src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/RequestHeaders.Generated.tt diff --git a/src/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/RequestStream.cs b/src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/RequestStream.cs similarity index 100% rename from src/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/RequestStream.cs rename to src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/RequestStream.cs diff --git a/src/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/RequestStreamAsyncResult.cs b/src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/RequestStreamAsyncResult.cs similarity index 100% rename from src/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/RequestStreamAsyncResult.cs rename to src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/RequestStreamAsyncResult.cs diff --git a/src/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/Response.cs b/src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/Response.cs similarity index 100% rename from src/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/Response.cs rename to src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/Response.cs diff --git a/src/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/ResponseBody.cs b/src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/ResponseBody.cs similarity index 100% rename from src/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/ResponseBody.cs rename to src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/ResponseBody.cs diff --git a/src/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/ResponseStreamAsyncResult.cs b/src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/ResponseStreamAsyncResult.cs similarity index 100% rename from src/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/ResponseStreamAsyncResult.cs rename to src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/RequestProcessing/ResponseStreamAsyncResult.cs diff --git a/src/Microsoft.AspNetCore.Server.HttpSys/Resources.resx b/src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/Resources.resx similarity index 100% rename from src/Microsoft.AspNetCore.Server.HttpSys/Resources.resx rename to src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/Resources.resx diff --git a/src/Microsoft.AspNetCore.Server.HttpSys/ResponseStream.cs b/src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/ResponseStream.cs similarity index 100% rename from src/Microsoft.AspNetCore.Server.HttpSys/ResponseStream.cs rename to src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/ResponseStream.cs diff --git a/src/Microsoft.AspNetCore.Server.HttpSys/StandardFeatureCollection.cs b/src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/StandardFeatureCollection.cs similarity index 100% rename from src/Microsoft.AspNetCore.Server.HttpSys/StandardFeatureCollection.cs rename to src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/StandardFeatureCollection.cs diff --git a/src/Microsoft.AspNetCore.Server.HttpSys/TimeoutManager.cs b/src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/TimeoutManager.cs similarity index 100% rename from src/Microsoft.AspNetCore.Server.HttpSys/TimeoutManager.cs rename to src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/TimeoutManager.cs diff --git a/src/Microsoft.AspNetCore.Server.HttpSys/UrlPrefix.cs b/src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/UrlPrefix.cs similarity index 100% rename from src/Microsoft.AspNetCore.Server.HttpSys/UrlPrefix.cs rename to src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/UrlPrefix.cs diff --git a/src/Microsoft.AspNetCore.Server.HttpSys/UrlPrefixCollection.cs b/src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/UrlPrefixCollection.cs similarity index 100% rename from src/Microsoft.AspNetCore.Server.HttpSys/UrlPrefixCollection.cs rename to src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/UrlPrefixCollection.cs diff --git a/src/Microsoft.AspNetCore.Server.HttpSys/ValidationHelper.cs b/src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/ValidationHelper.cs similarity index 100% rename from src/Microsoft.AspNetCore.Server.HttpSys/ValidationHelper.cs rename to src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/ValidationHelper.cs diff --git a/src/Microsoft.AspNetCore.Server.HttpSys/WebHostBuilderHttpSysExtensions.cs b/src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/WebHostBuilderHttpSysExtensions.cs similarity index 100% rename from src/Microsoft.AspNetCore.Server.HttpSys/WebHostBuilderHttpSysExtensions.cs rename to src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/WebHostBuilderHttpSysExtensions.cs diff --git a/src/Microsoft.AspNetCore.Server.HttpSys/baseline.netcore.json b/src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/baseline.netcore.json similarity index 100% rename from src/Microsoft.AspNetCore.Server.HttpSys/baseline.netcore.json rename to src/HttpSysServer/src/Microsoft.AspNetCore.Server.HttpSys/baseline.netcore.json diff --git a/test/Directory.Build.props b/src/HttpSysServer/test/Directory.Build.props similarity index 100% rename from test/Directory.Build.props rename to src/HttpSysServer/test/Directory.Build.props diff --git a/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/AuthenticationTests.cs b/src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/AuthenticationTests.cs similarity index 100% rename from test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/AuthenticationTests.cs rename to src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/AuthenticationTests.cs diff --git a/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/DummyApplication.cs b/src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/DummyApplication.cs similarity index 100% rename from test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/DummyApplication.cs rename to src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/DummyApplication.cs diff --git a/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/HttpsTests.cs b/src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/HttpsTests.cs similarity index 100% rename from test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/HttpsTests.cs rename to src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/HttpsTests.cs diff --git a/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Listener/RequestBodyTests.cs b/src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Listener/RequestBodyTests.cs similarity index 100% rename from test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Listener/RequestBodyTests.cs rename to src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Listener/RequestBodyTests.cs diff --git a/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Listener/RequestHeaderTests.cs b/src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Listener/RequestHeaderTests.cs similarity index 100% rename from test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Listener/RequestHeaderTests.cs rename to src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Listener/RequestHeaderTests.cs diff --git a/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Listener/RequestTests.cs b/src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Listener/RequestTests.cs similarity index 100% rename from test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Listener/RequestTests.cs rename to src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Listener/RequestTests.cs diff --git a/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Listener/ResponseBodyTests.cs b/src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Listener/ResponseBodyTests.cs similarity index 100% rename from test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Listener/ResponseBodyTests.cs rename to src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Listener/ResponseBodyTests.cs diff --git a/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Listener/ResponseCachingTests.cs b/src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Listener/ResponseCachingTests.cs similarity index 100% rename from test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Listener/ResponseCachingTests.cs rename to src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Listener/ResponseCachingTests.cs diff --git a/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Listener/ResponseHeaderTests.cs b/src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Listener/ResponseHeaderTests.cs similarity index 100% rename from test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Listener/ResponseHeaderTests.cs rename to src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Listener/ResponseHeaderTests.cs diff --git a/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Listener/ServerTests.cs b/src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Listener/ServerTests.cs similarity index 100% rename from test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Listener/ServerTests.cs rename to src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Listener/ServerTests.cs diff --git a/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Listener/Utilities.cs b/src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Listener/Utilities.cs similarity index 100% rename from test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Listener/Utilities.cs rename to src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Listener/Utilities.cs diff --git a/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/MessagePumpTests.cs b/src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/MessagePumpTests.cs similarity index 100% rename from test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/MessagePumpTests.cs rename to src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/MessagePumpTests.cs diff --git a/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests.csproj b/src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests.csproj similarity index 100% rename from test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests.csproj rename to src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests.csproj diff --git a/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/OSDontSkipConditionAttribute.cs b/src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/OSDontSkipConditionAttribute.cs similarity index 100% rename from test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/OSDontSkipConditionAttribute.cs rename to src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/OSDontSkipConditionAttribute.cs diff --git a/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/OpaqueUpgradeTests.cs b/src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/OpaqueUpgradeTests.cs similarity index 100% rename from test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/OpaqueUpgradeTests.cs rename to src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/OpaqueUpgradeTests.cs diff --git a/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Properties/AssemblyInfo.cs b/src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Properties/AssemblyInfo.cs similarity index 100% rename from test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Properties/AssemblyInfo.cs rename to src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Properties/AssemblyInfo.cs diff --git a/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/RequestBodyLimitTests.cs b/src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/RequestBodyLimitTests.cs similarity index 100% rename from test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/RequestBodyLimitTests.cs rename to src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/RequestBodyLimitTests.cs diff --git a/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/RequestBodyTests.cs b/src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/RequestBodyTests.cs similarity index 100% rename from test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/RequestBodyTests.cs rename to src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/RequestBodyTests.cs diff --git a/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/RequestHeaderTests.cs b/src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/RequestHeaderTests.cs similarity index 100% rename from test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/RequestHeaderTests.cs rename to src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/RequestHeaderTests.cs diff --git a/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/RequestTests.cs b/src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/RequestTests.cs similarity index 100% rename from test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/RequestTests.cs rename to src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/RequestTests.cs diff --git a/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/ResponseBodyTests.cs b/src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/ResponseBodyTests.cs similarity index 100% rename from test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/ResponseBodyTests.cs rename to src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/ResponseBodyTests.cs diff --git a/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/ResponseCachingTests.cs b/src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/ResponseCachingTests.cs similarity index 100% rename from test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/ResponseCachingTests.cs rename to src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/ResponseCachingTests.cs diff --git a/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/ResponseHeaderTests.cs b/src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/ResponseHeaderTests.cs similarity index 100% rename from test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/ResponseHeaderTests.cs rename to src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/ResponseHeaderTests.cs diff --git a/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/ResponseSendFileTests.cs b/src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/ResponseSendFileTests.cs similarity index 100% rename from test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/ResponseSendFileTests.cs rename to src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/ResponseSendFileTests.cs diff --git a/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/ResponseTests.cs b/src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/ResponseTests.cs similarity index 100% rename from test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/ResponseTests.cs rename to src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/ResponseTests.cs diff --git a/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/ServerTests.cs b/src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/ServerTests.cs similarity index 100% rename from test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/ServerTests.cs rename to src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/ServerTests.cs diff --git a/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Utilities.cs b/src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Utilities.cs similarity index 100% rename from test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Utilities.cs rename to src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.FunctionalTests/Utilities.cs diff --git a/test/Microsoft.AspNetCore.Server.HttpSys.Tests/Microsoft.AspNetCore.Server.HttpSys.Tests.csproj b/src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.Tests/Microsoft.AspNetCore.Server.HttpSys.Tests.csproj similarity index 100% rename from test/Microsoft.AspNetCore.Server.HttpSys.Tests/Microsoft.AspNetCore.Server.HttpSys.Tests.csproj rename to src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.Tests/Microsoft.AspNetCore.Server.HttpSys.Tests.csproj diff --git a/test/Microsoft.AspNetCore.Server.HttpSys.Tests/UrlPrefixTests.cs b/src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.Tests/UrlPrefixTests.cs similarity index 100% rename from test/Microsoft.AspNetCore.Server.HttpSys.Tests/UrlPrefixTests.cs rename to src/HttpSysServer/test/Microsoft.AspNetCore.Server.HttpSys.Tests/UrlPrefixTests.cs diff --git a/version.props b/src/HttpSysServer/version.props similarity index 100% rename from version.props rename to src/HttpSysServer/version.props