Commit Graph

263 Commits

Author SHA1 Message Date
Doug Bunting ce8f053af7
Rename all the service reference things (#9559)
- #7492
  - remove document generation from client project; will be included in Web API project infrastructure (coming soon)
  - adjust eng/ProjectReferences.props to new project name
  - simplify item de-duplication in `_CreateCompileItemsForServiceFileReferences` target i.e. use `Remove` attribute
    - also handle `.tsx` files in this target
- provide `%(FirstForGenerator)` metadata, #4916
- add `$(OpenApiGenerateAtDesignTime)` property (default `true` for now), #4944
- generate code in `obj` directory by default, #4945
- provide a default `%(CodeGenerator)` value, ##7491 1 of 2 (remainder will come in next milestone)

nits:
- remove a useless `StringBuilder.Append(...)` call
- remove `%(OpenApiProjectReference.SourceProject)` metadata, duplicated `%(OriginalItemSpec)`
- be more consistent about using element syntax for item metadata
2019-04-22 11:15:54 -07:00
Doug Bunting 1c19e8ee89
Merge branch 'release/2.2' -> 'master' (#9591) 2019-04-22 11:12:35 -07:00
Pranav K 418f3d82dd
React to new System.Text.Json features (#9572) 2019-04-21 20:48:41 -07:00
Ryan Nowak f0ea4fc8a1 Update solutions
We have a new SignalR package and it needs to be the added.
2019-04-21 15:16:54 -07:00
Pranav K e42f979cca
Add a System.Text.Json based IJsonHelper (#9566)
* Add a System.Text.Json based IJsonHelper

Fixes https://github.com/aspnet/AspNetCore/issues/9564
2019-04-21 12:10:47 -07:00
Pranav K 0303c9e90b
AddControllersWithViewsCore should add CacheTagHelper services (#9580) 2019-04-21 09:51:41 -07:00
Pranav K 5e953124e6
Add support for System.Text.Json based JsonResult executor (#9558)
Fixes https://github.com/aspnet/AspNetCore/issues/9554
2019-04-21 09:13:30 -07:00
Doug Bunting dfae19ee7c
Merge branch 'release/2.2' -> 'master' 2019-04-19 18:53:15 -07:00
John Luo 7a040f310b
Enable Pubternal API checks (#9530)
* Enable Pubternal API checks

* Use pragma

* Convert to pragma

* Test fix

* Remove extra restore dependencies
2019-04-19 18:49:07 -07:00
Nate McMaster 9212f4a3df
Update corefx dependencies and react to changes in JSON API (#9563) 2019-04-19 11:42:41 -07:00
Ben Adams d46388b58e Lazy create MVC ControllerActionInvoker statemachines (#9533)
* Lazy create ControllerActionInvoker.InvokeInnerFilterAsync statemachine

* Lazy create ControllerActionInvoker.InvokeNextActionFilterAwaitedAsync statemachine

* Lazy create ControllerActionInvoker.InvokeNextActionFilterAsync statemachine

* Lazy create ControllerActionInvoker.InvokeActionMethodAsync statemachine

* Lazy create Controller.OnActionExecutionAsync statemachine

* Ref assembly

* Formatting feedback
2019-04-19 07:48:26 -07:00
Pranav K acf45106fc
Use FileBufferingWriteStream in ViewComponentResultExecutor (#9523)
Fixes https://github.com/aspnet/AspNetCore/issues/9443
2019-04-18 19:27:55 -07:00
James Newton-King 7669cf0d03
Move Microsoft.AspNetCore.Authorization.Policy types (#9492) 2019-04-19 13:24:36 +12:00
Ryan Nowak 6074daacae Fixes: #9468 2019-04-18 12:47:42 -07:00
Ben Adams 8fcadf72cd Allow headers to match on ReferenceEquals before OrdinalIgnoreCase (#9341) 2019-04-18 12:00:01 -07:00
Justin Kotalik 7448964388 Mark mvc test as flaky (#9489) 2019-04-17 21:46:27 -07:00
David Fowler 32c46c7201
Create an activity more often than before (#9361)
- Create an Activity if there's a diagnostic listener attached with the activity name or if logging is enabled.
- Add the activity id to the logging scope (and call the field ActivityId)
2019-04-17 18:23:12 -07:00
Pranav K 92cae6faab
Buffer writes from sources of synchronous writes (#9015)
* Buffer writes from sources of synchronous writes

Fixes https://github.com/aspnet/AspNetCore/issues/6397
2019-04-17 18:11:07 -07:00
Pranav K 004ac25983
Remove AddRazorSupportForMvc from MVC and Blazor projects (#9446)
Fixes https://github.com/aspnet/AspNetCore/issues/9126
Fixes https://github.com/aspnet/AspNetCore/issues/9183
Fixes https://github.com/aspnet/AspNetCore/issues/9207
2019-04-16 20:46:51 -07:00
Ryan Nowak 7021df89e4 Remove dynamic from page endpoints 2019-04-16 19:36:32 -07:00
Ryan Nowak 6f305373ca Allow fallback to controller to use MatcherPolicy 2019-04-16 19:36:32 -07:00
Ryan Nowak 6eeda774ef Implement IEndpointSelectorPolicy for ConsumesMatcherPolicy 2019-04-16 19:36:32 -07:00
David Fowler 48f0a76ea9
Support plain text exception formatting (#9342)
- If there's no Accept: text/html then print the exception.ToString as plaintext
2019-04-16 18:34:07 -07:00
Pranav K e2477706b6
Always set flag in CorsMiddleware once it executes (#9440)
Fixes https://github.com/aspnet/AspNetCore/issues/9348
2019-04-16 16:28:27 -07:00
Pranav K 51028dd129
Remove use of IgnoreNullPropertyValueOnRead and ReaderOptions from JsonSerializerOptions (#9429)
Fixes https://github.com/aspnet/AspNetCore/issues/9406
2019-04-16 16:24:17 -07:00
Pranav K 2be80522b2
Prevent synchronous writes when using Razor (#9395)
* Do not perform synchronous writes to the Response TextWriter after a Razor FlushAsync
* Use ViewBuffer to perform async writes to the response when using ViewComponentResult

Related to #6397 

Fixes https://github.com/aspnet/AspNetCore/issues/4885
2019-04-16 16:12:37 -07:00
Nate McMaster d004cf0f14
Merge branch 'release/2.1' into release/2.2 2019-04-15 16:42:07 -07:00
Pranav K 836964a653 Don't log action and page handler arguments above Trace level (#9227) 2019-04-15 13:29:07 -07:00
Ben Adams 1baeaaac36 Feedback 2019-04-14 17:55:16 -07:00
Ben Adams 70b02f8406 Lazy create ResourceInvoker.InvokeNextResourceFilterAwaitedAsync statemachine 2019-04-14 17:55:16 -07:00
Ben Adams cfc22fe0df Lazy create ResourceInvoker.InvokeNextResultFilterAwaitedAsync statemachine 2019-04-14 17:55:16 -07:00
Ben Adams 8c97cbe6aa Lazy create ResourceInvoker.InvokeNextResultFilterAsync statemachine 2019-04-14 17:55:16 -07:00
Ben Adams 7393f264b0 Lazy create ResourceInvoker.InvokeResultFilters statemachine 2019-04-14 17:55:16 -07:00
Ben Adams 0657a3ed1a Lazy create ResourceInvoker.InvokeAlwaysRunResultFilters statemachine 2019-04-14 17:55:16 -07:00
Ben Adams 6039699afa Lazy create ResourceInvoker.InvokeNextExceptionFilterAsync statemachine 2019-04-14 17:55:16 -07:00
Ben Adams 1a7e606504 Lazy create ResourceInvoker.InvokeNextResourceFilter statemachine 2019-04-14 17:55:16 -07:00
Ben Adams 8bb54fc22a Lazy create ResourceInvoker.InvokeResultAsync statemachine 2019-04-14 17:55:16 -07:00
Ben Adams 305249709c Lazy create ResourceInvoker.InvokeFilterPipelineAsync statemachine 2019-04-14 17:55:16 -07:00
Ben Adams fe6907616b Lazy create ResourceInvoker.InvokeAsync statemachine 2019-04-14 17:55:16 -07:00
Ben Adams 7a4400e3b2 ResourceInvoker faster task completion check 2019-04-14 17:55:16 -07:00
Ben Adams 614d6336fd Skip keys array allocation 2019-04-12 06:49:01 -07:00
Javier Calvarro Nelson 3265c54518
[MVC][Fixes #7576]HtmlHelperOptions.ClientValidationEnabled = false is ignored in Razor Pages (#9289)
* Replaced IOptions<HtmlHelperOptions> with IOptions<MvcViewOptions> on the PageActionInvokerProvider.
2019-04-12 11:56:24 +02:00
Pranav K 5424045dac Ensure PackageArchive contains the right build of Razor.Design package (#6992)
* Ensure PackageArchive contains the right build of Razor.Design package

* Re-order values in build\dependencies.props to ensure Razor.Design's package version is
  overwritten.
* Convert additional package refs to project refs

Fixes https://github.com/aspnet/AspNetCore-Internal/issues/1708

* Update CodeCheck.ps1
2019-04-11 17:14:11 -07:00
Ben Adams 84da613d2c Cache OnStarting callback delegate (#9283) 2019-04-11 16:08:58 -07:00
Pranav K b93bc433db
Make AuthorizeFilter work in endpoint routing (#9099)
* Make AuthorizeFilter work in endpoint routing

Fixes https://github.com/aspnet/AspNetCore/issues/8387
2019-04-08 06:03:34 -07:00
James Newton-King 69f4b6d227
Add StartupAnalzyer (#9100) 2019-04-06 18:25:19 +13:00
Pranav K fb037bda01
Set CSharpLangVersion during runtime compilation (#9135)
* Set CSharpLangVersion during runtime compilation

* Pass CSharpLangVersion inferred by the CSharpCompiler to RazorEngine
* Set GenerateRazorHostingAssemblyInfo in Razor.RuntimeCompilation
targets
* Unskip failing test

Fixes https://github.com/aspnet/AspNetCore/issues/8996
2019-04-05 21:24:50 -07:00
Doug Bunting 1b50085835
Chain coherent dependencies up through Extensions to EF Core packages (#8877)
* Chain coherent dependencies up through Extensions to EF Core packages
- should reduce incoherent PRs we get from `darc`
- react to AspNetCore-Tooling breaking changes
  - use C# Preview version in Blazor integration tests
    - update `EnsureOptions_ConfiguresDefaultParseOptions` test to match new C# version default
  - react to new newline encoding behavior; thanx @ajaybhargavb!
  - update product code and tests to use new GetItem API; thanx @NTaylorMullen!
    - RazorProjectFileSystem breaking change
    - update ref assemblies
- react to EF Core breaking changes
  - react to EF Core method rename
  - react to aspnet/EntityFrameworkCore@ccfc5edbc7
  - react to aspnet/EntityFrameworkCore@6cb41531df breaking change
    - disable new analyzer in `ScratchDatabaseFixture`
- skip `MvcTemplate_NoAuthImplAsync(...)` test for F#
  - #8996
- exclude some runtime assemblies from crossgen; thanx @BrennanConroy!
- add direct references to Mvc in AzureAD samples
  - unclear why the reference is no longer pulled in transitively

* Run `darc` to grab the latest
- CoreFx packages with version 4.6.0-preview4.19204.1 to ensure coherency
- core-setup packages with version 3.0.0-preview4-27604-05 to ensure coherency
- Extensions packages with verisn 3.0.0-preview4.19204.2 to ensure coherency
- EntityFrameworkCore packages with version 3.0.0-preview4.19204.7 from build 20190404.7
- AspNetCore-Tooling packages with version 3.0.0-preview4.19204.2 from build 20190404.2
2019-04-05 10:54:04 -07:00
Ryan Nowak 258d34e382
Use coventional routes for link generation (#9037)
Use coventional routes for link generation

This change enables using conventional routes for link generation when
using MVC conventional routes. This change makes MVC link generation
behaviour highly compatible with 2.1.

The way that this works is that we create endpoints for **MATCHING**
using the denormalized conventional route, but we tell those endpoints
to suppress link generation.

For link generation we generate a non-matching endpoints per-route with
the same order value.

I added the concept of *required value any* to link generation. This is
needed because for an endpoint to participate in link generation using
RouteValuesAddress it needs to have some required values. These details
are a little fiddly, but I think it's worth doing this feature
completely.
2019-04-05 08:31:10 -07:00
Martin Costello 0f0a388eab Extend WebApplicationFactory<T> (#7414)
* Support host-agnostic services access

* Support host agnostic access to the IServiceCollection associated with
      WebApplicationFactory<T>.
2019-04-05 00:21:48 +02:00