Commit Graph

37440 Commits

Author SHA1 Message Date
Steve Sanderson 7a2dfd3200
Components: Forms and validation (#7614) 2019-02-20 09:56:32 +00:00
Chris Ross 4e44025a52
Replace IHostingEnvironment with IWebHostEnvironment (#7725) 2019-02-19 21:11:52 -08:00
Matthias Laroche 7af971838e Set Content-Length to 0, when returning an empty body
When returning 416 RangeNotSatisfiable in FileResultExecutorBase, set the Content-Length based on the length of the body instead of the length of the original file.
Bugfix for  :
https://github.com/aspnet/AspNetCore/issues/4943
2019-02-19 17:54:11 -08:00
Matthias Laroche 134f28f71d Update FileResult tests to detect a bug for the status 416 RangeNotSatisfiable
Update FileResult tests to detect a bug for the status 416 RangeNotSatisfiable :
https://github.com/aspnet/AspNetCore/issues/4943
When the body is empty, the Content-Length header should be 0 to match the body length.
2019-02-19 17:54:11 -08:00
Nate McMaster a9c358bbbd
Build MSI installers for targeting pack (#7726)
Part of #6501 

This adds a new Windows installer for the targeting pack. It places *.dll and *.xml (docs) in `[DOTNETHOME]\packs\Microsoft.AspNetCore.App.Ref\$(version)\ref\netcoreapp3.0`.

Outputs:
* aspnetcore-targeting-pack-$(version).zip
* aspnetcore-targeting-pack-$(version)-win-x64.exe (defaults to C:\Program Files\dotnet)
* aspnetcore-targeting-pack-$(version)-win-x86.exe (defaults to C:\Program Files (x86)\dotnet)

These all include the same files. These are meant to be bundled in the .NET Core SDK installer, but can be launched directly too.
2019-02-19 16:28:08 -08:00
Doug Bunting 8d6d300bfc
Improve service reference filenames and class names (#7447)
- #4927
- fully-sanitize class names and filenames
  - use aspnet/AspNetCore-Tooling's `CSharpIdentifier` class
- default metadata in sequence [URI or project&document name ->] `%(DocumentPath)` -> `%(OutputPath)` -> `%(ClassName)`
  - if user sets metadata explicitly, the override affects defaults later in the sequence
- separate some nested validations and defaulting steps
  - provide default `%(DocumentName}` even if `%(DocumentPath}` is set explicitly
  - validate URI is absolute even if `%(DocumentPath}` is set explicitly

other:
- don't write out an empty Open API / Swagger file

nits:
- do not use default `%(DocumentName}` in default `%(DocumentPath)` for `<ServiceProjectReference>` items
- do not use empty URI path or query string in default `%(DocumentPath)` for `<ServiceUriReference>` items
2019-02-19 16:05:54 -08:00
Ryan Nowak c725089e8b Add missing conversions on EventCallbackFactory 2019-02-19 15:48:16 -08:00
BrennanConroy f37d30833d
Ignore unexpected stream items and completions from client (#7511) 2019-02-19 15:25:50 -08:00
Doug Bunting 14b7184c09
Improve documentation of `BinderType` and `BindingSource` properties (#7218)
- add regression test for #4939
- add `[BindProperty]` doc comments
- add `<remarks>` to `BinderType` properties that recommend setting `BindingSource` in some cases

smaller issues:
- catch invalid `BinderType` values up front
- complete `BindingSource.ModelBinding` implementation: `IValueProvider` filtering was faulty

nits:
- accept VS suggestions e.g. remove unused variables
- "model binder" -> `<see cref="IModelBinder" /> implementation` in some doc comments
2019-02-19 15:22:04 -08:00
Doug Bunting 3e0c75187c
Place limits on model binding collection size and recursion depth (#7214)
- #7052
- add MvcOptions.MaxModelBindingCollectionSize` and `MvcOptions.MaxModelBindingRecursionDepth`

nits:
- update syntax of a few `Resources.Designer.cs` files (I ran `/t:resx` on Mvc.sln)
- take VS suggestions in a few test classes
2019-02-19 15:17:56 -08:00
Ryan Brandenburg 69abefa06f
[Design] Harden template package installer and fix name (#7624)
Harden template package installer and fix name
2019-02-19 14:41:59 -08:00
Mikael Mengistu d1fac57734
Ensure SignalR client messages are processed in order (#7697) 2019-02-19 11:48:22 -08:00
Nate McMaster ded53315d8
Update CODEOWNERS 2019-02-19 09:32:31 -08:00
TimTim dffe9abf6b Fix connection ID (#7681) 2019-02-18 17:13:53 -08:00
Ben Adams 3e47fa7c69 Inline BufferWriter .ctor (#7674) 2019-02-17 21:30:29 -08:00
Ryan Nowak 98fe8a8328 Improvements to bind and event handling
The changes here make event dispatching (including bind) more
user-friendly by avoiding the need for manual calls to StateHasChnaged.

We also introduce a new type `EventCallback` (and `EventCallback<T>`).
This is a new primitive that is like a super-powered version of a
delegate. When writing a component that accepts delegates as parameters,
consider using `EventCallback` for the following reasons:
- Allows consumer to pass a variety of different delegate signatures
- Does proper event dispatching and error handling

Using `EventCallback` will eliminate most of the remaining cases where a
manual `StateHasChanged` is required when components are passing content
and delegates to each other.

`EventCallback` is inherently async for the reason that this is really
the only way to provide correct error handling.

-----

The fix for this will be two-phase by first creating a set of APIs that
can be targeted by the compiler that has the desired behaviour and then
updating the compiler to target this new infrastructure.
2019-02-17 15:58:08 -08:00
James Newton-King cc7b35439c
Add test for HTTP method metadata order (#7225) 2019-02-18 09:20:12 +13:00
Ben Adams 6b7e821913 Don't hardcode fixed size for GetMemory in ChunkedTests 2019-02-17 09:29:57 -08:00
Chris R b571246c93 Suppress warnings for obsolete Extensions types 2019-02-17 09:29:57 -08:00
Justin Kotalik 49a720c1dc Fix GetMemory to not pass in size hint 2019-02-17 09:29:57 -08:00
Nate McMaster 69a463c709 Update Extensions 2019-02-17 09:29:57 -08:00
Nate McMaster cbf696b516 Update core-setup dependencies 2019-02-17 09:29:57 -08:00
Mikael Mengistu af43b80b1a Make server timeout configurable (#7340) 2019-02-17 07:57:36 -08:00
Stephen Halter 8ae4c4dbd6 Add SignalR web worker sample and test (#7378) 2019-02-17 07:52:18 -08:00
Ben Adams 4646ed5618 Work around WriteBarrier assign for nulling struct (#7659) 2019-02-16 20:09:39 -08:00
David Fowler 0fd753bfc2
Align host behavior with respect to exceptions (#7657)
- Don't catch errors in IHostedService.StartAsync
- Only catch errors when executing StopAsync but rethrow an aggregate
- Updated the tests
2019-02-16 19:09:14 -08:00
David Fowler 799b91a324
Change the namespace of the extension methods (#7651)
- The other routing extension methods use Microsoft.AspNetCore.Builder
2019-02-16 00:36:59 -08:00
James Newton-King c2d1ab925e
Remove obsolete APIs from routing (#7371) 2019-02-16 18:37:51 +13:00
Hao Kung 63a8b14619
Fix helix.proj warnings (#7373) 2019-02-15 19:40:10 -08:00
Hao Kung a1490bac35
Adding arm and fedora helix queues (#7543) 2019-02-15 19:37:05 -08:00
Mikael Mengistu c806c5a61a
Wait for stop to complete in SignalR test to prevent flakiness. (#7634) 2019-02-15 18:42:04 -08:00
Ben Adams 639d290b19 Lock-free IOQueue (#6154)
Second half of https://github.com/aspnet/AspNetCore/pull/4060
2019-02-15 18:26:30 -08:00
Nate McMaster 394ef0ab93
Add missing entry to Version.Details.xml (#7643)
Changes:
* add entry for Mono.WebAssembly.Interop to Version.Details.xml
* Update code check to ensure all veriables in the 'automated' section are accounted for in Version.Details.xml
2019-02-15 17:00:06 -08:00
Chris Ross 191fb03de7
ITlsHandshakeFeature requires Win8+ (#7629) 2019-02-15 16:28:04 -08:00
Justin Kotalik 60b00fa007
Make reads that return canceled ReadResult throw (#7618) 2019-02-15 16:11:57 -08:00
Chris Ross 93a24b03bb
Disable AllowSynchronousIO by default in all servers #4774 (#5120)
* Disable AllowSynchronousIO by default in all servers
2019-02-15 16:05:49 -08:00
Pranav K 7daa0e0145
Convert BlazorExtension to SDK style project (#7588)
* Convert BlazorExtension to SDK style project

Fixes https://github.com/aspnet/AspNetCore/issues/7135
2019-02-15 15:14:19 -08:00
Pranav K fe1c2c84ee
Remove uses of JSRuntime.Current (#7599)
* Remove uses of JSRuntime.Current

Prerequisite for https://github.com/aspnet/AspNetCore/issues/6828
2019-02-15 15:14:00 -08:00
Mikael Mengistu c98c79d255
Add startvs script from the tools directory. (#7582) 2019-02-15 14:55:07 -08:00
Pavel Krymets 9afdc48f13
Disable remote symbol loading for dump files in CI (#7620) 2019-02-15 14:42:36 -08:00
Nate McMaster bd41388fdd
Add deployment metadata to maestro manifests (#7625) 2019-02-15 13:01:42 -08:00
Chris Ross cc62bcebfc
Skip HttpSys.Https tests on Helix Internal/#1816 (#7578) 2019-02-15 12:33:23 -08:00
David Fowler 5ef51822de
Added endpoint routing support (#7608)
- Basic endpoint routing support to for SignalR hubs, ConnectionHandler and IConnectionBuilder endpoints
- Updated all functional tests and samples to use it
- Added all attributes as metadata from Hubs and ConnectionHandlers
- Added a test to verify client is rejected if auth is ineffective
2019-02-15 12:32:01 -08:00
Rick Anderson 8daca5ec3a Update CONTRIBUTING.md (#7622)
* Update CONTRIBUTING.md

* Remove 2/3 please per MS style guide:
  * *Avoid **please** except in situations where the customer is asked to do something inconvenient or the application or site is to blame for the situation.*
 * The last please meets that bar.
* Add AspNetCore repo
* Remove double blank lines
* Edit

* Update CONTRIBUTING.md

* Update CONTRIBUTING.md
2019-02-15 11:50:04 -08:00
Pavel Krymets 6bafb7cb6f
Log before releasing streams and firing tokens (#7583)
Might fix: https://github.com/aspnet/AspNetCore-Internal/issues/1659

I think writes complete too fast so we don't observe when the message gets logged
2019-02-15 10:41:21 -08:00
Justin Kotalik 25f1f59378
Make first write use the same BufferWriter (#7505) 2019-02-15 08:26:57 -08:00
Nikita Potapenko 98ad532822 Removed comments
Fixes #7579
2019-02-15 13:20:14 +00:00
Ajay Bhargav Baaskaran c565386a3e
Merge pull request #7597 from aspnet/ajbaaska/merge-master
Merge branch 'release/2.2' to master
2019-02-14 23:20:18 -08:00
Nate McMaster 67a6f08da9
Fix for missing, required property in Linux package signing 2019-02-14 17:45:41 -08:00
Ajay Bhargav Baaskaran b3d3f5e7fb Updated missed slns 2019-02-14 17:35:48 -08:00