Commit Graph

9 Commits

Author SHA1 Message Date
Ryan Nowak f95ffb57ae Make dictionary allocations lazy on RouteData
This change makes the allocation of DataTokens and Values on RouteData
lazy, and elides copies when copying an 'empty' RouteData.

In our current architecture this change will eliminiate 2 * (N + 1)
dictionary allocations/copies per request, where N is the number of routes
processed. In a large system with lots of attribute routes, this number
could be very significant.

For a small MVC site (ModelBinding, Validation, Views) with one route, it
still shows a modest reduction of dictionary allocations without adding
much complexity.
2015-09-28 22:54:32 -07:00
Pranav K c6941e797f Replacing NotNullAttribute with exceptions 2015-09-11 15:08:04 -07:00
N. Taylor Mullen 352732fc62 Update LICENSE.txt and license header on files. 2015-05-01 13:59:22 -07:00
Praburaj fb08460770 Using [NotNull] from common repo package 2015-03-13 17:54:16 -07:00
Ryan Nowak aae9e67773 add docs 2014-10-31 15:02:54 -07:00
Ryan Nowak d78e5478a7 Fix for #65,116 - Implement 'stack of routers'
This is the routing part of the fix. MVC will be updated as well
(attribute routing).

As the graph of routers is traversed, routers add themselves to the
current 'path', which unwinds on a failed path.

This mechanism is opt-in. Whoever adds something needs to remove it as
part of cleanup. If a router in the tree doesn't interact with the
.Routers property, then there are no consequences for those that do.

Additionally, fixing #116 as part of the same change. This means that we
create a nested 'RouteData' and then restore it on the way out. This is
simpler than just dealing with the .Routers property in isolation.
2014-10-31 14:07:35 -07:00
harshgMSFT efdd3054d2 Adding DataTokens Support. 2014-08-11 11:59:00 -07:00
Ryan Nowak 28b89c8fe5 Changing to list 2014-06-06 10:16:47 -07:00
Ryan Nowak d10682d15b Issue aspnet/Mvc#56 - merging RouteContext and RequestContext
This is the routing part of these changes, and just the breaking changes
parts.

Follow-ups will add:
- DataTokens
- Tracking the logical stack of routers
2014-06-06 10:11:57 -07:00